aboutsummaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorLeonid Logvinov <logvinov.leon@gmail.com>2018-07-03 20:47:13 +0800
committerLeonid Logvinov <logvinov.leon@gmail.com>2018-07-05 21:05:57 +0800
commit9c8de3e933d607b54e0d0a19f0a3e39bc356d6d9 (patch)
tree8381ec758f02139730d89b988c621239ac9f4180 /packages
parentcbdce6b67ee4ad44feb63766c4af613c18bf505d (diff)
downloaddexon-0x-contracts-9c8de3e933d607b54e0d0a19f0a3e39bc356d6d9.tar.gz
dexon-0x-contracts-9c8de3e933d607b54e0d0a19f0a3e39bc356d6d9.tar.zst
dexon-0x-contracts-9c8de3e933d607b54e0d0a19f0a3e39bc356d6d9.zip
Fix VRS signature generation in order-utils
Diffstat (limited to 'packages')
-rw-r--r--packages/order-utils/src/order_factory.ts5
1 files changed, 3 insertions, 2 deletions
diff --git a/packages/order-utils/src/order_factory.ts b/packages/order-utils/src/order_factory.ts
index 678336ac5..803cb82b1 100644
--- a/packages/order-utils/src/order_factory.ts
+++ b/packages/order-utils/src/order_factory.ts
@@ -57,9 +57,10 @@ export const orderFactory = {
};
function getVRSHexString(ecSignature: ECSignature): string {
- const vrs = `0x${intToHex(ecSignature.v)}${ethUtil.stripHexPrefix(ecSignature.r)}${ethUtil.stripHexPrefix(
+ const ETH_SIGN_SIGNATURE_TYPE = '03';
+ const vrs = `${intToHex(ecSignature.v)}${ethUtil.stripHexPrefix(ecSignature.r)}${ethUtil.stripHexPrefix(
ecSignature.s,
- )}`;
+ )}${ETH_SIGN_SIGNATURE_TYPE}`;
return vrs;
}