summaryrefslogtreecommitdiffhomepage
path: root/Crypto.hs
diff options
context:
space:
mode:
authorJoey Hess <joeyh@joeyh.name>2017-05-20 15:16:40 -0400
committerJoey Hess <joeyh@joeyh.name>2017-05-20 15:16:40 -0400
commit34b0151e125a6698f57ea476ccfa922c6275edf1 (patch)
treec4c7f57421ae1e7b87bb0f8b82ff97a1cec93222 /Crypto.hs
parent2e16195d151d401a664fa929604413aa613aa9f5 (diff)
downloaddebug-me-34b0151e125a6698f57ea476ccfa922c6275edf1.tar.gz
move unsafe hashing out of instance to avoid misuse
Avoids breaking backwards compat and should avoid future foot-shooting.
Diffstat (limited to 'Crypto.hs')
-rw-r--r--Crypto.hs2
1 files changed, 1 insertions, 1 deletions
diff --git a/Crypto.hs b/Crypto.hs
index efc754f..2fe27e0 100644
--- a/Crypto.hs
+++ b/Crypto.hs
@@ -31,7 +31,7 @@ class Signed t where
instance Hashable a => Signed (Activity a) where
getSignature = activitySignature
hashExceptSignature (Activity a mpa mpe mt _s) = hash $
- Tagged "Activity" [hash a, hash mpa, hash mpe, hash mt]
+ Tagged "Activity" [hash a, hashOfMaybeUnsafe mpa, hashOfMaybeUnsafe mpe, hash mt]
instance Signed Control where
getSignature = controlSignature