Repository navigation
Gds push upgrade - #1065
Open
FHatCSW wants to merge 34 commits into
Open
Gds push upgrade#1065FHatCSW wants to merge 34 commits into
FHatCSW wants to merge 34 commits into
Conversation
… select permitted types; improve trustlist update reporting
…rements for application registration and trust list management
- Introduced a new configuration field `opc_gds_push_regenerate_server_key` in `OpcUaGdsPushConfig` to allow generating a new private key for each certificate renewal. - Updated the GDS push service to handle the new key regeneration logic, including nonce generation when a new key is requested. - Enhanced trust list management by reading the server's current trust list and merging it with the new entries, preserving existing trust entries and handling rejected certificates. - Updated relevant views and help pages to reflect the new configuration option and its implications. - Added tests to ensure the correct behavior of the new key regeneration feature and trust list merging.
…ey regeneration option
…nd improving certificate handling
…st items and certificate handling
…nality - Implemented a new view to download the discovered server certificate during OPC UA GDS push discovery. - Enhanced the GdsPushService to capture and encode the server certificate during endpoint discovery. - Updated the truststore association template to provide a download link for the discovered server certificate. - Added validation for the CSR identity to ensure it matches the current server certificate's identity and SANs. - Introduced logic to defer ApplyChanges until all targeted trust lists or certificates have been staged, improving transaction management. - Enhanced error handling to provide actionable hints for various status codes during trust list updates and server certificate updates.
- Introduced opc_server_url field in OpcUaGdsPushConfig to allow full endpoint URL configuration, overriding IP address and port. - Added opc_gds_push_require_crls field to enforce CRL checks during trustlist updates. - Updated forms, views, and tasks to accommodate new fields and their logic. - Enhanced GdsPushService to utilize the configured server URL and handle CRL requirements appropriately. - Added migrations for new fields and updated tests to cover new functionality and ensure proper behavior.
…rtificate update - Introduced a new configuration option `opc_gds_push_renewal_threshold_days` to specify the number of days before certificate expiration when a renewal should occur. - Updated the GDS Push service to check the renewal threshold before replacing the server certificate. - Combined the trustlist and server certificate update processes into a single operation to streamline the update workflow. - Enhanced logging to provide clearer feedback on update success or failure. - Added tests to ensure the new functionality works as expected and that the combined update process behaves correctly.
…allback - Added audit logging for GDS Push operations, attributing actions to the initiating user. - Enhanced the GDS Push service to generate and upload a private key when the server cannot. - Updated the GDS Push views to pass the user ID for audit logging. - Modified the GDS Push tasks to include user attribution in audit records. - Improved error handling and logging for certificate updates and trust list operations. - Added new migration to include GDS Push operation type in the audit log model.
…ertificates - Implemented configuration options for minimum certificate key size and rejection of SHA-1 signed certificates in the OPC UA GDS Push settings. - Enhanced domain credential renewal process to verify the new certificate against these policies before revoking the old identity. - Updated relevant tests to ensure proper validation of these new policies.
… validation modes - Added a new view for refreshing the GDS push certificate inventory. - Introduced a new mixin for GDS push operations requiring specific permissions. - Enhanced the GDS push service to support CA chain validation for server certificates. - Implemented methods for reading and validating server certificates against a truststore. - Updated the device model to store the last certificate inventory and its update timestamp. - Added new permissions for managing GDS push operations. - Created help page sections to display the certificate inventory and actions. - Added tests for the new functionality, including inventory refresh and CA validation.
…and retry logic for ApplyChanges
- Replaced in-memory device lock with a database-backed GdsPushOperationLock model to manage GDS Push operations. - Updated the _acquire_device_lock and _release_device_lock functions to use the new locking mechanism. - Refactored GdsPushService to include a reconcile method that handles trust list and certificate updates independently. - Removed the server_certificate_needs_renewal method and related logic, simplifying the renewal decision process. - Enhanced tests to cover the new reconciliation logic and locking behavior. - Added a migration to create the GdsPushOperationLock model and a new field for managing trust list fingerprints.
- Added support for OPC UA security policies in the SecurityConfig model. - Implemented parsing and validation for permitted OPC UA security policies. - Enhanced GdsPushService to select and enforce security policies based on SecurityConfig. - Migrated existing device-specific security settings into the central SecurityConfig. - Created a new module for OPC UA security policy definitions and metadata. - Updated tests to cover new security policy features and ensure compliance with SecurityConfig.
…ust list management and server validation
- Updated the `GdsPushService` to support authoritative trust-list management mode, allowing for the removal of entries not present in the desired state. - Implemented methods to compute managed state per group and verify trust-list deployment. - Added functionality to preview authoritative trust-list changes, detailing which entries would be removed. - Enhanced unit tests to cover new authoritative mode behaviors and ensure correct management of trust-list entries. - Introduced a new HTML template for displaying the authoritative trust-list preview to users. - Adjusted existing tests to accommodate changes in trust-list management logic and ensure comprehensive coverage.
|
ⓘ Qodo reviews are paused because your trial has ended. Ask your workspace admin to add credits to resume reviews. Manage billing |
❌ 2 Tests Failed:
View the top 2 failed test(s) by shortest run time
To view more test analytics, go to the Test Analytics Dashboard |
…e retrieval and update related logic
…in implementation baseline and findings
- Updated the truststore association template to provide clearer instructions regarding trust store selection and permissions for importing and retrieving truststores. - Added a new production hardening document for the Trustpoint OPC UA GDS Push, outlining a comprehensive review process for security, interoperability, and operational robustness. - Introduced a confirmation template for updating the server certificate, detailing the implications of the update and providing device information for user review.
| """ | ||
| regenerate_key = False | ||
| require_crls = False | ||
| renewal_threshold_days = 30 |
… improvements - Added Subject Alternative Name extension to CA chain generation. - Updated tests to ensure ApplyChanges and CancelChanges are correctly handled for servers without transaction support. - Refactored certificate due date checks and improved logic for determining due certificate slots. - Introduced regression tests for production-hardening findings, focusing on certificate validation and CRL handling. - Enhanced error handling for certificate updates and trustlist management, ensuring proper state management during failures. - Improved handling of CA mode certificate validation, including checks for application URI and hostname mismatches. - Added tests for secure element behavior and transient invalid states to ensure robustness in certificate management.
- Implemented tests for GDS Push Application Credential mappings, including discovery, validation, and profile management. - Created a new migration to add GdsPushCertificateMapping model and related fields to OPC UA GDS Push configuration. - Developed a new HTML template for managing Application Credential mappings, allowing users to discover groups, update credentials, and manage mappings.
… and configuration updates - Introduced advanced operations for the Certificate Manager, including support for multiple pinned server certificates, self-signed certificate creation, and managed application discovery. - Updated GdsPushService to handle multiple server certificates, improving certificate renewal and verification processes. - Added methods for reading and updating configuration files, with support for deferred confirmation of updates. - Enhanced unit tests to cover new functionalities, including self-signed certificate creation and managed application certificate handling.
|
This branch has not been deployed
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Related to #
Description of changes
Notes
Legal