aboutsummaryrefslogtreecommitdiffstats
path: root/packages
diff options
context:
space:
mode:
authorFabio Berger <me@fabioberger.com>2018-05-23 07:37:17 +0800
committerFabio Berger <me@fabioberger.com>2018-05-23 07:37:17 +0800
commit05cabded020c5c50378af76ac638b0f9c73fab1e (patch)
tree2d5925fdf021cb246bf930436817137a1833852b /packages
parent1578402cbe308260dcebb62a11b0460b998d2793 (diff)
downloaddexon-sol-tools-05cabded020c5c50378af76ac638b0f9c73fab1e.tar.gz
dexon-sol-tools-05cabded020c5c50378af76ac638b0f9c73fab1e.tar.zst
dexon-sol-tools-05cabded020c5c50378af76ac638b0f9c73fab1e.zip
Fix signature verification test
Diffstat (limited to 'packages')
-rw-r--r--packages/order-utils/src/signature_utils.ts2
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 28a8e7241..ebd636b20 100644
--- a/packages/order-utils/src/signature_utils.ts
+++ b/packages/order-utils/src/signature_utils.ts
@@ -99,7 +99,7 @@ function parseSignatureHexAsVRS(signatureHex: string): ECSignature {
// HACK: Sometimes v is returned as [0, 1] and sometimes as [27, 28]
// If it is returned as [0, 1], add 27 to both so it becomes [27, 28]
const lowestValidV = 27;
- const isProperlyFormattedV = v < lowestValidV;
+ const isProperlyFormattedV = v >= lowestValidV;
if (!isProperlyFormattedV) {
v += lowestValidV;
}