hs-airdrop
hs-airdrop copied to clipboard
Asks for Passphrase for passphrase free key
$ hs-airdrop ~/.ssh/id_rsa hs1q5z7yyk8xrh4quqg3kw498ngy7hnd4sruqyxnxd
Passphrase:
My private key doesn't have passphrase, but the tool still asks for it.
-----BEGIN OPENSSH PRIVATE KEY-----
...
-----END OPENSSH PRIVATE KEY-----
What happens if you just leave it blank and hit enter?
What happens if you just leave it blank and hit enter?
$ ./hs-airdrop ~/.ssh/id_rsa hs1q5z7yyk8xrh4quqg3kw498ngy7hnd4sruqyxnxd
Passphrase: <Enter>
Error: Encoding failed.
at Object.decode (~/GitHub/handshake-org/hs-airdrop/node_modules/bcrypto/lib/native/bech32.js:52:18)
at parseAddress (~/GitHub/handshake-org/hs-airdrop/bin/hs-airdrop:800:39)
at parseArgs (~/GitHub/handshake-org/hs-airdrop/bin/hs-airdrop:749:37)
at processTicksAndRejections (internal/process/task_queues.js:93:5)
at async main (~/GitHub/handshake-org/hs-airdrop/bin/hs-airdrop:755:19)
Same error when I've tried to drop the passphrase from the source code:
- const passphrase = await readPassphrase();
- const key = SSHPrivateKey.fromString(str, passphrase);
+ //const passphrase = await readPassphrase();
+ const key = SSHPrivateKey.fromString(str);
Same when testing with new brand key (without passphrase, original master branch code):
$ ssh-keygen -f newkey
Generating public/private rsa key pair.
Enter passphrase (empty for no passphrase): (none)
Enter same passphrase again: (none)
Your identification has been saved in newkey.
Your public key has been saved in newkey.pub.
The key fingerprint is:
...
$ ./hs-airdrop newkey hs1q5z7yyk8xrh4quqg3kw498ngy7hnd4sruqyxnxd
Passphrase:
Error: Encoding failed.
And the same error when generated key with the passphrase (original master branch code):
$ ssh-keygen -t ed25519 -N password -f newkey2
Generating public/private ed25519 key pair.
Your identification has been saved in newkey2.
Your public key has been saved in newkey2.pub.
The key fingerprint is:
...
$ ./hs-airdrop newkey2 hs1q5z7yyk8xrh4quqg3kw498ngy7hnd4sruqyxnxd
Passphrase: password
Error: Encoding failed.
Ok so this does not look like a password issue, in fact the stack trace indicates an encoding error. I tried to reproduce your steps exactly and it failed the same way -- but it succeeded when I put in my own mainnet HNS address:
$ bin/hs-airdrop newkey hs1qde7jaw6qgzzfu83upn3twvsyhh0zrshg76qe0x
Passphrase:
Attempting to create proof.
This may take a bit.
Decrypting nonce...
NonceError: Could not find nonce in bucket 27.
at findNonces (/Users/matthewzipkin/Desktop/work/hs-airdrop/bin/hs-airdrop:275:17)
at async createKeyProofs (/Users/matthewzipkin/Desktop/work/hs-airdrop/bin/hs-airdrop:328:17)
at async main (/Users/matthewzipkin/Desktop/work/hs-airdrop/bin/hs-airdrop:761:8)
This means your key was not found in the airdrop tree.
If you registered at handshake.org, use that address.
Usage: $ hs-airdrop [addr]
So then I checked the HNS address you are using. Compare the results with my address:
$ hsd-rpc validateaddress hs1q5z7yyk8xrh4quqg3kw498ngy7hnd4sruqyxnxd
{
"isvalid": false
}
$ hsd-rpc validateaddress hs1qde7jaw6qgzzfu83upn3twvsyhh0zrshg76qe0x
{
"isvalid": true,
"address": "hs1qde7jaw6qgzzfu83upn3twvsyhh0zrshg76qe0x",
"isscript": false,
"isspendable": true,
"witness_version": 0,
"witness_program": "6e7d2ebb4040849e1e3c0ce2b73204bdde21c2e8"
}
Please double check your wallet address! :-)
i have same issues that need Passphrase and shown this when is enter
Error: PEM parse error (unexpected data).
at decode (/home/babycodes/Downloads/hs-airdrop-0.9.0/hs-airdrop/node_modules/bcrypto/lib/encoding/pem.js:349:13)
at decode.next (
Error: PEM parse error (unexpected data).
This is not a passphrase issue - is your key in PEM format?
so how the right format is?
From https://github.com/handshake-org/hs-airdrop#usage:
[key-file] can be:
- An SSH private key file.
- An exported PGP armor keyring (.asc).
- An exported PGP raw keyring (.pgp/.gpg).
ok i got it
which key?
Attempting to create proof.
This may take a bit.
Decrypting nonce...
NonceError: Could not find nonce in bucket 255.
at findNonces (/home/babycodes/Downloads/hs-airdrop-0.9.0/hs-airdrop/bin/hs-airdrop:275:17)
at async createKeyProofs (/home/babycodes/Downloads/hs-airdrop-0.9.0/hs-airdrop/bin/hs-airdrop:328:17)
at async main (/home/babycodes/Downloads/hs-airdrop-0.9.0/hs-airdrop/bin/hs-airdrop:761:8)
This means your key was not found in the airdrop tree.
If you registered at handshake.org, use that address.
Usage: $ hs-airdrop [addr]
i put address from this generated syntax
./bin/hsw-cli account get default | grep receiveAddress
Error: Address is not a faucet or sponsor address.
at readEntries (/home/babycodes/Downloads/hs-airdrop-0.9.0/hs-airdrop/bin/hs-airdrop:574:11)
at async parseArgs (/home/babycodes/Downloads/hs-airdrop-0.9.0/hs-airdrop/bin/hs-airdrop:738:25)
at async main (/home/babycodes/Downloads/hs-airdrop-0.9.0/hs-airdrop/bin/hs-airdrop:755:19)
This means your key was not found in the airdrop tree.
Are you sure you are using the key that was connected to your github profile in February 2019?
If you registered at handshake.org, use that address.
Did you register at Handshake.org?