Bitcoin Forum
May 21, 2024, 05:47:06 PM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Feature request: private key importation  (Read 967 times)
cdnbcguy (OP)
Full Member
***
Offline Offline

Activity: 128
Merit: 100


View Profile WWW
April 25, 2013, 11:56:32 PM
 #1

First, apologies if this is the wrong place or this has been requested before - but we really need an easy way to import a private key from the ever growing in popularity paper wallets.

No messing about with RPC, please.... Just a nice menu choice.


Annona ad! Please keep in mind that there is nothing wrong with Bitcoin itself. All it's scandals are caused by wonky websites and sleazy people exploiting it. The light attracts bugs.

When all this bullshit drys up and blows away, Bitcoin will be stronger than ever.
scintill
Sr. Member
****
Offline Offline

Activity: 448
Merit: 254


View Profile WWW
April 26, 2013, 10:13:57 PM
 #2

You might know this and probably won't be completely happy with it, but: the latest clients have a "Debug window" where RPC commands can be entered.  So it is as easy as Help -> Debug window -> Console -> Enter "importprivkey 5kj2..."

Most of the core devs seem to be against making this easy, see: https://github.com/bitcoin/bitcoin/pull/2050 .

1SCiN5kqkAbxxwesKMsH9GvyWnWP5YK2W | donations
cdnbcguy (OP)
Full Member
***
Offline Offline

Activity: 128
Merit: 100


View Profile WWW
April 27, 2013, 03:20:36 AM
 #3

You might know this and probably won't be completely happy with it, but: the latest clients have a "Debug window" where RPC commands can be entered.  So it is as easy as Help -> Debug window -> Console -> Enter "importprivkey 5kj2..."

Most of the core devs seem to be against making this easy, see: https://github.com/bitcoin/bitcoin/pull/2050 .

Wow. Ok whatya gonna do... It's the hard way then....

Annona ad! Please keep in mind that there is nothing wrong with Bitcoin itself. All it's scandals are caused by wonky websites and sleazy people exploiting it. The light attracts bugs.

When all this bullshit drys up and blows away, Bitcoin will be stronger than ever.
wumpus
Hero Member
*****
qt
Offline Offline

Activity: 812
Merit: 1022

No Maps for These Territories


View Profile
April 27, 2013, 07:54:50 AM
Last edit: April 27, 2013, 08:19:03 AM by John Smith
 #4

Importing/exporting individual keys is dangerous, and will never be supported in a friendly way as there's just too many ways to shoot yourself in the foot with it. It breaks the wallet abstraction as it allows private keys to exist in multiple places at once.

What would be acceptable is a "sweep" feature, that either once or regularly sweeps the incoming coins from a specified private key to the user's wallet using a transaction.

Bitcoin Core developer [PGP] Warning: For most, coin loss is a larger risk than coin theft. A disk can die any time. Regularly back up your wallet through FileBackup Wallet to an external storage or the (encrypted!) cloud. Use a separate offline wallet for storing larger amounts.
jag2k2
Member
**
Offline Offline

Activity: 62
Merit: 10


View Profile
April 27, 2013, 02:50:10 PM
 #5

So if importing private keys is dangerous then what is the right way to spend money that is stored in a paper wallet?  I imagined you were supposed to import the private key of the paper wallet.

I believe that banking institutions are more dangerous to our liberties than standing armies... The issuing power should be taken from the banks and restored to the people, to whom it properly belongs. - Thomas Jefferson
grue
Legendary
*
Offline Offline

Activity: 2058
Merit: 1431



View Profile
April 27, 2013, 03:00:44 PM
 #6

So if importing private keys is dangerous then what is the right way to spend money that is stored in a paper wallet?  I imagined you were supposed to import the private key of the paper wallet.
you're supposed to spend the input immediately, so there will be no funds left over in the paper wallet. this can be done by using a separate wallet to send to your main wallet, or by using coin control to make sure the paper wallet's inputs are spent.

It is pitch black. You are likely to be eaten by a grue.

Adblock for annoying signature ads | Enhanced Merit UI
cdnbcguy (OP)
Full Member
***
Offline Offline

Activity: 128
Merit: 100


View Profile WWW
April 27, 2013, 04:15:18 PM
 #7

So if importing private keys is dangerous then what is the right way to spend money that is stored in a paper wallet?  I imagined you were supposed to import the private key of the paper wallet.
you're supposed to spend the input immediately, so there will be no funds left over in the paper wallet. this can be done by using a separate wallet to send to your main wallet, or by using coin control to make sure the paper wallet's inputs are spent.

I thought a paper wallet was for safe long term storage. That's what I've been doing with it.


Annona ad! Please keep in mind that there is nothing wrong with Bitcoin itself. All it's scandals are caused by wonky websites and sleazy people exploiting it. The light attracts bugs.

When all this bullshit drys up and blows away, Bitcoin will be stronger than ever.
Mike Hearn
Legendary
*
expert
Offline Offline

Activity: 1526
Merit: 1129


View Profile
April 27, 2013, 04:39:52 PM
 #8

Yeah paper wallets are a great idea ... if your wallet software explicitly supports them. Which today none do. If your wallet app doesn't have explicit support for paper wallets then you are very, very likely to lose money with them. It's already happened.
jag2k2
Member
**
Offline Offline

Activity: 62
Merit: 10


View Profile
April 27, 2013, 07:42:22 PM
 #9

Quote
Yeah paper wallets are a great idea ... if your wallet software explicitly supports them. Which today none do. If your wallet app doesn't have explicit support for paper wallets then you are very, very likely to lose money with them. It's already happened

Really why?  My understanding is that the paper wallet has a private key on it so as long as the private key is safe the coins cannot be lost.  Isn't that the whole point of having a paper wallet?

Yes it is for long term savings but in the event you want to spend it, it needs to get to an online wallet somehow.  Why is using the import private key function a bad idea?  And what is the better way?

I believe that banking institutions are more dangerous to our liberties than standing armies... The issuing power should be taken from the banks and restored to the people, to whom it properly belongs. - Thomas Jefferson
grue
Legendary
*
Offline Offline

Activity: 2058
Merit: 1431



View Profile
April 27, 2013, 08:07:18 PM
 #10

it's bad because people can trick you into importing a private key. your client will show that you have BTC. but if it's not sweeped to one of your addresses, both you and the other party has access to the coins.

It is pitch black. You are likely to be eaten by a grue.

Adblock for annoying signature ads | Enhanced Merit UI
optimator
Sr. Member
****
Offline Offline

Activity: 351
Merit: 250



View Profile WWW
April 27, 2013, 08:16:03 PM
 #11

Of course, the other piece that needs to be in a client that imports private keys is the ability to spend from a specific address. If you believe that the act of importing a private key has potentially compromised the security of that key then all funds, once imported, need to be moved to a clean address. This also would address the "change" issue that I believe is being referenced when someone says "paper wallet imports make people lose their coins"

Mike Hearn
Legendary
*
expert
Offline Offline

Activity: 1526
Merit: 1129


View Profile
April 27, 2013, 08:51:35 PM
 #12

Yes, exactly. People don't understand how the protocol works and how wallets work, then they lose their money. It's not hard to have a wallet app that understands paper wallets and guides users through the process, it's just that today none do it. It'd be a  good contribution.
wumpus
Hero Member
*****
qt
Offline Offline

Activity: 812
Merit: 1022

No Maps for These Territories


View Profile
April 28, 2013, 06:59:21 AM
 #13

I heard Armory supports paper/offline wallets natively. Haven't tried, but may be worth taking a look.

Bitcoin Core developer [PGP] Warning: For most, coin loss is a larger risk than coin theft. A disk can die any time. Regularly back up your wallet through FileBackup Wallet to an external storage or the (encrypted!) cloud. Use a separate offline wallet for storing larger amounts.
Mike Hearn
Legendary
*
expert
Offline Offline

Activity: 1526
Merit: 1129


View Profile
April 28, 2013, 10:36:19 AM
 #14

The right way to do it is with deterministic wallets. Then you can have a paper wallet that doesn't have all the complicated issues with change addresses and privacy. But it would still need some nodes to index the UTXO set to make import fast, otherwise you have to rescan the chain from the birthday onwards, which is very slow. Fine for restoring from backups when you're not expecting to ever have to do it, less fine for other things. Some people want to use paper wallets not only for backups but to very frequently import, spend and delete the wallet. This use case is much more complicated to support.

In other words, to work well paper wallets need both changes in the protocol and upgrades of the clients.
Pages: [1]
  Print  
 
Jump to:  

Powered by MySQL Powered by PHP Powered by SMF 1.1.19 | SMF © 2006-2009, Simple Machines Valid XHTML 1.0! Valid CSS!