You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Apr 3, 2019. It is now read-only.
When adding a network that shares the same xpriv bytes as another, HDPrivateKey will return the incorrect network because it bases its decision only on those bytes. Should it store the actual network used instead? Maybe the network name?
> var b = require('bitcore-lib');
> var c = require('coininfo');
> var dashmain = c.dash.main.toBitcore();
> dashmain.name = 'dash';
> dashmain.alias = 'dashmainnet';
> b.Networks.add(dashmain);
> b.HDPrivateKey('dash').network
'dash' # OK
> b.HDPrivateKey(b.Networks.mainnet).network
'dash' # FAIL
Without modifying:
> var b = require('bitcore-lib');
> b.HDPrivateKey(b.Networks.mainnet).network.name
'livenet' # OK
The text was updated successfully, but these errors were encountered:
Hello,
When adding a network that shares the same xpriv bytes as another, HDPrivateKey will return the incorrect network because it bases its decision only on those bytes. Should it store the actual network used instead? Maybe the network name?
Without modifying:
The text was updated successfully, but these errors were encountered: