Pages:
Author

Topic: Prize for importing private key [WON] - page 5. (Read 18052 times)

hero member
Activity: 532
Merit: 500
FIAT LIBERTAS RVAT CAELVM
February 20, 2011, 06:35:26 AM
#7
The corresponding bitcoin address is 17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL. Here's the blockexplorer link: http://blockexplorer.com/address/17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL. When the balance goes to zero, someone's got it.

Address is the public key. He's given us everything we need, we just need to figure out how to stick the private key into a wallet, and then send ourselves the coins.
kvk
newbie
Activity: 7
Merit: 0
February 20, 2011, 06:30:59 AM
#6
As far i understand the bitcoin, it's not really possible to redeem the coins with only private key, the script expects full public key to compare with hash160 and to verify signature. Since no coins were redeemed with this address, the pubkey is not known and the task of reversing the hash is impossible.
administrator
Activity: 5222
Merit: 13027
hero member
Activity: 532
Merit: 500
FIAT LIBERTAS RVAT CAELVM
February 20, 2011, 05:41:55 AM
#4
Correct me if I'm wrong, but aren't Bitcoin private keys 279 bytes long?
Base 58. Each digit in that string can hold a lot of numbers: 123456789abcdefghijkmnopqrstuvwxyzABCDEFGHJKLMNPQRSTUVWXYZ

It's a great way to have a LOT of possibilities, in a small space, with little chance of error when hand-entering data.

So, it is 279 bytes long, if it were converted out. (or, it should be. I don't feel like doing the math at the moment)
legendary
Activity: 1288
Merit: 1076
February 20, 2011, 04:58:59 AM
#3
Damn it Hal, that's very mean.  Now we have to work on this or we'll look like fools.

I think I could manage to do that by tweaking the bitcoin code and recompiling.  But I'd have to use a brand new wallet cause I don't like to mess with my wallet.

PS.  pff  I give up.  I've tried to tweak the code for generating a new address.

Code:
vector GenerateNewKey()
{
    RandAddSeedPerfmon();
    CKey key;
    key.MakeNewKey();
    if (!AddKey(key))
throw runtime_error("GenerateNewKey() : AddKey failed");

    //  this is what I tried
    unsigned int nSize = i2d_ECPrivateKey(key.pkey, NULL);  // I had to set pkey public in Ckey
    if (!nSize)
throw key_error("CKey::GetPrivKey() : i2d_ECPrivateKey failed");
    CPrivKey vchPrivKey(nSize, 0);
    unsigned char* pbegin = &vchPrivKey[0];
    vector& vchRet;
    DecodeBase58("2qy6pGXd5yCo9qy3vxnN7rALgsXXcdboReZ9NZx5aExy", vchRet);
    strcpy(pbegin, vchRet); 
    key.SetPrivKey(vchRet);
    //  end of what I tried

    return key.GetPubKey();
}


The idea was to create the private key with the getnewaddress command.

It doesn't compile since vchRet is not a CPrivKey object.   I don't understand well enough what CPrivKey is.

Good luck to other people who will try.

Hal
vip
Activity: 314
Merit: 3853
February 19, 2011, 08:10:50 PM
#2
The corresponding bitcoin address is 17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL. Here's the blockexplorer link: http://blockexplorer.com/address/17kzeh4N8g49GFvdDzSf8PjaPfyoD1MndL. When the balance goes to zero, someone's got it.
Hal
vip
Activity: 314
Merit: 3853
February 19, 2011, 06:36:49 PM
#1
This is a base58 encoded plain private key (256 bit value from a "key" entry in my wallet) worth 20 BTC. We're now at block 109180. Let's see how long it takes for someone to input the key and collect the bitcoins.

2qy6pGXd5yCo9qy3vxnN7rALgsXXcdboReZ9NZx5aExy

ETA: this is wrong, the correct value is later in the thread
Pages:
Jump to: