Package-level declarations

Types

Link copied to clipboard
data class AuthenticatedCiphertext(val ciphertext: ByteArray, val authtag: ByteArray)
Link copied to clipboard
interface CryptoService
Link copied to clipboard
actual class DefaultCryptoService : CryptoService

Default implementation of a crypto service for iOS.

actual open class DefaultCryptoService : CryptoService
Link copied to clipboard
data class DefaultEphemeralKeyHolder(val publicKey: SecKeyRef, val privateKey: SecKeyRef? = null) : EphemeralKeyHolder
Link copied to clipboard
actual class DefaultVerifierCryptoService : VerifierCryptoService
actual open class DefaultVerifierCryptoService : VerifierCryptoService
Link copied to clipboard
enum Digest : Enum<Digest>
Link copied to clipboard
Link copied to clipboard
class FixedTimeClock(epochMilliseconds: Long) : Clock
Link copied to clipboard
interface Holder

Summarizes operations for a Holder in the sense of the W3C VC Data Model.

Link copied to clipboard
class HolderAgent(validator: Validator = Validator.newDefaultInstance(), subjectCredentialStore: SubjectCredentialStore = InMemorySubjectCredentialStore(), jwsService: JwsService, keyId: String) : Holder

An agent that only implements Holder, i.e. it can receive credentials form other agents and present credentials to other agents.

Link copied to clipboard
sealed class InternalNextMessage
Link copied to clipboard
class IssueCredentialProtocol(issuer: Issuer? = null, holder: Holder? = null, keyId: String, serviceEndpoint: String? = null, credentialScheme: ConstantIndex.CredentialScheme) : ProtocolStateMachine<IssueCredentialProtocolResult>

Use this class for exactly one instance of a protocol run.

Link copied to clipboard
interface Issuer

Summarizes operations for a Issuer in the sense of the W3C VC Data Model.

Link copied to clipboard
class IssuerAgent(validator: Validator, issuerCredentialStore: IssuerCredentialStore = InMemoryIssuerCredentialStore(), revocationListBaseUrl: String = "https://wallet.a-sit.at/backend/credentials/status", dataProvider: IssuerCredentialDataProvider = EmptyCredentialDataProvider, zlibService: ZlibService = DefaultZlibService(), revocationListLifetime: Duration = 48.hours, jwsService: JwsService, clock: Clock = Clock.System, keyId: String, timePeriodProvider: TimePeriodProvider = FixedTimePeriodProvider) : Issuer

An agent that only implements Issuer, i.e. it issues credentials for other agents.

Link copied to clipboard

Provides data for credentials to be issued.

Link copied to clipboard

Stores all issued credentials, keeps track of the index for the revocation list

Link copied to clipboard
open class JvmEphemeralKeyHolder(ecCurve: EcCurve) : EphemeralKeyHolder
Link copied to clipboard
class MessageWrapper(cryptoService: CryptoService, jwsService: JwsService = DefaultJwsService(cryptoService), verifierJwsService: VerifierJwsService = DefaultVerifierJwsService())
Link copied to clipboard
sealed class NextMessage
Link copied to clipboard
class OidcSiopProtocol(holder: Holder? = null, verifier: Verifier? = null, agentPublicKey: JsonWebKey, jwsService: JwsService, verifierJwsService: VerifierJwsService, relyingPartyChallenge: String = uuid4().toString(), walletUrl: String = "https://wallet.a-sit.at/mobile", relyingPartyUrl: String = "https://wallet.a-sit.at/verifier", timeLeewaySeconds: Long = 300, clock: Clock = Clock.System)

Combines Verifiable Presentations with OpenId Connect Implements OIDC for VP as well as SIOP V2.

Link copied to clipboard
class Parser(timeLeewaySeconds: Long = 300, epochMillisecondsForValidation: Long? = null)

Parses Verifiable Credentials and Verifiable Presentations. Does not verify the cryptographic authenticity of the data. Does not verify the revocation status of the data.

Link copied to clipboard
class PresentProofProtocol(holder: Holder? = null, verifier: Verifier? = null, requestedAttributeNames: List<String>? = null, credentialScheme: ConstantIndex.CredentialScheme, keyId: String, serviceEndpoint: String?, challengeForPresentation: String) : ProtocolStateMachine<PresentProofProtocolResult>

Use this class for exactly one instance of a protocol run.

Link copied to clipboard
Link copied to clipboard
abstract class ProtocolMessenger<T : ProtocolStateMachine<U>, U>(messageWrapper: MessageWrapper, createProtocolWhenNotActive: Boolean = true, signInitialMessage: Boolean = true, signFollowingMessages: Boolean = true, signAndEncryptFollowingMessages: Boolean = true, protocolRunManager: ProtocolRunManager<T, U> = ProtocolRunManager())

Allows for multiplexing of several active runs of a message protocol

Link copied to clipboard
class ProtocolRunManager<T : ProtocolStateMachine<U>, U>(timeoutDuration: Duration = 60.minutes)

Holds a list of protocol runs for ProtocolMessenger, handling concurrency with a lock, as well as cleaning up old (client did not send a message again) and finished runs.

Link copied to clipboard

Use this class for exactly one instance of a protocol run.

Link copied to clipboard
sealed class ReceivedMessage
Link copied to clipboard

Stores all credentials that a subject has received

Link copied to clipboard
Link copied to clipboard
class Validator(verifierJwsService: VerifierJwsService = DefaultVerifierJwsService(DefaultVerifierCryptoService()), parser: Parser = Parser(), zlibService: ZlibService = DefaultZlibService())

Parses and validates Verifiable Credentials and Verifiable Presentations. Does verify the cryptographic authenticity of the data, if a verifierJwsService is set on creation. Does verify the revocation status of the data.

Link copied to clipboard
interface Verifier

Summarizes operations for a Verifier in the sense of the W3C VC Data Model.

Link copied to clipboard

An agent that only implements Verifier, i.e. it can only verify credentials of other agents.

Link copied to clipboard

Functions

Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
Link copied to clipboard
fun NSData.toByteArray(): ByteArray
Link copied to clipboard
inline fun MemScope.toData(array: ByteArray): NSData

Properties