solidity-jwt
solidity-jwt copied to clipboard
Experiments with Solidity JWT. Do not use in production.
Solidity JWT validator
This project includes a set of contracts and a Vue-based demo that allow you to deploy an identity contract and then recover it using Google Sign-In. This is a proof-of-concept and is definitely not ready for production :warning:
Project setup
- Install dependencies via
npm install - Create a project in the Google Developers console
- In the Credentials section of your project, create an OAuth 2.0 for a Web Application
- Copy the client ID to your
.envlocal file - Start a local ganache instance and copy the network ID to your local
.envfile - Update the keys in
scripts/deployKeys.jsusing the latest JWKS shared by Google - Deploy the JWKS contract running
npx truffle exec scripts/deployKeys.js --network localand copy the deployment address to your local.envfile - Run locally with
npm run serve, or set up a production build withnpm run build
3rd party smart contracts
- https://github.com/adriamb/SolRsaVerify/
- https://github.com/chrisdotn/jsmnSol
- https://github.com/Arachnid/solidity-stringutils/