summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjoe <joe@jerkface.net>2016-08-29 16:05:04 -0400
committerjoe <joe@jerkface.net>2016-08-29 16:05:04 -0400
commit5c6d9d1a2810eba2772dcdbee255e11144e21176 (patch)
treed457d282f95ea60096ba002705de9e1b6d998256
parent1eff837423de69ece2a85430a7ad433b7c1a504a (diff)
Added "encrypt" and "sign" keys to be generated.
-rw-r--r--lib/KeyRing.hs30
-rw-r--r--lib/Kiki.hs4
2 files changed, 18 insertions, 16 deletions
diff --git a/lib/KeyRing.hs b/lib/KeyRing.hs
index e084fcd..8a23ff9 100644
--- a/lib/KeyRing.hs
+++ b/lib/KeyRing.hs
@@ -585,21 +585,21 @@ keyflags _ = Nothing
585 585
586data PGPKeyFlags = 586data PGPKeyFlags =
587 Special 587 Special
588 | Vouch -- Signkey 588 | Vouch -- 0001 C -- Signkey
589 | Sign 589 | Sign -- 0010 S
590 | VouchSign 590 | VouchSign -- 0011
591 | Communication 591 | Communication -- 0100 E
592 | VouchCommunication 592 | VouchCommunication -- 0101
593 | SignCommunication 593 | SignCommunication -- 0110
594 | VouchSignCommunication 594 | VouchSignCommunication -- 0111
595 | Storage 595 | Storage -- 1000 E
596 | VouchStorage 596 | VouchStorage -- 1001
597 | SignStorage 597 | SignStorage -- 1010
598 | VouchSignStorage 598 | VouchSignStorage -- 1011
599 | Encrypt 599 | Encrypt -- 1100 E
600 | VouchEncrypt 600 | VouchEncrypt -- 1101
601 | SignEncrypt 601 | SignEncrypt -- 1110
602 | VouchSignEncrypt 602 | VouchSignEncrypt -- 1111
603 deriving (Eq,Show,Read,Enum) 603 deriving (Eq,Show,Read,Enum)
604 604
605 605
diff --git a/lib/Kiki.hs b/lib/Kiki.hs
index c042540..90d1699 100644
--- a/lib/Kiki.hs
+++ b/lib/Kiki.hs
@@ -255,9 +255,11 @@ importAndRefresh root cmn = do
255 , initializer = NoCreate 255 , initializer = NoCreate
256 , transforms = [] } 256 , transforms = [] }
257 _ -> strm { spill = KF_Match "tor" }) 257 _ -> strm { spill = KF_Match "tor" })
258 , ( Generate 1 (GenRSA (1024 `div` 8)), strm { spill = KF_Match "ipsec" }) 258 , ( Generate 1 (GenRSA (2048 `div` 8)), strm { spill = KF_Match "ipsec" })
259 , ( ArgFile sshcpath, (peminfo 2048 "ssh-client") ) 259 , ( ArgFile sshcpath, (peminfo 2048 "ssh-client") )
260 , ( ArgFile sshspath, (peminfo 2048 "ssh-server") ) 260 , ( ArgFile sshspath, (peminfo 2048 "ssh-server") )
261 , ( Generate 2 (GenRSA (4096 `div` 8)), strm { spill = KF_Match "encrypt" })
262 , ( Generate 3 (GenRSA (4096 `div` 8)), strm { spill = KF_Match "sign" })
261 ] 263 ]
262 , opPassphrases = withAgent $ pwds ++ do pfd <- maybeToList passfd 264 , opPassphrases = withAgent $ pwds ++ do pfd <- maybeToList passfd
263 return $ PassphraseSpec Nothing Nothing pfd 265 return $ PassphraseSpec Nothing Nothing pfd