Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Password isn't verified when fully unlocking a anonymizeonly-locked wallet #148

Closed
jagerman opened this issue Dec 19, 2018 · 0 comments
Closed
Assignees
Labels

Comments

@jagerman
Copy link

When a wallet is currently unlocked with a true anonymizeonly setting, the wallet can be fully unlocked without using/knowing the wallet passphrase.

Here is the process I went through showing first that the anonymizeonly lock is working as expected, then showing that I can trivially get a full unlock without knowing the password:

betwixt:~/bulwark$ ./bulwark-cli walletlock
betwixt:~/bulwark$ ./bulwark-cli getstakingstatus
{
  "validtime": true,
  "haveconnections": true,
  "walletunlocked": false,
  "mintablecoins": true,
  "enoughcoins": true,
  "mnsync": true,
  "staking status": false
}
betwixt:~/bulwark$ ./bulwark-cli walletpassphrase "MYACTUALPASS" 0 true
betwixt:~/bulwark$ ./bulwark-cli getstakingstatus
{
  "validtime": true,
  "haveconnections": true,
  "walletunlocked": true,
  "mintablecoins": true,
  "enoughcoins": true,
  "mnsync": true,
  "staking status": true
}

Looking good. Now let's say I try to send from this wallet (back to myself for the sake of example):

betwixt:~/bulwark$ ./bulwark-cli getaccountaddress ""
bSomeNewAddr
betwixt:~/bulwark$ ./bulwark-cli sendfrom "" bSomeNewAddr 1
error: {"code":-13,"message":"Error: Please enter the wallet passphrase with walletpassphrase first."}

Good. But now:

betwixt:~/bulwark$ ./bulwark-cli walletpassphrase THISISNOTMYPASSWORD 60
betwixt:~/bulwark$ ./bulwark-cli sendfrom "" bSomeNewAddr 1
(shows the tx id here)

If I don't have the existing anonymizeonly unlock active (i.e. after the 60 second expiry set above) the bad password isn't accepted:

betwixt:~/bulwark$ ./bulwark-cli walletpassphrase THISISNOTMYPASSWORD 60
error: {"code":-14,"message":"Error: The wallet passphrase entered was incorrect."}

This seems to make the anonymizeonly option completely ineffective from a security point of view at the moment and needs a fix ASAP.

@dustinengle dustinengle self-assigned this Dec 19, 2018
@ghost ghost added the QT label Dec 24, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants