diff options
author | Andrew Cady <d@jerkface.net> | 2019-07-09 17:00:53 -0400 |
---|---|---|
committer | Andrew Cady <d@jerkface.net> | 2019-07-09 17:00:53 -0400 |
commit | f89d7cc984dd780159906dbd9f37371c057c467d (patch) | |
tree | 2ae0a5a0e70aaa5be284f3d750119df25fe9d501 /lib | |
parent | f7bc9de981616fadffe6556c7aba938dfbe06317 (diff) |
redundant imports
Diffstat (limited to 'lib')
-rw-r--r-- | lib/KeyRing/BuildKeyDB.hs | 38 |
1 files changed, 10 insertions, 28 deletions
diff --git a/lib/KeyRing/BuildKeyDB.hs b/lib/KeyRing/BuildKeyDB.hs index 2074ce3..afee71a 100644 --- a/lib/KeyRing/BuildKeyDB.hs +++ b/lib/KeyRing/BuildKeyDB.hs | |||
@@ -11,7 +11,6 @@ module KeyRing.BuildKeyDB where | |||
11 | 11 | ||
12 | #if defined(VERSION_memory) | 12 | #if defined(VERSION_memory) |
13 | import Data.ByteArray.Encoding | 13 | import Data.ByteArray.Encoding |
14 | import qualified Data.ByteString.Char8 as S8 | ||
15 | import qualified Data.ByteString as S | 14 | import qualified Data.ByteString as S |
16 | #elif defined(VERSION_dataenc) | 15 | #elif defined(VERSION_dataenc) |
17 | import qualified Codec.Binary.Base32 as Base32 | 16 | import qualified Codec.Binary.Base32 as Base32 |
@@ -19,7 +18,6 @@ import qualified Codec.Binary.Base64 as Base64 | |||
19 | #endif | 18 | #endif |
20 | import qualified Codec.Encryption.OpenPGP.ASCIIArmor as ASCIIArmor | 19 | import qualified Codec.Encryption.OpenPGP.ASCIIArmor as ASCIIArmor |
21 | import Codec.Encryption.OpenPGP.ASCIIArmor.Types | 20 | import Codec.Encryption.OpenPGP.ASCIIArmor.Types |
22 | import Control.Applicative (liftA2) | ||
23 | import Control.Arrow (first, second) | 21 | import Control.Arrow (first, second) |
24 | import Control.Exception (catch) | 22 | import Control.Exception (catch) |
25 | import Control.Monad | 23 | import Control.Monad |
@@ -27,52 +25,37 @@ import ControlMaybe (handleIO_) | |||
27 | import Data.ASN1.BinaryEncoding (DER (..)) | 25 | import Data.ASN1.BinaryEncoding (DER (..)) |
28 | import Data.ASN1.Encoding (decodeASN1, encodeASN1) | 26 | import Data.ASN1.Encoding (decodeASN1, encodeASN1) |
29 | 27 | ||
30 | import Data.ASN1.Types (ASN1 (BitString, End, IntVal, Null, OID, Start), | 28 | import Data.ASN1.Types (ASN1 (End, IntVal, Start), ASN1ConstructionType (Sequence), ASN1Object, fromASN1, toASN1) |
31 | ASN1ConstructionType (Sequence), ASN1Object, | 29 | |
32 | fromASN1, toASN1) | 30 | |
33 | import Data.Binary | 31 | import Data.Binary |
34 | import Data.Bits ((.&.), (.|.)) | 32 | import Data.Bits (testBit) |
35 | import Data.Bits (Bits, testBit) | ||
36 | import qualified Data.ByteString as S (ByteString, breakSubstring, | ||
37 | concat, drop, hGetContents, | ||
38 | hPutStr, length, null, | ||
39 | readFile, spanEnd, unpack) | ||
40 | import Data.ByteString.Lazy (ByteString) | 33 | import Data.ByteString.Lazy (ByteString) |
41 | import qualified Data.ByteString.Lazy as L (ByteString, concat, empty, | 34 | import qualified Data.ByteString.Lazy as L (ByteString, concat, empty, |
42 | fromChunks, hGetContents, | 35 | hGetContents, |
43 | null, readFile, toChunks, | 36 | null, toChunks, |
44 | toStrict, head) | 37 | toStrict, head) |
45 | import Data.Char | 38 | import Data.Char |
46 | import Data.Function | ||
47 | import Data.List | 39 | import Data.List |
48 | import qualified Data.Map as Map | 40 | import qualified Data.Map as Map |
49 | import Data.Maybe | 41 | import Data.Maybe |
50 | import Data.Monoid | ||
51 | import Data.OpenPGP | 42 | import Data.OpenPGP |
52 | import Data.OpenPGP.Util (GenerateKeyParams (..), | 43 | import Data.OpenPGP.Util (GenerateKeyParams (..), fingerprint, generateKey, pgpSign, verify) |
53 | decryptSecretKey, fingerprint, | 44 | |
54 | generateKey, pgpSign, verify) | 45 | |
55 | import Data.Ord | ||
56 | import Data.Text.Encoding (encodeUtf8) | ||
57 | import Data.Time.Clock (UTCTime) | 46 | import Data.Time.Clock (UTCTime) |
58 | import Data.Time.Clock.POSIX (utcTimeToPOSIXSeconds) | 47 | import Data.Time.Clock.POSIX (utcTimeToPOSIXSeconds) |
59 | import System.Directory (doesFileExist) | 48 | import System.Directory (doesFileExist) |
60 | 49 | ||
61 | import System.IO.Error (isDoesNotExistError) | 50 | import System.IO.Error (isDoesNotExistError) |
62 | import Text.Show.Pretty as PP (ppShow) | ||
63 | #if !defined(VERSION_cryptonite) | 51 | #if !defined(VERSION_cryptonite) |
64 | import qualified Crypto.Hash.SHA1 as SHA1 | 52 | import qualified Crypto.Hash.SHA1 as SHA1 |
65 | import qualified Crypto.Types.PubKey.ECC as ECC | 53 | import qualified Crypto.Types.PubKey.ECC as ECC |
66 | #else | 54 | #else |
67 | import qualified Crypto.Hash as Vincent | ||
68 | import qualified Crypto.PubKey.ECC.Types as ECC | 55 | import qualified Crypto.PubKey.ECC.Types as ECC |
69 | import Data.ByteArray (convert) | ||
70 | #endif | 56 | #endif |
71 | import qualified Codec.Compression.GZip as GZip | 57 | import qualified Codec.Compression.GZip as GZip |
72 | import qualified Crypto.PubKey.RSA as RSA | 58 | import qualified Crypto.PubKey.RSA as RSA |
73 | import qualified Data.Text as T (break, drop, dropAround, | ||
74 | length, pack, reverse, strip, | ||
75 | unpack) | ||
76 | import qualified Data.X509 as X509 | 59 | import qualified Data.X509 as X509 |
77 | import System.Posix.Files (getFdStatus, getFileStatus, | 60 | import System.Posix.Files (getFdStatus, getFileStatus, |
78 | modificationTime) | 61 | modificationTime) |
@@ -91,10 +74,9 @@ import Foreign.Marshal.Array (withArray) | |||
91 | import Foreign.Ptr | 74 | import Foreign.Ptr |
92 | import Foreign.Storable | 75 | import Foreign.Storable |
93 | #endif | 76 | #endif |
94 | import Data.IORef | ||
95 | import Data.Traversable (sequenceA) | 77 | import Data.Traversable (sequenceA) |
96 | import qualified Data.Traversable as Traversable | 78 | import qualified Data.Traversable as Traversable |
97 | import System.IO (stderr,openFile,IOMode(ReadMode)) | 79 | import System.IO (openFile, IOMode(ReadMode)) |
98 | 80 | ||
99 | import System.Posix.IO (fdToHandle) | 81 | import System.Posix.IO (fdToHandle) |
100 | #if ! MIN_VERSION_base(4,6,0) | 82 | #if ! MIN_VERSION_base(4,6,0) |