diff --git a/sdjwt/pex.py b/sdjwt/pex.py index 64234ae..551113a 100644 --- a/sdjwt/pex.py +++ b/sdjwt/pex.py @@ -88,6 +88,25 @@ class PresentationDefinition(BaseModel): "id": {"type": "string"}, "name": {"type": "string"}, "purpose": {"type": "string"}, + "format": { + "$schema": "http://json-schema.org/draft-07/schema#", + "title": "Presentation Definition Claim Format Designations", + "type": "object", + "additionalProperties": False, + "patternProperties": { + "mso_mdoc": { + "type": "object", + "additionalProperties": False, + "properties": { + "alg": { + "type": "array", + "minItems": 1, + "items": {"type": "string", "enum": ["ES256"]}, + } + }, + } + }, + }, "constraints": { "type": "object", "additionalProperties": False, @@ -143,6 +162,17 @@ class PresentationDefinition(BaseModel): } }, }, + "mso_mdoc": { + "type": "object", + "additionalProperties": False, + "properties": { + "alg": { + "type": "array", + "minItems": 1, + "items": {"type": "string", "enum": ["ES256"]}, + } + }, + }, }, }, }, @@ -197,6 +227,7 @@ class PresentationDefinitionValidationError(Exception): "vc+sd-jwt", "vp+sd-jwt", "sd-jwt", + "mso_mdoc", ], }, },