|
@@ 759-763 (lines=5) @@
|
| 756 |
|
$backupSeed = isset($options['backup_seed']) ? $options['backup_seed'] : self::randomBits(256); |
| 757 |
|
} |
| 758 |
|
|
| 759 |
|
if (isset($options['primary_private_key'])) { |
| 760 |
|
$options['primary_private_key'] = BlocktrailSDK::normalizeBIP32Key($options['primary_private_key']); |
| 761 |
|
} else { |
| 762 |
|
$options['primary_private_key'] = BIP32Key::create(HierarchicalKeyFactory::fromEntropy(new Buffer($primarySeed)), "m"); |
| 763 |
|
} |
| 764 |
|
|
| 765 |
|
// create primary public key from the created private key |
| 766 |
|
$options['primary_public_key'] = $options['primary_private_key']->buildKey($walletPath->keyIndexPath()->publicPath()); |
|
@@ 897-901 (lines=5) @@
|
| 894 |
|
} |
| 895 |
|
} |
| 896 |
|
|
| 897 |
|
if (isset($options['primary_private_key'])) { |
| 898 |
|
$options['primary_private_key'] = BlocktrailSDK::normalizeBIP32Key($options['primary_private_key']); |
| 899 |
|
} else { |
| 900 |
|
$options['primary_private_key'] = BIP32Key::create(HierarchicalKeyFactory::fromEntropy($primarySeed), "m"); |
| 901 |
|
} |
| 902 |
|
|
| 903 |
|
// create primary public key from the created private key |
| 904 |
|
$options['primary_public_key'] = $options['primary_private_key']->buildKey($walletPath->keyIndexPath()->publicPath()); |