diff options
author | Joey Hess <joeyh@joeyh.name> | 2016-08-16 13:40:52 -0400 |
---|---|---|
committer | Joey Hess <joeyh@joeyh.name> | 2016-08-16 13:40:52 -0400 |
commit | c9c476ae7216b80932b80870a2cd06f9339306aa (patch) | |
tree | ad2255c1d331bb2f286d7786e65151ba987a8247 /Types.hs | |
parent | 3229b02f0aa6bb23e351d00ade1263851a2f1826 (diff) | |
download | keysafe-c9c476ae7216b80932b80870a2cd06f9339306aa.tar.gz |
improve options to select secret key to backup/restore
Diffstat (limited to 'Types.hs')
-rw-r--r-- | Types.hs | 12 |
1 files changed, 5 insertions, 7 deletions
@@ -45,18 +45,16 @@ newtype Password = Password B.ByteString newtype Name = Name B.ByteString deriving (Show) --- | The type of the key that is stored in keysafe. -newtype KeyType = KeyType B.ByteString +-- | Source of the secret key stored in keysafe. +data SecretKeySource = GpgKey KeyId | KeyFile FilePath deriving (Show) -gpgKey :: KeyType -gpgKey = KeyType "gpg" - -- | The keyid is any value that is unique to a private key, and can be -- looked up somehow without knowing the private key. -- --- A gpg keyid is the obvious example. -data KeyId = KeyId KeyType B.ByteString +-- A gpg keyid is the obvious example. But, if a gpg key is not +-- stored on the key servers, keysafe will instead use "". +data KeyId = KeyId B.ByteString deriving (Show) data BenchmarkResult t = BenchmarkResult { expectedBenchmark :: t, actualBenchmark :: t } |