SignedAuthenticationData

public struct SignedAuthenticationData

Signed (with PrK_SE_AUT) representation of AuthenticationData.

  • Original idp challenge session that is signed within the authentication data

    Declaration

    Swift

    public let originalChallenge: IDPChallengeSession
  • Signed authentication data that is encrypted and sent to the server

    Declaration

    Swift

    public let signedAuthenticationData: JWT
  • Initialize SignedAuthenticationData with challenge and signed data

    Declaration

    Swift

    public init(
        originalChallenge: IDPChallengeSession,
        signedAuthenticationData: JWT
    )

    Parameters

    originalChallenge

    Original IDP challenge session

    signedAuthenticationData

    JWT containing signed authentication data

  • Serialize the signedChallenge

    Declaration

    Swift

    public func serialize() -> String

    Return Value

    ASCII Encoded String

  • Encrypt the signed authentication data using the provided public key

    Throws

    IDPError if encryption fails

    Declaration

    Swift

    public func encrypted(with publicKey: BrainpoolP256r1.KeyExchange.PublicKey,
                          using cryptoBox: IDPCrypto) throws -> JWE

    Parameters

    publicKey

    BrainpoolP256r1 public key for encryption

    cryptoBox

    IDPCrypto instance containing encryption parameters

    Return Value

    JWE containing the encrypted signed authentication data