mirror of
https://github.com/logos-messaging/lab.waku.org.git
synced 2026-01-05 23:33:11 +00:00
temp
This commit is contained in:
parent
ff894d6464
commit
94013391d5
56
examples/keystore-management/package-lock.json
generated
56
examples/keystore-management/package-lock.json
generated
@ -8,7 +8,7 @@
|
|||||||
"name": "waku-keystore-management",
|
"name": "waku-keystore-management",
|
||||||
"version": "0.1.0",
|
"version": "0.1.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@waku/rln": "0.1.5-6198efb.0",
|
"@waku/rln": "0.1.5-ad0e277.0",
|
||||||
"next": "15.1.7",
|
"next": "15.1.7",
|
||||||
"react": "^19.0.0",
|
"react": "^19.0.0",
|
||||||
"react-dom": "^19.0.0"
|
"react-dom": "^19.0.0"
|
||||||
@ -2309,16 +2309,16 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@waku/core": {
|
"node_modules/@waku/core": {
|
||||||
"version": "0.0.35-6198efb.0",
|
"version": "0.0.35-ad0e277.0",
|
||||||
"resolved": "https://registry.npmjs.org/@waku/core/-/core-0.0.35-6198efb.0.tgz",
|
"resolved": "https://registry.npmjs.org/@waku/core/-/core-0.0.35-ad0e277.0.tgz",
|
||||||
"integrity": "sha512-9ta28XPCs9mOT9DmaewxHuZyWVME5bqRsF8Hardrd4QaHVLEaE5nlqi1nF7PoxdwF+l+XmZ2x/gqwgDee6qPwg==",
|
"integrity": "sha512-IfgWE/Kc8jpcmO6PGsLzySHAWwoDQtIY9gsxWtoqPnll1cE9ylxfGVh0je4o58E5F0XGw+wm9TdD149hq30cJQ==",
|
||||||
"license": "MIT OR Apache-2.0",
|
"license": "MIT OR Apache-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@libp2p/ping": "2.0.1",
|
"@libp2p/ping": "2.0.1",
|
||||||
"@waku/enr": "0.0.29-6198efb.0",
|
"@waku/enr": "0.0.29-ad0e277.0",
|
||||||
"@waku/interfaces": "0.0.30-6198efb.0",
|
"@waku/interfaces": "0.0.30-ad0e277.0",
|
||||||
"@waku/proto": "0.0.10-6198efb.0",
|
"@waku/proto": "0.0.10-ad0e277.0",
|
||||||
"@waku/utils": "0.0.23-6198efb.0",
|
"@waku/utils": "0.0.23-ad0e277.0",
|
||||||
"debug": "^4.3.4",
|
"debug": "^4.3.4",
|
||||||
"it-all": "^3.0.4",
|
"it-all": "^3.0.4",
|
||||||
"it-length-prefixed": "^9.0.4",
|
"it-length-prefixed": "^9.0.4",
|
||||||
@ -2356,9 +2356,9 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@waku/enr": {
|
"node_modules/@waku/enr": {
|
||||||
"version": "0.0.29-6198efb.0",
|
"version": "0.0.29-ad0e277.0",
|
||||||
"resolved": "https://registry.npmjs.org/@waku/enr/-/enr-0.0.29-6198efb.0.tgz",
|
"resolved": "https://registry.npmjs.org/@waku/enr/-/enr-0.0.29-ad0e277.0.tgz",
|
||||||
"integrity": "sha512-vInEV3d2LV1fakhXIACYn4PBZwYLZNpKYqDMU1YJQ3yoQv6nHl0emeGz7GviyXh+2qyLFjEKzesqhLht41kP/A==",
|
"integrity": "sha512-3IoFVU3XX7rEge3VFMl5r3wc0XVnZTvheRuFYSm0HgPrMls23PmAd7IdFLOMq5e9CGWAbWx0fdT3StzIdN2PbQ==",
|
||||||
"license": "MIT OR Apache-2.0",
|
"license": "MIT OR Apache-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@ethersproject/rlp": "^5.7.0",
|
"@ethersproject/rlp": "^5.7.0",
|
||||||
@ -2366,7 +2366,7 @@
|
|||||||
"@libp2p/peer-id": "^5.0.1",
|
"@libp2p/peer-id": "^5.0.1",
|
||||||
"@multiformats/multiaddr": "^12.0.0",
|
"@multiformats/multiaddr": "^12.0.0",
|
||||||
"@noble/secp256k1": "^1.7.1",
|
"@noble/secp256k1": "^1.7.1",
|
||||||
"@waku/utils": "0.0.23-6198efb.0",
|
"@waku/utils": "0.0.23-ad0e277.0",
|
||||||
"debug": "^4.3.4",
|
"debug": "^4.3.4",
|
||||||
"js-sha3": "^0.9.2"
|
"js-sha3": "^0.9.2"
|
||||||
},
|
},
|
||||||
@ -2383,21 +2383,21 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@waku/interfaces": {
|
"node_modules/@waku/interfaces": {
|
||||||
"version": "0.0.30-6198efb.0",
|
"version": "0.0.30-ad0e277.0",
|
||||||
"resolved": "https://registry.npmjs.org/@waku/interfaces/-/interfaces-0.0.30-6198efb.0.tgz",
|
"resolved": "https://registry.npmjs.org/@waku/interfaces/-/interfaces-0.0.30-ad0e277.0.tgz",
|
||||||
"integrity": "sha512-K+DIqbSFct0/1RYg2QdpviXOps9mDo04quW7jvlUvKP9qVBDvDUBlZrvfw+kIHr77g0DzyYLganuLv/Ocd13rw==",
|
"integrity": "sha512-Xg0vupz9y+PGNKVsJ3AodpcxWLkGafLPser4H/0SYvwiBKR0doEs08wfRdXY83WID1GZPVkA3jcIm0rAnPZWSw==",
|
||||||
"license": "MIT OR Apache-2.0",
|
"license": "MIT OR Apache-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@waku/proto": "0.0.10-6198efb.0"
|
"@waku/proto": "0.0.10-ad0e277.0"
|
||||||
},
|
},
|
||||||
"engines": {
|
"engines": {
|
||||||
"node": ">=20"
|
"node": ">=20"
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@waku/proto": {
|
"node_modules/@waku/proto": {
|
||||||
"version": "0.0.10-6198efb.0",
|
"version": "0.0.10-ad0e277.0",
|
||||||
"resolved": "https://registry.npmjs.org/@waku/proto/-/proto-0.0.10-6198efb.0.tgz",
|
"resolved": "https://registry.npmjs.org/@waku/proto/-/proto-0.0.10-ad0e277.0.tgz",
|
||||||
"integrity": "sha512-PQktYd1wgQ9Ihdyf+u950ugJL3LUfLh0kEvEHlSLhD9fOsipaegPBR7EsK78cecpZP1hBxuOZwjr5coO3byWlg==",
|
"integrity": "sha512-F4RKTcdX3v+E3/TxdINPWpsQEjst1VXlslJdNXC1LXPRqd87S7r2e47PXafM7TGBdOitIIPw8Xf4MxbPFGa1Gg==",
|
||||||
"license": "MIT OR Apache-2.0",
|
"license": "MIT OR Apache-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"protons-runtime": "^5.4.0"
|
"protons-runtime": "^5.4.0"
|
||||||
@ -2407,15 +2407,15 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@waku/rln": {
|
"node_modules/@waku/rln": {
|
||||||
"version": "0.1.5-6198efb.0",
|
"version": "0.1.5-ad0e277.0",
|
||||||
"resolved": "https://registry.npmjs.org/@waku/rln/-/rln-0.1.5-6198efb.0.tgz",
|
"resolved": "https://registry.npmjs.org/@waku/rln/-/rln-0.1.5-ad0e277.0.tgz",
|
||||||
"integrity": "sha512-v/x79fKH6M1E4qjpRWdGErSGt6p7LBLc9tt7G/ZFWJY8afBHbtOH3JrJ0ZqDc4oZsQbRRMGVLJ6WbJIDkQtoYA==",
|
"integrity": "sha512-2QxvEhZoZjsP0J8wg6BAv7GTvDMeOzD7a46WR6M3Gld39TNf+2hQMzED5I91QxjcoAvMMbphD8FiH4X5tqzM5g==",
|
||||||
"license": "MIT OR Apache-2.0",
|
"license": "MIT OR Apache-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@chainsafe/bls-keystore": "3.0.0",
|
"@chainsafe/bls-keystore": "3.0.0",
|
||||||
"@noble/hashes": "^1.2.0",
|
"@noble/hashes": "^1.2.0",
|
||||||
"@waku/core": "0.0.35-6198efb.0",
|
"@waku/core": "0.0.35-ad0e277.0",
|
||||||
"@waku/utils": "0.0.23-6198efb.0",
|
"@waku/utils": "0.0.23-ad0e277.0",
|
||||||
"@waku/zerokit-rln-wasm": "^0.0.13",
|
"@waku/zerokit-rln-wasm": "^0.0.13",
|
||||||
"chai": "^5.1.2",
|
"chai": "^5.1.2",
|
||||||
"chai-as-promised": "^8.0.1",
|
"chai-as-promised": "^8.0.1",
|
||||||
@ -2432,13 +2432,13 @@
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
"node_modules/@waku/utils": {
|
"node_modules/@waku/utils": {
|
||||||
"version": "0.0.23-6198efb.0",
|
"version": "0.0.23-ad0e277.0",
|
||||||
"resolved": "https://registry.npmjs.org/@waku/utils/-/utils-0.0.23-6198efb.0.tgz",
|
"resolved": "https://registry.npmjs.org/@waku/utils/-/utils-0.0.23-ad0e277.0.tgz",
|
||||||
"integrity": "sha512-K7RNG8ngHYpyVwIHeXaIAi52FO1fJM/h4gurxII331segXrnSXSYtnv3jwO3HDnoTMX+o21ddM0VfyzxilM3NQ==",
|
"integrity": "sha512-r3nef/L4fZx2GA7byUAOFLSjhVXuH22FFgmEp7+/jzbAjKAcVIaCfG2M09SnNDbxc5uViKeEE6ODIfw+k+2rZw==",
|
||||||
"license": "MIT OR Apache-2.0",
|
"license": "MIT OR Apache-2.0",
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@noble/hashes": "^1.3.2",
|
"@noble/hashes": "^1.3.2",
|
||||||
"@waku/interfaces": "0.0.30-6198efb.0",
|
"@waku/interfaces": "0.0.30-ad0e277.0",
|
||||||
"chai": "^4.3.10",
|
"chai": "^4.3.10",
|
||||||
"debug": "^4.3.4",
|
"debug": "^4.3.4",
|
||||||
"uint8arrays": "^5.0.1"
|
"uint8arrays": "^5.0.1"
|
||||||
|
|||||||
@ -10,7 +10,7 @@
|
|||||||
"lint": "next lint"
|
"lint": "next lint"
|
||||||
},
|
},
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
"@waku/rln": "0.1.5-6198efb.0",
|
"@waku/rln": "0.1.5-ad0e277.0",
|
||||||
"next": "15.1.7",
|
"next": "15.1.7",
|
||||||
"react": "^19.0.0",
|
"react": "^19.0.0",
|
||||||
"react-dom": "^19.0.0"
|
"react-dom": "^19.0.0"
|
||||||
|
|||||||
@ -98,7 +98,7 @@ export function KeystoreProvider({ children }: { children: ReactNode }) {
|
|||||||
|
|
||||||
// Add the credential to the new keystore
|
// Add the credential to the new keystore
|
||||||
await singleCredentialKeystore.addCredential(credential, password);
|
await singleCredentialKeystore.addCredential(credential, password);
|
||||||
|
console.log("Single credential keystore:", singleCredentialKeystore.toString());
|
||||||
return singleCredentialKeystore.toString();
|
return singleCredentialKeystore.toString();
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@ -309,12 +309,14 @@ export function RLNProvider({ children }: { children: ReactNode }) {
|
|||||||
const credentials = await rln.registerMembership({
|
const credentials = await rln.registerMembership({
|
||||||
signature: signature
|
signature: signature
|
||||||
});
|
});
|
||||||
|
console.log("Credentials:", credentials);
|
||||||
|
|
||||||
// If we have save options, save to keystore
|
// If we have save options, save to keystore
|
||||||
let keystoreHash: string | undefined;
|
let keystoreHash: string | undefined;
|
||||||
if (saveOptions && saveOptions.password && credentials) {
|
if (saveOptions && saveOptions.password && credentials) {
|
||||||
try {
|
try {
|
||||||
keystoreHash = await saveCredentialsToKeystore(credentials as KeystoreEntity, saveOptions.password);
|
const credentialsEntity = credentials as KeystoreEntity;
|
||||||
|
keystoreHash = await saveCredentialsToKeystore(credentialsEntity, saveOptions.password);
|
||||||
console.log("Credentials saved to keystore with hash:", keystoreHash);
|
console.log("Credentials saved to keystore with hash:", keystoreHash);
|
||||||
} catch (saveErr) {
|
} catch (saveErr) {
|
||||||
console.error("Error saving credentials to keystore:", saveErr);
|
console.error("Error saving credentials to keystore:", saveErr);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user