diff options
author | Joey Hess <joeyh@joeyh.name> | 2017-04-19 20:07:47 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2017-04-19 20:07:47 -0400 |
commit | f7999cecc2bb0c76d88005444478e8500c624786 (patch) | |
tree | 9deccd684e1333dca028d980489892ac4189582b /Types.hs | |
parent | 6f7cf857b408401abdc4477c888495b4f13162c7 (diff) | |
download | debug-me-f7999cecc2bb0c76d88005444478e8500c624786.tar.gz |
fully working signatures
This commit was sponsored by Ethan Aubin.
Diffstat (limited to 'Types.hs')
-rw-r--r-- | Types.hs | 7 |
1 files changed, 5 insertions, 2 deletions
@@ -50,6 +50,9 @@ instance DataSize a => DataSize (Message a) where -- to a previous Activity. -- -- The Signature is over both the data in the activity, and its pointer. +-- +-- Note that the Signature is included in the Hash of an Activity, +-- which is why it's part of the Activity. data Activity a = Activity { activity :: a , prevActivity :: Maybe Hash @@ -119,7 +122,7 @@ instance DataSize Signature where -- | A public key used for a debug-me session. -- It may be signed with a gpg key. data PublicKey = PublicKey Val (Maybe GpgSig) - deriving (Show, Generic) + deriving (Show, Generic, Eq) instance DataSize PublicKey where -- ed25519 public keys are 32 bytes @@ -127,7 +130,7 @@ instance DataSize PublicKey where -- | A signature made with a gpg key. newtype GpgSig = GpgSig Val - deriving (Show, Generic) + deriving (Show, Generic, Eq) instance DataSize GpgSig where dataSize (GpgSig s) = dataSize s |