@sphereon/ssi-sdk-ext.jwt-service
Version:
1,251 lines (1,250 loc) • 1.48 MB
JSON
{
"IJwtService": {
"components": {
"schemas": {
"CreateJwsCompactArgs": {
"$ref": "#/components/schemas/CreateJwsArgs"
},
"CreateJwsArgs": {
"type": "object",
"properties": {
"mode": {
"$ref": "#/components/schemas/JwsIdentifierMode"
},
"issuer": {
"anyOf": [
{
"type": "object",
"properties": {
"noIssPayloadUpdate": {
"type": "boolean"
},
"noIdentifierInHeader": {
"type": "boolean"
},
"lazyDisabled": {
"type": "boolean"
},
"jwk": {
"type": "object",
"properties": {
"kty": {
"type": "string",
"enum": [
"EC",
"RSA",
"oct",
"OKP"
]
},
"crv": {
"type": "string",
"enum": [
"P-256",
"P-384",
"P-521",
"X25519",
"X448",
"EdDSA",
"Ed25519",
"Ed448",
"secp256k1"
]
},
"alg": {
"type": "string",
"enum": [
"RS256",
"RS384",
"RS512",
"ES256",
"ES256K",
"ES384",
"ES512",
"EdDSA",
"HS256",
"HS384",
"HS512",
"PS256",
"PS384",
"PS512",
"none"
]
},
"x": {
"type": "string"
},
"y": {
"type": "string"
},
"e": {
"type": "string"
},
"n": {
"type": "string"
},
"d": {
"type": "string"
},
"dp": {
"type": "string"
},
"dq": {
"type": "string"
},
"ext": {
"type": "boolean"
},
"k": {
"type": "string"
},
"key_ops": {
"type": "array",
"items": {
"type": "string",
"enum": [
"sign",
"verify",
"encrypt",
"decrypt",
"wrapKey",
"unwrapKey",
"deriveKey",
"deriveBits"
]
}
},
"kid": {
"type": "string"
},
"oth": {
"type": "array",
"items": {
"type": "object",
"properties": {
"d": {
"type": "string"
},
"r": {
"type": "string"
},
"t": {
"type": "string"
}
}
}
},
"p": {
"type": "string"
},
"q": {
"type": "string"
},
"qi": {
"type": "string"
},
"use": {
"type": "string"
},
"x5c": {
"type": "array",
"items": {
"type": "string"
},
"description": "JWK \"x5c\" (X.509 Certificate Chain) Parameter."
},
"x5t": {
"type": "string",
"description": "JWK \"x5t\" (X.509 Certificate SHA-1 Thumbprint) Parameter."
},
"x5t#S256": {
"type": "string",
"description": "\"x5t#S256\" (X.509 Certificate SHA-256 Thumbprint) Parameter."
},
"x5u": {
"type": "string",
"description": "JWK \"x5u\" (X.509 URL) Parameter."
},
"iv": {
"type": "string"
}
},
"additionalProperties": {},
"required": [
"kty"
]
},
"jwkThumbprint": {
"type": "string"
},
"kmsKeyRef": {
"type": "string"
},
"method": {
"type": "string",
"const": "x5c"
},
"opts": {
"anyOf": [
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "jwk"
},
"identifier": {
"type": "object",
"properties": {
"kty": {
"type": "string",
"enum": [
"EC",
"RSA",
"oct",
"OKP"
]
},
"crv": {
"type": "string",
"enum": [
"P-256",
"P-384",
"P-521",
"X25519",
"X448",
"EdDSA",
"Ed25519",
"Ed448",
"secp256k1"
]
},
"alg": {
"type": "string",
"enum": [
"RS256",
"RS384",
"RS512",
"ES256",
"ES256K",
"ES384",
"ES512",
"EdDSA",
"HS256",
"HS384",
"HS512",
"PS256",
"PS384",
"PS512",
"none"
]
},
"x": {
"type": "string"
},
"y": {
"type": "string"
},
"e": {
"type": "string"
},
"n": {
"type": "string"
},
"d": {
"type": "string"
},
"dp": {
"type": "string"
},
"dq": {
"type": "string"
},
"ext": {
"type": "boolean"
},
"k": {
"type": "string"
},
"key_ops": {
"type": "array",
"items": {
"type": "string",
"enum": [
"sign",
"verify",
"encrypt",
"decrypt",
"wrapKey",
"unwrapKey",
"deriveKey",
"deriveBits"
]
}
},
"kid": {
"type": "string"
},
"oth": {
"type": "array",
"items": {
"type": "object",
"properties": {
"d": {
"type": "string"
},
"r": {
"type": "string"
},
"t": {
"type": "string"
}
}
}
},
"p": {
"type": "string"
},
"q": {
"type": "string"
},
"qi": {
"type": "string"
},
"use": {
"type": "string"
},
"x5c": {
"type": "array",
"items": {
"type": "string"
},
"description": "JWK \"x5c\" (X.509 Certificate Chain) Parameter."
},
"x5t": {
"type": "string",
"description": "JWK \"x5t\" (X.509 Certificate SHA-1 Thumbprint) Parameter."
},
"x5t#S256": {
"type": "string",
"description": "\"x5t#S256\" (X.509 Certificate SHA-256 Thumbprint) Parameter."
},
"x5u": {
"type": "string",
"description": "JWK \"x5u\" (X.509 URL) Parameter."
},
"iv": {
"type": "string"
}
},
"additionalProperties": {},
"required": [
"kty"
]
},
"kmsKeyRef": {
"type": "string"
},
"issuer": {
"type": "string"
},
"kid": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
}
},
"required": [
"identifier"
]
},
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "x5c"
},
"identifier": {
"type": "array",
"items": {
"type": "string"
}
},
"kmsKeyRef": {
"type": "string"
},
"issuer": {
"type": "string"
},
"kid": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
}
},
"required": [
"identifier"
]
},
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "did"
},
"identifier": {
"anyOf": [
{
"$ref": "#/components/schemas/IIdentifier"
},
{
"type": "string"
}
]
},
"kmsKeyRef": {
"type": "string"
},
"issuer": {
"type": "string"
},
"kid": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
},
"keyType": {
"$ref": "#/components/schemas/TKeyType"
},
"offlineWhenNoDIDRegistered": {
"type": "boolean"
},
"noVerificationMethodFallback": {
"type": "boolean"
},
"controllerKey": {
"type": "boolean"
},
"vmRelationship": {
"$ref": "#/components/schemas/DIDDocumentSection"
}
},
"required": [
"identifier"
]
},
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "kid"
},
"identifier": {
"type": "string"
},
"kmsKeyRef": {
"type": "string"
},
"issuer": {
"type": "string"
},
"kid": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
}
},
"required": [
"identifier"
]
},
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "key"
},
"identifier": {
"$ref": "#/components/schemas/IKey"
},
"kmsKeyRef": {
"type": "string"
},
"issuer": {
"type": "string"
},
"kid": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
}
},
"required": [
"identifier"
]
},
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "cose_key"
},
"identifier": {
"type": "object",
"properties": {
"kty": {
"type": "number",
"enum": [
1,
2,
3,
4,
0
]
},
"kid": {
"type": "string"
},
"alg": {
"type": "number",
"enum": [
-7,
-47,
-35,
-36,
-8,
4,
5,
6,
7,
-37,
-38,
-39
]
},
"key_ops": {
"type": "array",
"items": {
"type": "number",
"enum": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10
]
}
},
"baseIV": {
"type": "string"
},
"crv": {
"type": "number",
"enum": [
1,
2,
3,
4,
5,
6,
7,
-1
]
},
"x": {
"type": "string"
},
"y": {
"type": "string"
},
"d": {
"type": "string"
},
"x5chain": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"kty"
],
"additionalProperties": {},
"description": "See our mdl-mdoc and crypto library for more information https://github.com/Sphereon-Opensource/mdoc-cbor-crypto-multiplatform\n\nConversion functions are available in above library. Conversion functions are also available for TS in our"
},
"kmsKeyRef": {
"type": "string"
},
"issuer": {
"type": "string"
},
"kid": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
}
},
"required": [
"identifier"
]
},
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "oid4vci-issuer"
},
"identifier": {
"type": "string"
},
"kmsKeyRef": {
"type": "string"
},
"issuer": {
"type": "string"
},
"kid": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
}
},
"required": [
"identifier"
]
}
]
},
"key": {
"$ref": "#/components/schemas/IKey"
},
"kid": {
"type": "string"
},
"issuer": {
"type": "string"
},
"clientId": {
"type": "string"
},
"clientIdScheme": {
"type": "string"
},
"identifier": {
"anyOf": [
{
"$ref": "#/components/schemas/IIdentifier"
},
{
"type": "string"
},
{
"type": "array",
"items": {
"type": "string"
}
},
{
"type": "object",
"properties": {
"kty": {
"type": "string",
"enum": [
"EC",
"RSA",
"oct",
"OKP"
]
},
"crv": {
"type": "string",
"enum": [
"P-256",
"P-384",
"P-521",
"X25519",
"X448",
"EdDSA",
"Ed25519",
"Ed448",
"secp256k1"
]
},
"alg": {
"type": "string",
"enum": [
"RS256",
"RS384",
"RS512",
"ES256",
"ES256K",
"ES384",
"ES512",
"EdDSA",
"HS256",
"HS384",
"HS512",
"PS256",
"PS384",
"PS512",
"none"
]
},
"x": {
"type": "string"
},
"y": {
"type": "string"
},
"e": {
"type": "string"
},
"n": {
"type": "string"
},
"d": {
"type": "string"
},
"dp": {
"type": "string"
},
"dq": {
"type": "string"
},
"ext": {
"type": "boolean"
},
"k": {
"type": "string"
},
"key_ops": {
"type": "array",
"items": {
"type": "string",
"enum": [
"sign",
"verify",
"encrypt",
"decrypt",
"wrapKey",
"unwrapKey",
"deriveKey",
"deriveBits"
]
}
},
"kid": {
"type": "string"
},
"oth": {
"type": "array",
"items": {
"type": "object",
"properties": {
"d": {
"type": "string"
},
"r": {
"type": "string"
},
"t": {
"type": "string"
}
}
}
},
"p": {
"type": "string"
},
"q": {
"type": "string"
},
"qi": {
"type": "string"
},
"use": {
"type": "string"
},
"x5c": {
"type": "array",
"items": {
"type": "string"
},
"description": "JWK \"x5c\" (X.509 Certificate Chain) Parameter."
},
"x5t": {
"type": "string",
"description": "JWK \"x5t\" (X.509 Certificate SHA-1 Thumbprint) Parameter."
},
"x5t#S256": {
"type": "string",
"description": "\"x5t#S256\" (X.509 Certificate SHA-256 Thumbprint) Parameter."
},
"x5u": {
"type": "string",
"description": "JWK \"x5u\" (X.509 URL) Parameter."
},
"iv": {
"type": "string"
}
},
"additionalProperties": {},
"required": [
"kty"
]
},
{
"$ref": "#/components/schemas/IKey"
},
{
"type": "object",
"properties": {
"kty": {
"type": "number",
"enum": [
1,
2,
3,
4,
0
]
},
"kid": {
"type": "string"
},
"alg": {
"type": "number",
"enum": [
-7,
-47,
-35,
-36,
-8,
4,
5,
6,
7,
-37,
-38,
-39
]
},
"key_ops": {
"type": "array",
"items": {
"type": "number",
"enum": [
1,
2,
3,
4,
5,
6,
7,
8,
9,
10
]
}
},
"baseIV": {
"type": "string"
},
"crv": {
"type": "number",
"enum": [
1,
2,
3,
4,
5,
6,
7,
-1
]
},
"x": {
"type": "string"
},
"y": {
"type": "string"
},
"d": {
"type": "string"
},
"x5chain": {
"type": "array",
"items": {
"type": "string"
}
}
},
"required": [
"kty"
],
"additionalProperties": {},
"description": "See our mdl-mdoc and crypto library for more information https://github.com/Sphereon-Opensource/mdoc-cbor-crypto-multiplatform\n\nConversion functions are available in above library. Conversion functions are also available for TS in our"
}
],
"description": "Use whenever we need to pass in an identifier. We can pass in kids, DIDs, IIdentifier objects and x5chains\n\nThe functions below can be used to check the type, and they also provide the proper 'runtime' types"
},
"x5c": {
"type": "array",
"items": {
"type": "string"
}
},
"certificate": {}
},
"required": [
"certificate",
"identifier",
"jwk",
"jwkThumbprint",
"key",
"kmsKeyRef",
"method",
"opts",
"x5c"
]
},
{
"type": "object",
"properties": {
"noIssPayloadUpdate": {
"type": "boolean"
},
"noIdentifierInHeader": {
"type": "boolean"
},
"lazyDisabled": {
"type": "boolean"
},
"jwk": {
"type": "object",
"properties": {
"kty": {
"type": "string",
"enum": [
"EC",
"RSA",
"oct",
"OKP"
]
},
"crv": {
"type": "string",
"enum": [
"P-256",
"P-384",
"P-521",
"X25519",
"X448",
"EdDSA",
"Ed25519",
"Ed448",
"secp256k1"
]
},
"alg": {
"type": "string",
"enum": [
"RS256",
"RS384",
"RS512",
"ES256",
"ES256K",
"ES384",
"ES512",
"EdDSA",
"HS256",
"HS384",
"HS512",
"PS256",
"PS384",
"PS512",
"none"
]
},
"x": {
"type": "string"
},
"y": {
"type": "string"
},
"e": {
"type": "string"
},
"n": {
"type": "string"
},
"d": {
"type": "string"
},
"dp": {
"type": "string"
},
"dq": {
"type": "string"
},
"ext": {
"type": "boolean"
},
"k": {
"type": "string"
},
"key_ops": {
"type": "array",
"items": {
"type": "string",
"enum": [
"sign",
"verify",
"encrypt",
"decrypt",
"wrapKey",
"unwrapKey",
"deriveKey",
"deriveBits"
]
}
},
"kid": {
"type": "string"
},
"oth": {
"type": "array",
"items": {
"type": "object",
"properties": {
"d": {
"type": "string"
},
"r": {
"type": "string"
},
"t": {
"type": "string"
}
}
}
},
"p": {
"type": "string"
},
"q": {
"type": "string"
},
"qi": {
"type": "string"
},
"use": {
"type": "string"
},
"x5c": {
"type": "array",
"items": {
"type": "string"
},
"description": "JWK \"x5c\" (X.509 Certificate Chain) Parameter."
},
"x5t": {
"type": "string",
"description": "JWK \"x5t\" (X.509 Certificate SHA-1 Thumbprint) Parameter."
},
"x5t#S256": {
"type": "string",
"description": "\"x5t#S256\" (X.509 Certificate SHA-256 Thumbprint) Parameter."
},
"x5u": {
"type": "string",
"description": "JWK \"x5u\" (X.509 URL) Parameter."
},
"iv": {
"type": "string"
}
},
"additionalProperties": {},
"required": [
"kty"
]
},
"jwkThumbprint": {
"type": "string"
},
"kmsKeyRef": {
"type": "string"
},
"method": {
"type": "string",
"const": "did"
},
"opts": {
"anyOf": [
{
"type": "object",
"properties": {
"method": {
"type": "string",
"const": "jwk"
},
"identifier": {
"type": "object",
"properties": {
"kty": {
"type": "string",
"enum": [
"EC",
"RSA",
"oct",
"OKP"
]
},
"crv": {
"type": "string",
"enum": [
"P-256",
"P-384",
"P-521",
"X25519",
"X448",
"EdDSA",
"Ed25519",
"Ed448",
"secp256k1"
]
},
"alg": {
"type": "string",
"enum": [
"RS256",
"RS384",
"RS512",
"ES256",
"ES256K",
"ES384",
"ES512",
"EdDSA",
"HS256",
"HS384",
"HS512",
"PS256",
"PS384",
"PS512",
"none"
]
},
"x": {
"type": "string"
},
"y": {
"type": "string"
},
"e": {
"type": "string"
},
"n": {
"type": "string"
},
"d": {
"type": "string"
},
"dp": {
"type": "string"
},
"dq": {
"type": "string"
},
"ext": {
"type": "boolean"
},
"k": {
"type": "string"
},
"key_ops": {
"type": "array",
"items": {
"type": "string",
"enum": [
"sign",
"verify",
"encrypt",
"decrypt",
"wrapKey",
"unwrapKey",
"deriveKey",
"deriveBits"
]
}
},
"kid": {
"type": "string"
},
"oth": {
"type": "array",
"items": {
"type": "object",
"properties": {
"d": {
"type": "string"
},
"r": {
"type": "string"
},
"t": {
"type": "string"
}
}
}
},
"p": {
"type": "string"
},
"q": {
"type": "string"
},
"qi": {
"type": "string"
},
"use": {
"type": "string"