Skip to content

Feature: Support documents#1

Open
sephynox wants to merge 4 commits intomainfrom
feature/attribute-updates
Open

Feature: Support documents#1
sephynox wants to merge 4 commits intomainfrom
feature/attribute-updates

Conversation

@sephynox
Copy link
Collaborator

@sephynox sephynox commented Dec 4, 2025

Supports updates ASN.1 types.

@sephynox sephynox self-assigned this Dec 4, 2025
@sephynox sephynox added the enhancement New feature or request label Dec 4, 2025
Copy link

Copilot AI left a comment

Choose a reason for hiding this comment

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

Pull request overview

This PR adds support for document-related ASN.1 types in the keetanetwork-asn1 codebase, introducing new data structures for identity documents (passport, driver's license, ID cards, etc.) along with supporting types for references, digests, and person identification. The changes include significant refactoring of the build script to better handle extension types and improve code maintainability.

Key Changes:

  • Added new Document ASN.1 type with 7 document subtypes (driver's license, passport, ID card, visa, etc.) to support identity verification workflows
  • Introduced supporting types (Reference, DigestInfo, ExternalReference) for handling external document references with encryption and digest information
  • Refactored build.rs Default implementation generation into reusable helper functions with improved enum type detection
  • Made breaking API changes to EntityType (CHOICE → SEQUENCE) and PersonIdentificationSchemeNameChoice (UTF8String → ENUMERATED)

Reviewed changes

Copilot reviewed 5 out of 5 changed files in this pull request and generated 7 comments.

Show a summary per file
File Description
keetanetwork-asn1/oids.json Added Document type with 21 fields and 7 document subtypes; added name components (firstName, lastName, middleName), nationality, and PersonIdentificationSchemeNameProprietary enum; changed EntityType from CHOICE to SEQUENCE; reformatted for readability
keetanetwork-asn1/build.rs Added generate_extension_types() function for processing extension types with dependency sorting; refactored Default implementation generation into helper functions (get_ordered_field_names, collect_enumerated_types, generate_field_defaults); added rustfmt call to format generated code
keetanetwork-asn1/asn1/iso20022.asn Added ASN.1 definitions for DigestInfo, ExternalReference, Reference, Document, and moved EntityType definition; added FirstName, LastName, MiddleName, Nationality primitives; added PersonIdentificationSchemeNameProprietary enumeration
Makefile Replaced emoji characters with plain text prefixes (ERROR, WARNING, PASS, FAIL) for better terminal compatibility; adjusted indentation for alignment
keetanetwork-x509/src/utils.rs Changed test vector from vec![] to array literal [] for minor performance improvement

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@sonarqubecloud
Copy link

sonarqubecloud bot commented Dec 4, 2025

@sephynox sephynox requested a review from Srayman December 18, 2025 17:57
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

enhancement New feature or request

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants