-
Notifications
You must be signed in to change notification settings - Fork 19
ACME: allow specifying preferred or required profile. #71
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
Conversation
There was a problem hiding this 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 the ACME Profiles Extension (draft-ietf-acme-profiles-00), allowing users to request specific certificate profiles from ACME servers. The implementation provides two modes: preferred profiles (gracefully degrade if unsupported) and required profiles (fail if unsupported).
Key changes:
- Added
profiledirective toacme_issuerconfiguration with optionalrequireparameter - Implemented profile validation during account registration and certificate ordering
- Added comprehensive test coverage for both default and short-lived certificate profiles
Reviewed Changes
Copilot reviewed 7 out of 7 changed files in this pull request and generated 3 comments.
Show a summary per file
| File | Description |
|---|---|
| t/acme_profiles.t | Adds test suite verifying profile functionality with default and short-lived certificates |
| src/conf/issuer.rs | Defines Profile enum and adds profile field to Issuer struct |
| src/conf.rs | Implements profile directive configuration parser supporting 1-2 arguments |
| src/acme/types.rs | Extends ACME types to include profiles in directory metadata, order requests, and error handling |
| src/acme/error.rs | Adds profile-related error variant to NewAccountError |
| src/acme.rs | Implements profile validation logic and includes profile in order requests |
| README.md | Documents the new profile directive and references the ACME Profiles Extension specification |
Tip: Customize your code reviews with copilot-instructions.md. Create the file or learn how to get started.
b0a3303 to
72ef19b
Compare
ensh63
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
BTreeMap looks slightly overwhelmed solution for such a small collection as profile list, but it has predefined de-serialization support. So, this is a reasonable choice.
Looks good overall.
72ef19b to
7a5e27a
Compare
|
The latest fixup updates handling of required profiles and invalidProfile errors:
|
ff993dd to
1dbe801
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
Copilot reviewed 8 out of 8 changed files in this pull request and generated 3 comments.
💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.
This change implements [draft-ietf-acme-profiles] version 00. [draft-ietf-acme-profiles]: https://datatracker.ietf.org/doc/draft-ietf-acme-profiles/ Fixes: nginx#4.
1dbe801 to
a6abe56
Compare
xeioex
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM.
Merging all 3 patches into 1 seems more natural to me, but YMMV.
Taking suggestions for directive syntax or documentation. I want to keep the
--preferred-profile/--required-profiledistinction, but maybe that's not the best way.Verified working with:
shortlivedand IP identifiersCurious testing artifact:
Which doesn't quite look like
urn:ietf:params:acme:error:invalidProfile. Neither ismalformedfrom Pebble.