Comments (3)
This is something that should be addressed soon.. The private_key_to_WIF function calls a function get_private_key_address_version.. which is not compatible with some altcoins, which deviate from how bitcoin does it I think. (It adds 0x80 to the address version)
Looking into ways to change the coin networks at the moment, but for now I would do this instead of your line: $wif = .....
$_privkey_version = '??'; // not the regular address version, check out the templecoin-qt source
$compressed = FALSE; // false because electrum uses 04... keys, not shorter ones. just bear this in mind!
for($i = $startidx; $i < $startidx+10; $i++){
$privkey = Electrum::generate_private_key($seed, $i,0);
$_to_wif = $_privkey_version . $privkey . (($compressed == TRUE) ? '01' : '');
$wif = self::base58_encode_checksum($_to_wif);
}
from bitcoin-lib-php.
thanks your reply, i would try out something a little bit later
However, what I mentioned that use "smart shut inside pride milk linger pretty happen stupid lung warmth zone" phrases also will hapeen for bitcoin to get an invalid WIF address.
I can't figure out on this too.
from bitcoin-lib-php.
in the #26 PR I still rely on the private key version being address version +0x80
we could also add the private key version to that instead of calculating it?
from bitcoin-lib-php.
Related Issues (20)
- How to use createrawtransaction and set fees? HOT 18
- electrum HOT 1
- decode fails to read a vout HOT 2
- RawTransaction::decode will fail on version numbers that are not equal to 1.
- Support OP_RETURN transaction ?
- Unnecessary cast in toBTC()
- implement BIP173 - SegWit HOT 5
- Generating change address from publicKey Bip44, Bip43
- Function mcrypt_create_iv() is deprecated HOT 1
- Namespace Issue HOT 3
- Is it possible to create Segwit addresses? HOT 1
- Ignore - Delete
- other coins wallet
- Replace mdanter/ecc with paragonie/ecc
- How i can list unspent transaction for any private key of address. HOT 5
- Electrum 2.0 xpub HOT 3
- parse error HOT 4
- installation problem HOT 2
- bits -> difficulty? HOT 2
- Feature Request: capability to derive all (used) wallet keys from public master key. HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from bitcoin-lib-php.