Repository navigation
fix: write certificate chains with Unicode subjects - #14
Merged
Merged
Conversation
ancwrd1
approved these changes
Oct 13, 2026
Owner
|
Thanks for the fix. |
Contributor
Author
|
Thanks for the quick merge! Any chance for 0.4.1 release? |
Owner
|
Sure, released. |
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.
Writing a key chain fails when a certificate subject contains a supplementary Unicode character, even though that subject is valid UTF8String data in the certificate. The writer currently copies each subject into a BMPString
friendlyNameattribute.Omit that optional generated attribute when the subject cannot be represented as BMPString. Preserve certificate DER, private-key DER, and local key IDs so leaf association and chain construction continue to work. Explicit aliases still require BMP characters, and BMP subjects keep their existing labels.
Add an OpenSSL-generated Unicode leaf/CA fixture and regression tests for round trips and explicit alias rejection. The fixture contains disposable test keys and has a regeneration script; OpenSSL is not required to build or run the tests.
Validation on Rust 1.92:
cargo test --workspace --offline: passed, including integration tests and doctests.cargo clippy --workspace --examples --tests --offline -- -D warnings: passed.cargo fmt --all -- --check: passed.SecretSpec needs this fix to rewrap imported PKCS#12 identities without restricting certificate subjects to BMP characters. A bugfix release containing it would let SecretSpec use the registry dependency instead of a temporary Git pin.