mirror of
https://github.com/Xahau/xahau.js.git
synced 2025-12-06 17:27:59 +00:00
Update ripple-keypairs
This commit is contained in:
20
npm-shrinkwrap.json
generated
20
npm-shrinkwrap.json
generated
@@ -169,8 +169,8 @@
|
||||
}
|
||||
},
|
||||
"ripple-keypairs": {
|
||||
"version": "0.9.0",
|
||||
"resolved": "https://registry.npmjs.org/ripple-keypairs/-/ripple-keypairs-0.9.0.tgz",
|
||||
"version": "0.10.0",
|
||||
"resolved": "https://registry.npmjs.org/ripple-keypairs/-/ripple-keypairs-0.10.0.tgz",
|
||||
"dependencies": {
|
||||
"brorand": {
|
||||
"version": "1.0.5",
|
||||
@@ -185,22 +185,6 @@
|
||||
"resolved": "https://registry.npmjs.org/inherits/-/inherits-2.0.1.tgz"
|
||||
}
|
||||
}
|
||||
},
|
||||
"ripple-address-codec": {
|
||||
"version": "1.6.0",
|
||||
"resolved": "https://registry.npmjs.org/ripple-address-codec/-/ripple-address-codec-1.6.0.tgz",
|
||||
"dependencies": {
|
||||
"x-address-codec": {
|
||||
"version": "0.6.0",
|
||||
"resolved": "https://registry.npmjs.org/x-address-codec/-/x-address-codec-0.6.0.tgz",
|
||||
"dependencies": {
|
||||
"base-x": {
|
||||
"version": "1.0.1",
|
||||
"resolved": "https://registry.npmjs.org/base-x/-/base-x-1.0.1.tgz"
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
|
||||
@@ -28,7 +28,7 @@
|
||||
"lru-cache": "~2.5.0",
|
||||
"ripple-address-codec": "^2.0.1",
|
||||
"ripple-binary-codec": "^0.0.6",
|
||||
"ripple-keypairs": "^0.9.0",
|
||||
"ripple-keypairs": "^0.10.0",
|
||||
"ripple-lib-transactionparser": "^0.5.1",
|
||||
"ripple-lib-value": "0.1.0",
|
||||
"sjcl-codec": "0.1.0",
|
||||
|
||||
@@ -33,7 +33,7 @@ function hashSerialization(serialized, prefix) {
|
||||
|
||||
function computeSignature(txJSON, privateKey) {
|
||||
const signingData = binary.encodeForSigning(txJSON);
|
||||
return keypairs.sign(new Buffer(signingData, 'hex'), privateKey);
|
||||
return keypairs.sign(signingData, privateKey);
|
||||
}
|
||||
|
||||
function sign(txJSON: string, secret: string
|
||||
|
||||
@@ -507,8 +507,7 @@ Transaction.prototype.sign = function(secret) {
|
||||
}
|
||||
|
||||
const keypair = deriveKeypair(secret || this._secret);
|
||||
this.tx_json.TxnSignature = sign(new Buffer(this.signingData(), 'hex'),
|
||||
keypair.privateKey);
|
||||
this.tx_json.TxnSignature = sign(this.signingData(), keypair.privateKey);
|
||||
this.previousSigningHash = hash;
|
||||
|
||||
return this;
|
||||
@@ -1656,7 +1655,7 @@ Transaction.prototype.multiSign = function(account, secret) {
|
||||
|
||||
const signer = {
|
||||
Account: account,
|
||||
TxnSignature: sign(new Buffer(signingData, 'hex'), keypair.privateKey),
|
||||
TxnSignature: sign(signingData, keypair.privateKey),
|
||||
SigningPubKey: keypair.publicKey
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user