Skip to content

Add parser/dresser for naked COSE keys#341

Merged
geonnave merged 2 commits intolake-rs:mainfrom
chrysn-pull-requests:feature-336
Feb 5, 2025
Merged

Add parser/dresser for naked COSE keys#341
geonnave merged 2 commits intolake-rs:mainfrom
chrysn-pull-requests:feature-336

Conversation

@chrysn
Copy link
Copy Markdown
Member

@chrysn chrysn commented Feb 3, 2025

Implements #336, and refactors the parse_ccs() function, broadening the range of accepted items.

Closes: #336


/// Parse a COSE Key, accepting only understood fields.
///
/// This takes a decoder rather than a slice because this enables a naked decoder to asset that
Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

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

to assert* ?

Copy link
Copy Markdown
Member Author

Choose a reason for hiding this comment

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

Thanks, fixed.

@geonnave
Copy link
Copy Markdown
Collaborator

geonnave commented Feb 3, 2025

Looks good to me, left just a minor comment, then I am ready to merge.

This allows processing some generally valid cases that could not be
processed before, eg. CCSs without a KID.
@geonnave geonnave merged commit 977d352 into lake-rs:main Feb 5, 2025
@chrysn chrysn deleted the feature-336 branch February 5, 2025 11:46
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

feature: Directly ingest naked COSE key

2 participants