Bitcoin Forum
November 02, 2024, 08:40:15 AM *
News: Latest Bitcoin Core release: 28.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: « 1 2 3 4 5 6 7 8 9 10 [11] 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 »
  Print  
Author Topic: [ANN] bitaddress.org Safe JavaScript Bitcoin address/private key  (Read 153342 times)
dooglus
Legendary
*
Offline Offline

Activity: 2940
Merit: 1333



View Profile
May 30, 2012, 05:06:50 AM
 #201

The 'wallet details' tab says:

Quote
Public Key (compressed, 65 characters [0-9A-F]):
021057EDD23AE4D3E51C150AF43C9477530FA268EC80FC03046F0AD7957597E9E6

but that's 66 characters, not 65.

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
payb.tc
Hero Member
*****
Offline Offline

Activity: 812
Merit: 1000



View Profile
May 30, 2012, 05:07:35 AM
 #202

The 'wallet details' tab says:

Quote
Public Key (compressed, 65 characters [0-9A-F]):
021057EDD23AE4D3E51C150AF43C9477530FA268EC80FC03046F0AD7957597E9E6

but that's 66 characters, not 65.

maybe they ignore the leading zero on the left.
dooglus
Legendary
*
Offline Offline

Activity: 2940
Merit: 1333



View Profile
May 30, 2012, 05:12:34 AM
 #203

The 'wallet details' tab says:

Quote
Public Key (compressed, 65 characters [0-9A-F]):
021057EDD23AE4D3E51C150AF43C9477530FA268EC80FC03046F0AD7957597E9E6

but that's 66 characters, not 65.

maybe they ignore the leading zero on the left.


I think it's just a typo in the bitaddress code.  Compare with the uncompressed version which also has a leading zero, but has the correct length:

Quote
Public Key (130 characters [0-9A-F]):
048FDCB5A9E446EC3363CD04ABB7FEA271265A2942D5347F0D9488C0926AF87FD
ECF2345C49CA5A6C5677936C4BFAA3062DC1BFF7A5F93A94FEAF271DEECCC3CAF
Public Key (compressed, 65 characters [0-9A-F]):
038FDCB5A9E446EC3363CD04ABB7FEA271265A2942D5347F0D9488C0926AF87FDE

The uncompressed key is 1+32+32 bytes, the compressed key is 1+32 bytes.  Both need doubling to get the length in hex digits.

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
pointbiz (OP)
Sr. Member
****
Offline Offline

Activity: 437
Merit: 415

1ninja


View Profile
July 15, 2012, 05:27:48 PM
 #204

The 'wallet details' tab says:

Quote
Public Key (compressed, 65 characters [0-9A-F]):
021057EDD23AE4D3E51C150AF43C9477530FA268EC80FC03046F0AD7957597E9E6

but that's 66 characters, not 65.

maybe they ignore the leading zero on the left.


I think it's just a typo in the bitaddress code.  Compare with the uncompressed version which also has a leading zero, but has the correct length:

Quote
Public Key (130 characters [0-9A-F]):
048FDCB5A9E446EC3363CD04ABB7FEA271265A2942D5347F0D9488C0926AF87FD
ECF2345C49CA5A6C5677936C4BFAA3062DC1BFF7A5F93A94FEAF271DEECCC3CAF
Public Key (compressed, 65 characters [0-9A-F]):
038FDCB5A9E446EC3363CD04ABB7FEA271265A2942D5347F0D9488C0926AF87FDE

The uncompressed key is 1+32+32 bytes, the compressed key is 1+32 bytes.  Both need doubling to get the length in hex digits.

Yes it's a typo, should be 66 characters. I will fix in the next release.

Coder of: https://www.bitaddress.org      Thread
Open Source JavaScript Client-Side Bitcoin Wallet Generator
Donations: 1NiNja1bUmhSoTXozBRBEtR8LeF9TGbZBN   PGP
teflone
Hero Member
*****
Offline Offline

Activity: 770
Merit: 500


You're fat, because you dont have any pics on FB


View Profile
July 16, 2012, 02:19:17 AM
 #205

Ok, I thought this would be easier than it is..


Can someone describe how to actually use the keys provided once generated from Bitaddress.org ?

I've tried a bit using Armory..     its a no go, it uses a different terminology for the "codes"



Why isnt this simple, and documented somewhere ?   Roll Eyes

For Canadians by Canadians: Canada's Bitcoin Community - https://www.coinforum.ca/
dooglus
Legendary
*
Offline Offline

Activity: 2940
Merit: 1333



View Profile
July 16, 2012, 03:01:40 AM
 #206

Ok, I thought this would be easier than it is..


Can someone describe how to actually use the keys provided once generated from Bitaddress.org ?

I've tried a bit using Armory..     its a no go, it uses a different terminology for the "codes"



Why isnt this simple, and documented somewhere ?   Roll Eyes

To import a private key into your satoshi client:

0. edit or create bitcoin.conf in the same folder as wallet.dat adding lines that say:

Quote
rpcuser=someusername
rpcpassword=somepassword

1. run:  bitcoin-qt -server and wait for it to load the blockchain and start up

2. run:  bitcoind importprivkey 5Je4KHK15KobUcbj29xATN6z6QgZVxL4rYnBD2kaTzncS6oKmqL   (replace 5J... with the private key given to you by bitaddress)

3. wait 5 minutes or so while bitcoin-qt checks the whole blockchain for transactions containing your new address

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
payb.tc
Hero Member
*****
Offline Offline

Activity: 812
Merit: 1000



View Profile
July 16, 2012, 03:40:15 AM
 #207

2. run:  bitcoind importprivkey 5Je4KHK15KobUcbj29xATN6z6QgZVxL4rYnBD2kaTzncS6oKmqL   (replace 5J... with the private key given to you by bitaddress)

do you need to type your username and password with every command? if so, what syntax is it?

i've only ever done this through JSON, not actually on the command line.
teflone
Hero Member
*****
Offline Offline

Activity: 770
Merit: 500


You're fat, because you dont have any pics on FB


View Profile
July 16, 2012, 04:19:12 AM
 #208

Ok, I thought this would be easier than it is..


Can someone describe how to actually use the keys provided once generated from Bitaddress.org ?

I've tried a bit using Armory..     its a no go, it uses a different terminology for the "codes"



Why isnt this simple, and documented somewhere ?   Roll Eyes

To import a private key into your satoshi client:

0. edit or create bitcoin.conf in the same folder as wallet.dat adding lines that say:

Quote
rpcuser=someusername
rpcpassword=somepassword

1. run:  bitcoin-qt -server and wait for it to load the blockchain and start up

2. run:  bitcoind importprivkey 5Je4KHK15KobUcbj29xATN6z6QgZVxL4rYnBD2kaTzncS6oKmqL   (replace 5J... with the private key given to you by bitaddress)

3. wait 5 minutes or so while bitcoin-qt checks the whole blockchain for transactions containing your new address


Lmfao!

Are you serious ?  Undecided

No easier way? no way with armory ?

For Canadians by Canadians: Canada's Bitcoin Community - https://www.coinforum.ca/
casascius
Mike Caldwell
VIP
Legendary
*
Offline Offline

Activity: 1386
Merit: 1140


The Casascius 1oz 10BTC Silver Round (w/ Gold B)


View Profile WWW
July 16, 2012, 04:51:15 AM
 #209

Blockchain.info is pretty painless for redeeming private keys. You can import a key and send the funds onward within seconds of creating a new account and without having to wait for any confirmations.

Companies claiming they got hacked and lost your coins sounds like fraud so perfect it could be called fashionable.  I never believe them.  If I ever experience the misfortune of a real intrusion, I declare I have been honest about the way I have managed the keys in Casascius Coins.  I maintain no ability to recover or reproduce the keys, not even under limitless duress or total intrusion.  Remember that trusting strangers with your coins without any recourse is, as a matter of principle, not a best practice.  Don't keep coins online. Use paper or hardware wallets instead.
teflone
Hero Member
*****
Offline Offline

Activity: 770
Merit: 500


You're fat, because you dont have any pics on FB


View Profile
July 16, 2012, 05:24:10 AM
 #210

Blockchain.info is pretty painless for redeeming private keys. You can import a key and send the funds onward within seconds of creating a new account and without having to wait for any confirmations.


Ahhh, that could help someday..  Thanks Casascius.. Smiley

But Im more interested in keeping the address created from bitaddress.org


I understand I can keep it through blockchain.info wallet, but hoping I could use it on bitcoin spinner, and or Armory..

For Canadians by Canadians: Canada's Bitcoin Community - https://www.coinforum.ca/
dooglus
Legendary
*
Offline Offline

Activity: 2940
Merit: 1333



View Profile
July 16, 2012, 06:54:45 AM
 #211

2. run:  bitcoind importprivkey 5Je4KHK15KobUcbj29xATN6z6QgZVxL4rYnBD2kaTzncS6oKmqL   (replace 5J... with the private key given to you by bitaddress)

do you need to type your username and password with every command? if so, what syntax is it?

i've only ever done this through JSON, not actually on the command line.

You don't have to type it at all once you have put it into the bitcoin.conf file.  The server will read that file when it starts up, and the client will read it each time you run it (assuming they both run on the same box).  The server will refuse to start if the password isn't set.

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
dooglus
Legendary
*
Offline Offline

Activity: 2940
Merit: 1333



View Profile
July 16, 2012, 06:56:49 AM
 #212


Lmfao!

Are you serious ?  Undecided

No easier way? no way with armory ?

There's no easier way in the satoshi client at the moment.  I don't know if there are plans to make importing private keys available from the GUI.

Maybe Armory can do it, I've almost no experience of Armory.

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
pointbiz (OP)
Sr. Member
****
Offline Offline

Activity: 437
Merit: 415

1ninja


View Profile
July 29, 2012, 08:05:57 PM
 #213

v1.6
https://www.bitaddress.org/bitaddress.org-v1.6-SHA1-162d1ff4fd1e09222cbaca6c282672ee6c195e1b.html
 - Added Brain Wallet Tab. Algorithm is SHA256(passphrase).
   Minimum passphrase length is 15 characters.

Coder of: https://www.bitaddress.org      Thread
Open Source JavaScript Client-Side Bitcoin Wallet Generator
Donations: 1NiNja1bUmhSoTXozBRBEtR8LeF9TGbZBN   PGP
Stephen Gornick
Legendary
*
Offline Offline

Activity: 2506
Merit: 1010


View Profile
July 29, 2012, 09:24:24 PM
 #214


I can verify that the site has been updated and returns the same HTML from the latest commit (4dc7cc64aca58bcf9ee25a859feb9f877623faa8) in github.

To confirm this I first check the sha1sum hash of the html returned by a request to http://bitaddress.org:

$ wget --quiet -O - http://bitaddress.org|sha1sum
162d1ff4fd1e09222cbaca6c282672ee6c195e1b  -

Then from my bitaddress.org repo:

$ git rev-list --max-count=1 HEAD
4dc7cc64aca58bcf9ee25a859feb9f877623faa8

$ sha1sum bitaddress.org.html
162d1ff4fd1e09222cbaca6c282672ee6c195e1b  bitaddress.org.html

Unichange.me

            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █
            █


BkkCoins
Hero Member
*****
Offline Offline

Activity: 784
Merit: 1009


firstbits:1MinerQ


View Profile WWW
July 29, 2012, 11:09:43 PM
Last edit: July 29, 2012, 11:47:19 PM by BkkCoins
 #215

There's no easier way in the satoshi client at the moment.  I don't know if there are plans to make importing private keys available from the GUI.
Are you sure that method works? I was under the impression that the rpc password was different than the password used to encrypt keys.

I haven't tried that way but if I recall I did it like this, with satoshi client,

bitcoind --daemon
bitcoind walletpassphrase  <pwd>
bitcoind importprivkey 5blahblahblah...
bitcoind stop

No file editing. At the import step it took some long time to come back as it scans the chain. This can easily be put in a script file with pwd and key args. eg.

Code:
#!/bin/bash
bitcoind --daemon
sleep 60
bitcoind walletpassphrase  $1 60
bitcoind importprivkey $2 $3
bitcoind stop
(I added the sleep because when first starting the daemon is too busy to take cmds.)

Save to file "importkey", chmod +x importkey.
Now you have a one step way to do it.

importkey <pwd> <key>

But be aware that your pwd is in the cmdline and will be in history file etc. Which is bad. With very small change it could be prompted for instead.

Revised version:
Code:
#!/bin/bash
bitcoind --daemon
echo -n "Enter passphrase:"
read -s pwd
echo "Waiting while server busy"
sleep 60
echo "Unlocking wallet"
bitcoind walletpassphrase  $pwd 60
echo "Importing and scanning the chain"
bitcoind importprivkey $1 $2
echo "Done"
bitcoind stop
I added a few progress msgs. Use like this, (will prompt for passphrase, label optional)

importkey <key> [label]

Note: the gui client cannot be running at same time.

Now we have a one step import. Easy to modify further into a bulk import too.
I leave as an exercise how you might do it with Windows.

Re: v1.6 Brain Wallet
That's awesome! Just tried it. Imported key with script above. Works.

dooglus
Legendary
*
Offline Offline

Activity: 2940
Merit: 1333



View Profile
July 30, 2012, 01:55:08 AM
 #216

Are you sure that method works? I was under the impression that the rpc password was different than the password used to encrypt keys.

No file editing.

My method is the same as yours.  The only file editing needed is to set up bitcoin.conf.  You can't use bitcoind to talk to a bitcoin server unless you specify the username and password.  You can do that on the command line if you like, but it's more convenient to put them into bitcoin.conf once and forget about them.

You will have done that once a long time ago and probably forgot about it already, but a new user who didn't use bitcoind before will need to do it before your scripts will work:

Code:
$ bitcoind getblockcount
191445
$ mv ~/.bitcoin/bitcoin.conf x
$ bitcoind getblockcount
error: You must set rpcpassword=<password> in the configuration file:
/home/chris/.bitcoin/bitcoin.conf
If the file does not exist, create it with owner-readable-only file permissions.
$ mv x ~/.bitcoin/bitcoin.conf
$ bitcoind getblockcount
191445
$

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
BkkCoins
Hero Member
*****
Offline Offline

Activity: 784
Merit: 1009


firstbits:1MinerQ


View Profile WWW
July 30, 2012, 02:33:18 AM
 #217

Ah, you're right. I must have done that long ago as I'd totally forgotten about it.
The rpcpassword is not the same as the encryption one - walletpassphrase.

I tested that you cannot import a private key without knowing the walletpassphrase.

Which is good as otherwise someone with local system access could import hundreds of keys they already own and stand a good chance of later being able to access funds as the client uses them.

It's too bad there isn't an option to tell it not to check the blockchain. For newly created keys that's not needed and it takes so much time.

dooglus
Legendary
*
Offline Offline

Activity: 2940
Merit: 1333



View Profile
July 30, 2012, 07:18:53 PM
 #218

I tested that you cannot import a private key without knowing the walletpassphrase.

The client needs to know the passphrase in order to encrypt the private keys - that's why you can't add a private key if the wallet is locked.

It's too bad there isn't an option to tell it not to check the blockchain. For newly created keys that's not needed and it takes so much time.

I just comment out these two lines in src/rpcdump.cpp:

Code:
        pwalletMain->ScanForWalletTransactions(pindexGenesisBlock, true);
        pwalletMain->ReacceptWalletTransactions();

Then you can import keys really quickly.  Since you've probably just generated the private keys anyway using bitaddress.org it's a real waste of time to scan the blockchain for transactions to and from the keys.  I need to restart bitcoin-qt after importing a batch of keys for the keys to show up in the 'receive coins' tab, but that's much better than having to wait for a full rescan after each importprivkey.

Just-Dice                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   Play or Invest                 ██             
          ██████████         
      ██████████████████     
  ██████████████████████████ 
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
██████████████████████████████
    ██████████████████████   
        ██████████████       
            ██████           
   1% House Edge
casascius
Mike Caldwell
VIP
Legendary
*
Offline Offline

Activity: 1386
Merit: 1140


The Casascius 1oz 10BTC Silver Round (w/ Gold B)


View Profile WWW
July 30, 2012, 09:05:43 PM
 #219

I just comment out these two lines in src/rpcdump.cpp:

Code:
        pwalletMain->ScanForWalletTransactions(pindexGenesisBlock, true);
        pwalletMain->ReacceptWalletTransactions();

Then you can import keys really quickly.  Since you've probably just generated the private keys anyway using bitaddress.org it's a real waste of time to scan the blockchain for transactions to and from the keys.  I need to restart bitcoin-qt after importing a batch of keys for the keys to show up in the 'receive coins' tab, but that's much better than having to wait for a full rescan after each importprivkey.

I did this too, and also modified the -rescan code so that -rescan=170000 (for example) only scans from block 170000 and beyond.  Perfect if you know you're importing recently-received funds.  IIRC, the way I did it was to modify ScanForWalletTransactions() to have one more 64-bit-integer parameter to say how many blocks to skip, and then created an overload so calls lacking the skip number will default to 0.

This way I can import lots of private keys, but only wait for a blockchain rescan once, and only from the starting point where I began receiving payments with those keys.

Companies claiming they got hacked and lost your coins sounds like fraud so perfect it could be called fashionable.  I never believe them.  If I ever experience the misfortune of a real intrusion, I declare I have been honest about the way I have managed the keys in Casascius Coins.  I maintain no ability to recover or reproduce the keys, not even under limitless duress or total intrusion.  Remember that trusting strangers with your coins without any recourse is, as a matter of principle, not a best practice.  Don't keep coins online. Use paper or hardware wallets instead.
Gyrsur
Legendary
*
Offline Offline

Activity: 2856
Merit: 1520


Bitcoin Legal Tender Countries: 2 of 206


View Profile WWW
July 30, 2012, 09:19:08 PM
 #220

So it's JavaScript it means it is client side computing no private key is transmitted over the internet?

Pages: « 1 2 3 4 5 6 7 8 9 10 [11] 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 »
  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!