createJwtKeyAttestation

suspend fun createJwtKeyAttestation(signingKey: AsymmetricKey, attestationIssuer: String, keysToAttest: List<KeyIdAndAttestation>, challenge: String, userAuthentication: List<String>? = null, keyStorage: List<String>? = null): String

Generates JWT implementing OpenID4VCI Appendix D.1. "Key Attestation in JWT format".

Unlike platform key attestation in KeyAttestation, his attestation is standard and platform-neutral, but it generally cannot be generated on the platform itself in fully trustworthy manner.

Return

key attestation in JWT format

Parameters

signingKey

private key to sign the key attestation

attestationIssuer

key attestation issuer identifier

keysToAttest

list of private keys to attests with their platform attestations

challenge

(a.k.a c_nonce in OpenID4VCI spec)

userAuthentication

list of values for user_authentication claim (if any)

keyStorage

list of values for key_storage claim (if any)