mirror of
https://github.com/apple/swift-crypto
synced 2026-11-24 04:37:48 +00:00
### Motivation The latest draft of the ARC spec[0] includes moving where the presentation limit is used. Before it was baked in when a client constructed a credential request, but now it has moved to when a client makes a presentation from a finalized credential. This PR updates the internals and API surface to reflect this change. ### Modifications - Defer passing the presentation limit until a presentation is made. ### Result Align more closely with the published draft. ### API breakage It's expected that this will result in the following _breaking_ API changes: ```diff - P384._ARCV1.PublicKey.prepareCredentialRequest(requestContext:presentationLimit:) + P384._ARCV1.PublicKey.prepareCredentialRequest(requestContext:) ``` ```diff - P384._ARCV1.Credential.makePresentation(context:) + P384._ARCV1.Credential.makePresentation(context:presentationLimit:) ``` As this is behind an underscored namespace, we deem this an acceptable break. [0]: https://datatracker.ietf.org/doc/draft-yun-cfrg-arc/