SdJwtKb

class SdJwtKb

A SD-JWT+KB according to draft-ietf-oauth-selective-disclosure-jwt.

When a SdJwtKb instance is initialized, cursory checks on the provided string with compact serialization are performed. Full verification of the SD-JWT+KB can be done using the verify method.

A wallet can create an instance of this class by using one of the SdJwt.present methods and can then send compactSerialization to a verifier via e.g. OpenID4VP.

This class is immutable.

Throws

if the given compact serialization is malformed.

Types

Link copied to clipboard
object Companion

Properties

Link copied to clipboard

the compact serialization of the SD-JWT+KB.

Link copied to clipboard
val jwtBody: JsonObject

The body of the SD-JWT+KB.

Link copied to clipboard

The SD-JWT part of the SD-JWT+KB.

Functions

Link copied to clipboard
suspend fun verify(issuerKey: EcPublicKey, checkNonce: (nonce: String) -> Boolean, checkAudience: (audience: String) -> Boolean, checkCreationTime: (creationTime: Instant) -> Boolean): JsonObject

Verifies a SD-JWT+KB according to Section 7.3 of the SD-JWT specification