8000 Refactor Certificate handling by Apollon77 · Pull Request #2169 · project-chip/matter.js · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

Refactor Certificate handling #2169

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 3 commits into from
Jun 18, 2025
Merged

Refactor Certificate handling #2169

merged 3 commits into from
Jun 18, 2025

Conversation

Apollon77
Copy link
Collaborator

The PR prepares more changes for certificates when we incorporate DCL and mainly splits the CertificateManager's down into smaller pieces.

The PR prepares more changes for certificates when we incorporate DCL and mainly splits the CertificateManager's down into smaller pieces.
Copy link
Contributor
@gemini-code-assist gemini-code-assist bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request significantly refactors certificate handling by breaking down the monolithic CertificateManager into a more modular structure with specialized classes for different certificate types (RCAC, ICAC, NOC, PAA, PAI, DAC) and a new base class X509Base for common X.509 operations. This improves code organization, maintainability, and clarity. The changes also include updates to how certificates are generated, encoded, and verified across various parts of the protocol.

Key improvements:

  • Introduction of X509Base for core X.509 logic, including CSR handling.
  • Specialized classes for operational certificates (Rcac, Icac, Noc) and attestation certificates (Paa, Pai, Dac).
  • Centralized TLV and ASN.1 definitions.
  • Updated tests to reflect the new structure.

I've identified a few areas for attention, including a couple of TODOs that should be addressed for completeness and a potential issue in ICAC key usage verification.

@Apollon77 Apollon77 added the automerge Set this label if the PR is ready to automatically merged after approval label Jun 18, 2025
@mergify mergify bot merged commit df2264f into main Jun 18, 2025
47 checks passed
@mergify mergify bot deleted the cert-refactor branch June 18, 2025 20:00
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
automerge Set this label if the PR is ready to automatically merged after approval review - approved
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants
0