forked from polkadot-js/extension
-
Notifications
You must be signed in to change notification settings - Fork 81
SubWallet Interactive with Cold Wallet #150
Copy link
Copy link
Closed
Milestone
Description
Basic knowledge
Overview
Signer with manage account and keep private key and allow to create signature for any transaction. Most of signer require passphase to unlock private key before create signature. DApp, Extension Wallet, Hardware Wallet, Mobile Signer can become signer if it keep private key of an account.
There are some signing data usecase depend on which object contain private key:
- DApp keep private key
a. This is most simplest case. DApp will create transaction and sign transaction with private key that it own. - Extension Wallet keep private key, this case is very popular key
a. Some Wallet Extension like SubWallet have some features like a DApp. When user perform some features that required signature, this case will be the same with 1a.
b. DApp will create transaction and keyring on DApp will request signature from Extension via extension signature.
c. DApp on mobile can be import account from QR code. Anytime required signature DApp need to push data to Extension Wallet and get signature result by QR. - Hardware Wallet keep private key, this is nearly the most security
a. DApp direct connect to hardware wallet via usb connection and it need to import account from hardware wallet. Whenver imported account request signature, it required Hardware Wallet connect and sign data with its passphase.
b. DApp use injected account from Extension and Extension import account from hardware. With DApp this case is same with 2a but with Extension it need to import account from Hardware and connect to this device to get transaction signature. - Mobile Signer keep private key. This case near the same with Hardware Wallet but Mobile Signature will use QR code to interact with extension or DApp
a. DApp direct connect to hardware wallet via usb connection and it need to import account from QR code. Whenver imported account request signature DApp with send and get payload via QR code.
b. DApp use injected account from Extension and Extension import account from hardware. With DApp this case is same with 2a but with Extension it need to import account from and request signature by send and get data via QR code.
Use QR with signer
- Import account via QR:
- Data:
AccountType:Address:PublicKey:AccountName - Example:
substrate:5HL6xpAbHnxCwW2uUqQ5dmev2wo2FQkpUEfmXrzmzTFkWMRo:0xe143f23803ac50e8f6f8e62695d1ce9e4e1d68aa36c1cd2cfd15340213f3423e:Westend root
- Data:
- Import ETH Account:
- Data:
ethereum:(details = address | address "@" chainid | address "@" chainid ":" name) - EG:
ethereum:0x4f604e0FECf7F78B64a564C343b870bB4608700c@1284:EVM-Account-001
- Data:
- Signature request:
createSignPayload(address, cmd, payload, genesisHash)in package@polkadot/react-qr - Signature: Sign result eg:
01d6b5a7d39598c76c5754448e0e55a258088cb03a573dd04db06e16be3eafb854285407903b8ce551255011e0ae52226f52ab7a31d38f1f3fd1f0a09349e2b989 - Research Mindmap

- Standard: folllow this article
Requirements
SubWallet now work ok with case 2a, 2b It hold private key and can sign for these transaction.
- We need to test does our wallet work well with case 3a.
- We also compitable with case 2c, 4b
Todo List
These step will help us response for all requiredment
Research
- How to hardware wallet work?
- How to mobile signer work?
Test again
- Sign Transactions with hardware wallet
- Create Account via Ledger
- Send / Receive Assets
Implement
Can use 2 lib @polkadot/react-singer & @polkadot/react-qr with these component QrDisplayPayload and QrScanSignature
- QR display / QR Scan #316
- (2c) Sign with the extension via QR: Add method sign via QR with extension #317
- (4b) Sign with mobile signer via QR: Support Parity Signer/ Style to sign transaction or send funds transaction of account imported via QR #315
Staking
- Stake
- UnStake
- Withdraw
Reactions are currently unavailable
Metadata
Metadata
Labels
No labels
