Repository navigation
Attesto 2.3.1
Attesto 2.3.1 adds final OpenID4VP support, bounded credential encryption, and stricter signature and presentation verification. It includes the changes from 2.3.0, which was tagged but not published to Hex.
Security
- Preserve the default FAPI signing algorithm and key-strength policy when callers supply explicit allowlists, including mixed lists. Reject malformed, unknown, duplicate, and non-string entries; an empty list denies every algorithm. Broader policy requires explicit
enforce_fapi_alg_policy: false. - Enforce FAPI key-strength checks for SD-JWT issuer verification by default, including RSA moduli of at least 2048 bits for PS256.
- Verify PS256, PS384, and PS512 with the exact required PSS salt lengths and matching MGF1 hashes. Apply the same parameters to the DPoP test signing helper.
- Bind presentation responses to the requested credential-query IDs and reject unsolicited IDs before credential processing.
- Return controlled errors for malformed presentation values, including scalar values in encrypted presentation-session responses.
OpenID4VP and credential encryption
- Add an explicit
RequestObjectOpenID4VP profile that enforces request typing and client identity while ignoringiss, as required by OpenID4VP 1.0. Existing JAR issuer binding remains the default. - Require non-empty presentation arrays per query ID in
VpToken.verify/2and presentation sessions. Callers that need the earlier scalar format must selectlegacy_scalar_values: true. - Support certificate-identified SD-JWT VC credentials without
issthroughissuer_identity: :certificate, after the caller validates the issuer chain and supplies the verified leaf key. Issuer-claim validation remains the default. - Add
Attesto.JWE.encrypt/4anddecrypt/3for bounded compact credential encryption using ECDH-ES with P-256 and A128GCM or A256GCM. Callers select algorithms from trusted protocol metadata and can narrow the accepted set. - Validate encoded sizes, canonical Base64URL, duplicate protected JSON members, ephemeral public keys, GCM parameters, and key-use constraints before decryption. Compression and unsupported critical extensions are rejected; malformed input and authentication failures return controlled errors.
Install from Hex: {:attesto, "~> 2.3.1"}.