We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 1f3e5f1 commit 5ab28edCopy full SHA for 5ab28ed
spp_openid_vci/models/vci_issuer.py
@@ -11,3 +11,19 @@ def onchange_auth_allowed_issuers(self):
11
args = [rec, f"set_default_auth_allowed_issuers_{rec.issuer_type}"]
12
if hasattr(*args):
13
getattr(*args)()
14
+
15
+ def sign_and_issue_credential(self, credential: dict) -> dict:
16
+ self.ensure_one()
17
18
+ ld_proof = self.build_empty_ld_proof()
19
20
+ signature = self.get_encryption_provider().jwt_sign(
21
+ {"credential": credential, "proof": ld_proof},
22
+ include_payload=False,
23
+ include_certificate=True,
24
+ include_cert_hash=True,
25
+ )
26
+ ld_proof["jws"] = signature
27
+ ret = dict(credential)
28
+ ret["proof"] = ld_proof
29
+ return ret
0 commit comments