boulder/wfe2
Jacob Hoffman-Andrews e198d3529d
wfe: check well-formedness of requested names early (#7530)
This allows us to give a user-meaningful error about malformed names
early on, instead of propagating internal errors from the new rate
limiting system.

This moves the well-formedness logic from `WillingToIssue` into a new
function `WellFormedDomainNames`, which calls `ValidDomain` on each name
and combines the errors into suberrors if there is more than one.
`WillingToIssue` now calls `WellFormedDomainNames` to keep the existing
behavior. Additionally, WFE calls `WellFormedDomainNames` before
checking rate limits.

This creates a slight behavior change: If an order contains both
malformed domain names and wellformed but blocked domain names,
suberrors will only be generated for the malformed domain names. This is
reflected in the changes to `TestWillingToIssue_Wildcard`.

Adds a WFE test case for receiving malformed identifiers in a new-order
request.

Follows up on #3323 and #7218

Fixes #7526

Some small incidental fixes:

- checkWildcardHostList was checking `pa.blocklist` for `nil` before
accessing `pa.wildcardExactBlocklist`. Fix that.
- move table test for WillingToIssue into a new test case for
WellFormedDomainNames
 - move two standalone test cases into the big table test
2024-06-10 13:46:55 -07:00
..
README.md Duplicate WFE to WFE2. (#2839) 2017-07-05 13:32:45 -07:00
cache.go Add account cache to WFE (#5855) 2021-12-15 11:10:23 -08:00
cache_test.go Add account cache to WFE (#5855) 2021-12-15 11:10:23 -08:00
stale.go Finish migration from int64 timestamps to timestamppb (#7142) 2023-11-27 13:37:31 -08:00
stale_test.go Finish migration from int64 timestamps to timestamppb (#7142) 2023-11-27 13:37:31 -08:00
stats.go WFE: Count NewOrders which indicate replacement (#7416) 2024-04-08 12:32:45 -04:00
verify.go Remove deprecated WFE.RedeemNonceServices (#7493) 2024-05-21 13:13:13 -04:00
verify_test.go Remove deprecated WFE.RedeemNonceServices (#7493) 2024-05-21 13:13:13 -04:00
wfe.go wfe: check well-formedness of requested names early (#7530) 2024-06-10 13:46:55 -07:00
wfe_test.go wfe: check well-formedness of requested names early (#7530) 2024-06-10 13:46:55 -07:00

README.md

WFE v2

The wfe2 package is copied from the wfe package in order to implement the "ACME v2" API. This design choice was made to facilitate a clean separation between v1 and v2 code and to support running a separate API process on a different port alongside the v1 API process.