crypton-x509-store 1.6.11 → 1.6.12
raw patch · 2 files changed
+15/−2 lines, 2 filesdep +unixPVP ok
version bump matches the API change (PVP)
Dependencies added: unix
API changes (from Hackage documentation)
Files
- Data/X509/File.hs +11/−0
- crypton-x509-store.cabal +4/−2
Data/X509/File.hs view
@@ -1,3 +1,5 @@+{-# LANGUAGE CPP #-}+ module Data.X509.File ( readSignedObject, readKeyFile,@@ -14,6 +16,9 @@ import Data.PEM (PEM, pemContent, pemName, pemParseLBS) import qualified Data.X509 as X509 import Data.X509.Memory (pemToKey)+#if !defined(mingw32_HOST_OS)+import System.Posix.IO+#endif newtype PEMError = PEMError {displayPEMError :: String} deriving (Show)@@ -23,7 +28,13 @@ readPEMs :: FilePath -> IO [PEM] readPEMs filepath = do+#if defined(mingw32_HOST_OS) content <- L.readFile filepath+#else+ fd <- openFd filepath ReadOnly defaultFileFlags{cloexec = True}+ h <- fdToHandle fd+ content <- L.hGetContents h+#endif either (throw . PEMError) pure $ pemParseLBS content -- | return all the signed objects in a file.
crypton-x509-store.cabal view
@@ -1,5 +1,5 @@ Name: crypton-x509-store-version: 1.6.11+version: 1.6.12 Description: X.509 collection accessing and storing methods for certificate, crl, exception list License: BSD3 License-file: LICENSE@@ -26,6 +26,8 @@ , asn1-encoding >= 0.9 && < 0.10 , crypton , crypton-x509 >= 1.7.2+ if !os(windows)+ Build-Depends: unix Exposed-modules: Data.X509.CertificateStore Data.X509.File Data.X509.Memory@@ -46,5 +48,5 @@ source-repository head type: git- location: git://github.com/vincenthz/hs-certificate+ location: https://github.com/kazu-yamamoto/crypton-certificate subdir: x509-store