Bitcoin Forum

Bitcoin => Bitcoin Technical Support => Topic started by: p100 on April 09, 2017, 08:40:23 AM



Title: Spaces in the password unlocking the wallet (bitcoin-cli).
Post by: p100 on April 09, 2017, 08:40:23 AM
1. Using bitcoin-qt one can enter password with spaces in the window to decrypt the wallet. How to do it with bitcoin-cli? Imagine a password is 120 130 140 (two spaces between the numbers), if I type walletpassphrase 120 130 140 150 will bitcoin-cli interpret 120 130 140 as password (with two spaces) and 150 as timeout?

2. What if spaces are at the beginning and the end of password? How to send such phrase using bitcoin-cli (in GUI when typing spaces arrows appear, so I think GUI normally "sees" those spaces). Thanks!


Title: Re: Spaces in the password unlocking the wallet (bitcoin-cli).
Post by: achow101 on April 09, 2017, 12:41:44 PM
1. Using bitcoin-qt one can enter password with spaces in the window to decrypt the wallet. How to do it with bitcoin-cli? Imagine a password is 120 130 140 (two spaces between the numbers), if I type walletpassphrase 120 130 140 150 will bitcoin-cli interpret 120 130 140 as password (with two spaces) and 150 as timeout?
No, that will not work. You have to surround your passphrase with quotes, so like
Code:
walletpassphrase "120 130 140" 150

2. What if spaces are at the beginning and the end of password? How to send such phrase using bitcoin-cli (in GUI when typing spaces arrows appear, so I think GUI normally "sees" those spaces). Thanks!
Again, use double quotes around your entire passphrase.


Title: Re: Spaces in the password unlocking the wallet (bitcoin-cli).
Post by: amaclin on April 11, 2017, 11:35:04 AM
No, that will not work. You have to surround your passphrase with quotes, so like
Code:
walletpassphrase "120 130 140" 150
What if the quote is a part of password?  :P (this ia s joke, not a question, not a problem)


Title: Re: Spaces in the password unlocking the wallet (bitcoin-cli).
Post by: shorena on April 15, 2017, 10:32:47 AM
No, that will not work. You have to surround your passphrase with quotes, so like
Code:
walletpassphrase "120 130 140" 150
What if the quote is a part of password?  :P (this ia s joke, not a question, not a problem)


Escape it  ::)