diff options
author | Greg Hysen <greg.hysen@gmail.com> | 2018-08-24 17:42:20 +0800 |
---|---|---|
committer | Amir Bandeali <abandeali1@gmail.com> | 2018-08-25 05:40:00 +0800 |
commit | 241534a63dab54172326ec71d6b5e78733bb24c6 (patch) | |
tree | b5a903a14895e672d9a5f1a705e360cb4d17958e /packages/order-utils | |
parent | 1932aff35c6b07093534cde66dec63c5f919fcf0 (diff) | |
download | dexon-sol-tools-241534a63dab54172326ec71d6b5e78733bb24c6.tar dexon-sol-tools-241534a63dab54172326ec71d6b5e78733bb24c6.tar.gz dexon-sol-tools-241534a63dab54172326ec71d6b5e78733bb24c6.tar.bz2 dexon-sol-tools-241534a63dab54172326ec71d6b5e78733bb24c6.tar.lz dexon-sol-tools-241534a63dab54172326ec71d6b5e78733bb24c6.tar.xz dexon-sol-tools-241534a63dab54172326ec71d6b5e78733bb24c6.tar.zst dexon-sol-tools-241534a63dab54172326ec71d6b5e78733bb24c6.zip |
Fixed trezor personal message in client+contracts; added a test using message signed by Trezor One (firmware v1.6.2)
Diffstat (limited to 'packages/order-utils')
-rw-r--r-- | packages/order-utils/src/signature_utils.ts | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/packages/order-utils/src/signature_utils.ts b/packages/order-utils/src/signature_utils.ts index 23577efdc..c18e895f5 100644 --- a/packages/order-utils/src/signature_utils.ts +++ b/packages/order-utils/src/signature_utils.ts @@ -347,7 +347,7 @@ export const signatureUtils = { }; function hashTrezorPersonalMessage(message: Buffer): Buffer { - const prefix = ethUtil.toBuffer('\x19Ethereum Signed Message:\n' + String.fromCharCode(message.byteLength)); + const prefix = ethUtil.toBuffer('\x19Ethereum Signed Message:\n' + message.byteLength); return ethUtil.sha3(Buffer.concat([prefix, message])); } |