Skip to content

Commit

Permalink
Merge pull request #50 from hypersign-protocol/v5.0.0
Browse files Browse the repository at this point in the history
V5.0.0
  • Loading branch information
Pratap2018 authored Aug 8, 2023
2 parents 364ee13 + fd10082 commit bc01995
Show file tree
Hide file tree
Showing 5 changed files with 8 additions and 7 deletions.
4 changes: 2 additions & 2 deletions src/popup/router/pages/Account.vue
Original file line number Diff line number Diff line change
Expand Up @@ -460,12 +460,12 @@ export default {
}
const intersectionSchemasIds = credentialSchemasIds.filter(x => schemaIds.indexOf(x) > -1)
const intersectionSchemasIdSet=new Set(intersectionSchemasIds)
if (intersectionSchemasIds.length <= 0) {
throw new Error('Credential not found for schemaIds ' + schemaId.join(','))
}
if (intersectionSchemasIds.length < schemaIds.length) {
if (intersectionSchemasIdSet.size < schemaIds.length) {
const rest = schemaIds.filter(x => intersectionSchemasIds.indexOf(x) < 0)
const msg= rest ? rest.join(',') : ''
throw new Error('Credential not found for schemaIds ' + msg)
Expand Down
1 change: 1 addition & 0 deletions src/popup/router/pages/DIDs.vue
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ export default {
const publicKeyMultibase = kp.publicKeyMultibase
const didDoc = await hsSdk.did.generate({ publicKeyMultibase });
didDoc.keyAgreement = [];
// if(didDoc.id.split(":").at(-1).length!==45){
// console.log("DID length is not 45. Trying again with index "+ (hdIndex+1));
// return this.generateNewDid(hdIndex+1);
Expand Down
1 change: 1 addition & 0 deletions src/popup/router/pages/Index.vue
Original file line number Diff line number Diff line change
Expand Up @@ -163,6 +163,7 @@ export default {
const publicKeyMultibase = kp.publicKeyMultibase
const didDoc = await hsSdk.did.generate({ publicKeyMultibase });
didDoc.keyAgreement = [];
// const didDoc = JSON.parse(didDocString);
const did = didDoc.id;
Expand Down
3 changes: 1 addition & 2 deletions src/popup/router/pages/SignDid.vue
Original file line number Diff line number Diff line change
Expand Up @@ -97,8 +97,8 @@ export default {
// Generating dummy key
const kp = await this.hsSDK.did.generateKeys();
let didDoc = await this.hsSDK.did.generate({ publicKeyMultibase: kp.publicKeyMultibase});
didDoc.keyAgreement = [];
// let didDoc = JSON.parse(didDocString);
const { controllers, alsoKnownAs, serviceEndpoint } = this.didRaw;
if(!Array.isArray(controllers)){
Expand Down Expand Up @@ -139,7 +139,6 @@ export default {
didDoc.verificationMethod.push(didDocument.verificationMethod[0])
didDoc.authentication.push(didDocument.authentication[0]);
didDoc.assertionMethod.push(didDocument.assertionMethod[0])
didDoc.keyAgreement.push(didDocument.keyAgreement[0]);
didDoc.capabilityInvocation.push(didDocument.capabilityInvocation[0]);
didDoc.capabilityDelegation.push(didDocument.capabilityDelegation[0]);
}
Expand Down
6 changes: 3 additions & 3 deletions src/popup/utils/hsConstants.js
Original file line number Diff line number Diff line change
@@ -1,15 +1,15 @@
// export const SUPERHERO_HS_AUTH_BASE_URL = process.env.VUE_APP_HS_AUTH_BASE_URL || "https://stage.hypermine.in/authserver/";
// export const SUPERHERO_HS_AUTH_BASE_URL = process.env.VUE_APP_HS_AUTH_BASE_URL || "http://localhost:8001/";
export const SUPERHERO_HS_AUTH_BASE_URL = process.env.VUE_APP_HS_AUTH_BASE_URL || "https://api.fyre.hypersign.id/auth/";
export const HS_VC_STATUS_CHECK_ATTEMPT=process.env.VUE_APP_HS_VC_STATUS_CHECK_ATTEMPT || 15;
export const HS_VC_STATUS_CHECK_INTERVAL=process.env.VUE_APP_ || 7000;
export const HS_VC_STATUS_CHECK_ATTEMPT = process.env.VUE_APP_HS_VC_STATUS_CHECK_ATTEMPT || 15;
export const HS_VC_STATUS_CHECK_INTERVAL = process.env.VUE_APP_ || 7000;
export const SUPERHERO_HS_AUTH_CREDENTIAL_ISSUE_API = "hs/api/v2/register"; // change supero to hypersign later
export const HS_AUTH_DID_URL = SUPERHERO_HS_AUTH_BASE_URL + "hs/api/v2/authdid"
export const HS_VC_STATUS_PATH = SUPERHERO_HS_AUTH_BASE_URL + "hs/api/v2/vcstatus"
export const WALLET_URL = process.env.VUE_APP_WALLET_URL || "https://wallet-jagrat.hypersign.id/";
// export const WALLET_URL=process.env.VUE_APP_WALLET_URL || "http://localhost:4999/chrome/popup/popup#/";
// export const BUSINESSCARD_SCHEMA='sch:hid:testnet:zFc19V37DPHmdysvPDJJdeHQTLPWzuSVZq4Tn9GPXcEj2:1.0'
export const BUSINESSCARD_SCHEMA='sch:hid:testnet:zDt4ZZwoA5vBV3t7tn8Y4KNKjH4fBDkwYxLfQK1nJC8BR:1.0'
export const BUSINESSCARD_SCHEMA = 'sch:hid:testnet:zDt4ZZwoA5vBV3t7tn8Y4KNKjH4fBDkwYxLfQK1nJC8BR:1.0'
export const AUTH_SERVER_FAUCET_PATH = "hs/api/v2/faucet/"
export const WALLET_TYPE = process.env.VUE_APP_HS_WALLET_TYPE || "web"
export const HYPERSIGN_AUTH_PROVIDER = {
Expand Down

0 comments on commit bc01995

Please sign in to comment.