Bitcoin Forum
June 29, 2024, 08:59:12 AM *
News: Latest Bitcoin Core release: 27.0 [Torrent]
 
   Home   Help Search Login Register More  
Pages: [1]
  Print  
Author Topic: Bitcoin-Lib-PHP problem  (Read 892 times)
temple (OP)
Hero Member
*****
Offline Offline

Activity: 1456
Merit: 539


View Profile
September 11, 2014, 04:52:08 PM
Last edit: March 06, 2023, 09:33:11 AM by temple
 #1

Could anyone help me on this issue?

https://github.com/Bit-Wasp/bitcoin-lib-php/issues/19

basee on https://github.com/Bit-Wasp/bitcoin-lib-php/blob/master/examples/electrum.php
I change the magic_byte ='00' to '41' for templecoin
and come up with as follows:

https://templecoin.com/api/electrum/private.php

put the seed as follows (without quotation)
"smart shut inside pride milk linger pretty happen stupid lung warmth zone"

look at the #5
QWTbEwMvmw4aKtao2taKDGM4y41Le7cgGcjPQWGyDsBHQ9mMXH

It is invalid, others are the same as electrum, I can't figure out how to solve this problem.

The source for the private WIF:

$magic_byte = '41';
$string = trim($seed);
$seed = Electrum::decode_mnemonic($string);

for($i = $startidx; $i < $startidx+10; $i++) {
$privkey = Electrum::generate_private_key($seed, $i,0);
$wif=BitcoinLib::private_key_to_WIF($privkey, FALSE, $magic_byte);
echo "$i ::
";
}

I need help on this.

UPDATE: I change the magic_byte='0' will have the same problem.
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!