Comments (1)
Found a solution to the issue:
CustomAuth basically returns a private key for user on frontend, so we can derive terra private key by using CustomAuth private key as entropy.
Example to do this is:
const { MnemonicKey } = require('@terra-money/terra.js');
const bip39 = require('bip39');
const torus_key = "cb8b467539d992dd1510bbe0e69a3b654ada325fbe4d830d0fbeab7788bc296f";
const mnemonic_phrase = bip39.entropyToMnemonic(torus_key);
const mk = new MnemonicKey({
mnemonic: mnemonic_phrase, // optional, will be random if not provided
coinType: 330, // optional, default
account: 0, // optional, default
index: 0, // optional, default
});
console.log("account 0, index 0 key", mk.privateKey.toString('hex'))
In above code snippet just replace the torus_key
with the one returned from CustomAuth.
from customauth.
Related Issues (20)
- Integration in NextJS HOT 3
- Issue requesting key from mainnet verifier HOT 2
- link to documentation is not valid url HOT 2
- Update to use solana HOT 1
- Normalize email before comparing HOT 1
- Could't connect to Ropsten node HOT 2
- Error: paramsemail not equal body.email HOT 1
- Sorry, the Torus Network that powers Web3Auth is currently very busy. HOT 3
- ENGINE_MAP import issue HOT 1
- To reduce logo size for email password HOT 1
- Torus w/ Express HOT 1
- Unable to use own credentials for passwordless login with Auth0 in example HOT 1
- Error while installing the package HOT 1
- Internal error "code":-32602 HOT 1
- firefox doesnt fails to initialize redirect mode HOT 1
- Receiving a "window not found" error on v4.11.1 HOT 3
- High Severity Vulnerabilities
- Documentation - LRC Environment HOT 1
- Regression - Window is not defined HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from customauth.