Skip to content

Commit

Permalink
Revert presentation request metadata and restrictions changes
Browse files Browse the repository at this point in the history
Signed-off-by: jamshale <[email protected]>
  • Loading branch information
jamshale committed Dec 18, 2024
1 parent 3581b01 commit 5920e8f
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 7 deletions.
12 changes: 6 additions & 6 deletions acapy_agent/anoncreds/models/presentation_request.py
Original file line number Diff line number Diff line change
Expand Up @@ -47,7 +47,7 @@ class AnoncredsPresentationReqPredSpecSchema(OpenAPISchema):
fields.Dict(
keys=fields.Str(
validate=validate.Regexp(
"^schema_id|schema_issuer_id|schema_name|schema_version|issuer_id|"
"^schema_id|schema_issuer_did|schema_name|schema_version|issuer_did|"
"cred_def_id|attr::.+::value$"
),
metadata={"example": "cred_def_id"},
Expand All @@ -58,8 +58,8 @@ class AnoncredsPresentationReqPredSpecSchema(OpenAPISchema):
metadata={
"description": (
"If present, credential must satisfy one of given restrictions: specify"
" schema_id, schema_issuer_id, schema_name, schema_version,"
" issuer_id, cred_def_id, and/or attr::<attribute-name>::value where"
" schema_id, schema_issuer_did, schema_name, schema_version,"
" issuer_did, cred_def_id, and/or attr::<attribute-name>::value where"
" <attribute-name> represents a credential attribute name"
)
},
Expand Down Expand Up @@ -113,7 +113,7 @@ class AnoncredsPresentationReqAttrSpecSchema(OpenAPISchema):
fields.Dict(
keys=fields.Str(
validate=validate.Regexp(
"^schema_id|schema_issuer_id|schema_name|schema_version|issuer_id|"
"^schema_id|schema_issuer_did|schema_name|schema_version|issuer_did|"
"cred_def_id|attr::.+::value$"
),
metadata={"example": "cred_def_id"},
Expand All @@ -124,8 +124,8 @@ class AnoncredsPresentationReqAttrSpecSchema(OpenAPISchema):
metadata={
"description": (
"If present, credential must satisfy one of given restrictions: specify"
" schema_id, schema_issuer_id, schema_name, schema_version,"
" issuer_id, cred_def_id, and/or attr::<attribute-name>::value where"
" schema_id, schema_issuer_did, schema_name, schema_version,"
" issuer_did, cred_def_id, and/or attr::<attribute-name>::value where"
" <attribute-name> represents a credential attribute name"
)
},
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -2117,7 +2117,7 @@ async def test_receive_pres_bait_and_switch_pred(self):
"name": "highScore",
"p_type": ">=",
"p_value": 1000000,
"restrictions": [{"issuer_id": "FFFFFFFFFFFFFFFFFFFFFF"}], # fake issuer
"restrictions": [{"issuer_did": "FFFFFFFFFFFFFFFFFFFFFF"}], # fake issuer
"non_revoked": {"from": NOW, "to": NOW},
}
pres_proposal = V20PresProposal(
Expand Down

0 comments on commit 5920e8f

Please sign in to comment.