Hunting Bitcoin private keys and solving crypto puzzles. https://privatekeys.pw
ok ok.... i have found some realization
Читать полностью…Anybody knows the answer? Cmon guys (girls)....
Читать полностью…Use that PhD and help find that openssl flaw in the version Satoshi used back in 2012
Читать полностью…and nowhere to simply read this. Jeez. Why they dont simply written this in.. i dont know... pseudo code or whatever.....
Читать полностью…It feels soooo simple having that code above
Читать полностью…what you need to do which that?
Читать полностью…I thought 192 == 128 + 64 and so the new lengths would be 256 + 64
Читать полностью…i almost sure, the "adaptation" simply requires to extend the ipad \ opad to 3 128 bytes chunks, fill the ipad and opad with mnemonic bytes and fill the left with "36" "5C" and place the "salt" in the third 128 bytes chunk.
Читать полностью…better than nothing but not really helpful
Читать полностью…I’m gonna honestly stop my laziness and write something in cuda
Читать полностью…compiller try itself to optimize the code
Читать полностью…Gave up and started accumulating hate for cuda
Читать полностью…But each core will be doing the whole series of operations sequentially again and again
Читать полностью…but even if i will understand this - would be actualy hard to manage all those bitwise hell into nice pipes... even sha256 looks like a hell to me, hmac-sha512 is some imbossible meat-sloter
Читать полностью…Why this is not the answer ??? WHYYYYYYYYYYYYY!!!!!!!!!!!!!!!!!!
uint8_t mnemonic[220] = { 0 };
uint32_t ipad[(3*128) / 4];
uint32_t opad[(3*128) / 4];
uint32_t seed[64 / 4] = { 0 };
for (int x = 0; x < (2*120) / 8; x++)
*(uint64_t*)((uint64_t*)ipad + x) = 0x3636363636363636ULL ^ SWAP512(*(uint64_t*)((uint64_t*)mnemonic + x));
for (int x = 0; x < (2*120) / 8; x++)
*(uint64_t*)((uint64_t*)opad + x) = 0x5C5C5C5C5C5C5C5CULL ^ SWAP512(*(uint64_t*)((uint64_t*)mnemonic + x));
for (int x = (2*120) / 4; x < (2*128) / 4; x++)
ipad[x] = 0x36363636;
for (int x = (2*120) / 4; x < (2*128) / 4; x++)
opad[x] = 0x5C5C5C5C;
for (int x = 0; x < 16 / 4; x++)
ipad[x + (2*128) / 4] = *(uint32_t*)((uint32_t*)&salt_swap + x);
sha512_swap((uint64_t*)ipad, (2*128+16-4), (uint64_t*)&opad[(2*128) / 4]);
sha512_swap((uint64_t*)opad, (2*128 + 64), (uint64_t*)&ipad[(2*128) / 4]);
for (int x = 0; x < 64 / 4; x++)
seed[x] = ipad[(2*128) / 4 + x];
for (int x = 1; x < 2048; x++){
sha512_swap((uint64_t*)ipad, (2*128 + 64), (uint64_t*)&opad[(2*128) / 4]);
sha512_swap((uint64_t*)opad, (2*128 + 64), (uint64_t*)&ipad[(2*128) / 4]);
for (int x = 0; x < 64 / 4; x++)
seed[x] = seed[x] ^ ipad[(2*128) / 4 + x];
}
god damn..... how to get the seed for 24 words
Читать полностью…all wallets\clients simply uses openssl
Читать полностью…but same time .... nothing works right
Читать полностью…yeah i see, very interesting question but I never tested things with mnemonics and keys
Читать полностью…(this is real working code that suits me - but it is written for 12 words mnemonic and nope - it wont work for 24 words, the 24 words occupy much more than 120 bytes - actually up to 215 bytes)
Читать полностью…while 140.... well..... 128 + 16 - 4 and the adapted would be 256 + 16 -4
Читать полностью…but i am not sure what to do with those sha_512 swaps further
Читать полностью…uint8_t mnemonic[220] = { 0 };
uint32_t ipad[256 / 4];
uint32_t opad[256 / 4];
uint32_t seed[64 / 4] = { 0 };
for (int x = 0; x < 120 / 8; x++)
*(uint64_t*)((uint64_t*)ipad + x) = 0x3636363636363636ULL ^ SWAP512(*(uint64_t*)((uint64_t*)mnemonic + x));
for (int x = 0; x < 120 / 8; x++)
*(uint64_t*)((uint64_t*)opad + x) = 0x5C5C5C5C5C5C5C5CULL ^ SWAP512(*(uint64_t*)((uint64_t*)mnemonic + x));
for (int x = 120 / 4; x < 128 / 4; x++)
ipad[x] = 0x36363636;
for (int x = 120 / 4; x < 128 / 4; x++)
opad[x] = 0x5C5C5C5C;
for (int x = 0; x < 16 / 4; x++)
ipad[x + 128 / 4] = *(uint32_t*)((uint32_t*)&salt_swap + x);
sha512_swap((uint64_t*)ipad, 140, (uint64_t*)&opad[128 / 4]);
sha512_swap((uint64_t*)opad, 192, (uint64_t*)&ipad[128 / 4]);
for (int x = 0; x < 64 / 4; x++)
seed[x] = ipad[128 / 4 + x];
for (int x = 1; x < 2048; x++){
sha512_swap((uint64_t*)ipad, 192, (uint64_t*)&opad[128 / 4]);
sha512_swap((uint64_t*)opad, 192, (uint64_t*)&ipad[128 / 4]);
for (int x = 0; x < 64 / 4; x++)
seed[x] = seed[x] ^ ipad[128 / 4 + x];
}
This is the code for HMAC-SHA512 (PBKDF2) that takes 12 words mnemonic and turns it to the "seed" that i used further as master key in BIP39 keys derivation.
The SIMPLE question: "How to adapt it to at least 24 words? (better adapt to any mnemonic length)
Damn. I tried to find some real implementations and have not found anything. The only real thing i have found was the openssl implementation, but it is not straightforward for me to easily grab it.
Hey.... are you pretty?
(can you help me understand the hmac-sha512 ?)
so some of this thing could have been already made by compiller
Читать полностью…aaand yet its possible that something like that is already done by the compiller
Читать полностью…I tried with ripemd160 for few months
Читать полностью…I think same cores could run a set series of operations
Читать полностью…but what if same cores could run {operationA(thread1 | thread2 | thread3) operationB(thread4 | thread5 | thread6) operationC(thread7|thread8|thread9)) etc....
Читать полностью…