fromSignedRequest
suspend fun fromSignedRequest(certChain: X509CertChain, clientId: String): OpenID4VPRequesterIdentity
Creates the identity of a signer of an OpenID4VP request, checking that clientId is bound to certChain as required by its Client Identifier Prefix.
For the x509_san_dns prefix, OpenID4VP 1.0 Section 5.9.3 requires the Client Identifier without the prefix to match a dNSName subject alternative name of the leaf certificate. For the x509_hash prefix, OpenID4VP 1.0 Section 5.9.3 requires the Client Identifier without the prefix to match the base64url-encoded SHA-256 hash of the DER-encoded leaf certificate. Other prefixes are not checked.
Return
the identity.
Parameters
certChain
the certificate chain the request was signed with, leaf certificate first.
clientId
the client_id of the request.