replace remaining didJwt.createJwt calls with one that checks for did:peer

This commit is contained in:
2024-07-11 19:35:17 -06:00
parent 145a1da37e
commit 7cb9e2aa52
18 changed files with 212 additions and 319 deletions

View File

@@ -93,7 +93,7 @@ import {
SimpleSigner,
} from "@/libs/crypto";
import {
CONTACT_URL_PREFIX,
CONTACT_URL_PREFIX, createEndorserJwt,
ENDORSER_JWT_URL_LOCATION,
isDid,
register,
@@ -161,15 +161,7 @@ export default class ContactQRScanShow extends Vue {
},
};
const alg = undefined;
const privateKeyHex: string = identity.keys[0].privateKeyHex;
const signer = await SimpleSigner(privateKeyHex);
// create a JWT for the request
const vcJwt: string = await didJwt.createJWT(contactInfo, {
alg: alg,
issuer: identity.did,
signer: signer,
});
const vcJwt: string = await createEndorserJwt(identity.did, contactInfo);
const viewPrefix = CONTACT_URL_PREFIX + ENDORSER_JWT_URL_LOCATION;
this.qrValue = viewPrefix + vcJwt;
}