Implement RFC 8555 Section 7.3.3 terms of service changes.#41
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Adds RFC 8555 §7.3.3 handling so the ACME server can reject newOrder requests when Terms of Service have changed since an account last agreed, and allows clients to re-agree via account update.
Changes:
- Reject
/new-orderwithuserActionRequired(HTTP 403) whenTOS.LastUpdateis newer than the account’s stored ToS acceptance timestamp. - Include
Link: <tos-url>; rel="terms-of-service"onuserActionRequiredproblem responses. - Add ACME conformance scenarios/steps and update README to document the behavior.
Reviewed changes
Copilot reviewed 7 out of 8 changed files in this pull request and generated 2 comments.
Show a summary per file
| File | Description |
|---|---|
| tests/opencertserver.certserver.tests/StepDefinitions/AcmeConformance.cs | Adds step definitions for ToS-change scenarios (reject order + re-agree via account update). |
| tests/opencertserver.certserver.tests/Features/AcmeConformance.feature | Adds new RFC 8555 §7.3.3 conformance scenarios. |
| tests/opencertserver.certserver.tests/Features/AcmeConformance.feature.cs | Updates generated Reqnroll bindings for the new feature scenarios. |
| src/opencertserver.acme.server/Filters/AcmeProtocolResponseFilter.cs | Adds Link header emission for userActionRequired errors and maps status code to 403. |
| src/opencertserver.acme.server/Endpoints/OrderEndpoints.cs | Enforces ToS update checks on /new-order and throws UserActionRequiredException. |
| src/opencertserver.acme.abstractions/Model/Account.cs | Updates ToS agreement recording to always refresh the acceptance timestamp. |
| src/opencertserver.acme.abstractions/Exceptions/UserActionRequiredException.cs | Introduces a dedicated exception for userActionRequired with optional ToS URL. |
| README.md | Documents ToS change behavior and re-agreement flow. |
Files not reviewed (1)
- tests/opencertserver.certserver.tests/Features/AcmeConformance.feature.cs: Language not supported
8eaddb2 to
a49ce71
Compare
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
Co-authored-by: Copilot Autofix powered by AI <175728472+Copilot@users.noreply.github.com>
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.
Add support for handling terms of service changes