packages feed

mysql-haskell 1.1.7 → 1.1.8

raw patch · 4 files changed

+56/−13 lines, 4 filesdep +ramdep ~basedep ~cryptondep ~tlsPVP ok

version bump matches the API change (PVP)

Dependencies added: ram

Dependency ranges changed: base, crypton, tls

API changes (from Hackage documentation)

Files

ChangeLog.md view
@@ -1,5 +1,8 @@ # Revision history for mysql-haskell +## 1.1.8 ++ bump constraints+ ## 1.1.7 -- 2025.08.23  + bump constraints + upgrade cabal file
mysql-haskell.cabal view
@@ -1,6 +1,6 @@ cabal-version:      3.4 name:               mysql-haskell-version:            1.1.7+version:            1.1.8 synopsis:           pure haskell MySQL driver description:        pure haskell MySQL driver. license:            BSD-3-Clause@@ -40,7 +40,7 @@  source-repository head   type:     git-  location: git://github.com/winterland1989/mysql-haskell.git+  location: https://github.com/winterland1989/mysql-haskell   common common-options@@ -52,7 +52,7 @@     -fenable-th-splice-warnings     -fno-omit-yields   build-depends:-      base >=4.9.1.0 && <4.21.0+      base >=4.9.1.0 && <4.22.0   default-language: GHC2021  library@@ -90,7 +90,7 @@     blaze-textual >=0.2 && <0.3,     bytestring >=0.10.2.0 && <0.12 || ^>=0.12.0,     bytestring-lexing >=0.5 && <0.6,-    crypton >=0.31 && <0.40 || ^>=1.0.0,+    crypton >=0.31 && <0.40 || ^>=1.0.0 || ^>=1.1.0,     crypton-x509 >=1.5 && <2.0,     crypton-x509-store >=1.5 && <2.0,     crypton-x509-system >=1.5 && <2.0,@@ -99,12 +99,13 @@     io-streams >=1.2 && <2.0,     memory >=0.14.4 && <0.19,     monad-loops >=0.4 && <0.5,+    ram >=0.20 && <0.23,     network >=2.3 && <4.0,     pem >=0.2.4 && <0.3,     scientific >=0.3 && <0.4,     text >=1.1 && <2.1 || ^>=2.1,     time >=1.5.0 && <1.12 || ^>=1.12.2 || ^>=1.14,-    tls >=1.7.0 && <1.8 || ^>=1.8.0 || ^>=1.9.0 || ^>=2.0.0 || ^>=2.1.0,+    tls >=1.7.0 && <1.8 || ^>=1.8.0 || ^>=1.9.0 || ^>=2.0.0 || ^>=2.1.0 || ^>=2.2.0 || ^>=2.3.0,     vector >=0.8 && <0.13 || ^>=0.13.0,     word-compat >=0.0 && <0.1 
src/Data/TLSSetting.hs view
@@ -1,3 +1,5 @@+{-# LANGUAGE CPP #-}+ -- | Helpers for setting up a tls connection with @tls@ package, -- for further customization, please refer to @tls@ package. --@@ -16,7 +18,6 @@     ) where  import qualified Data.ByteString            as B-import           Data.Default.Class         (def) import qualified Data.PEM                   as X509 import qualified Data.X509                  as X509 import qualified Data.X509.CertificateStore as X509@@ -25,6 +26,10 @@ import           Paths_mysql_haskell          (getDataFileName) import qualified System.X509                as X509 +#if !MIN_VERSION_tls(2,0,0)+import           Data.Default.Class         (def)+#endif+ -- | The whole point of TLS is that: a peer should have already trusted -- some certificates, which can be used for validating other peer's certificates. -- if the certificates sent by other side form a chain. and one of them is issued@@ -67,10 +72,10 @@ makeClientParams tca = do     caStore <- makeCAStore tca     return (TLS.defaultParamsClient "" B.empty)-        {   TLS.clientSupported = def { TLS.supportedCiphers = TLS.ciphersuite_default }-        ,   TLS.clientShared    = def+        {   TLS.clientSupported = defaultSupported' { TLS.supportedCiphers = TLS.ciphersuite_default }+        ,   TLS.clientShared    = defaultShared'             {   TLS.sharedCAStore         = caStore-            ,   TLS.sharedValidationCache = def+            ,   TLS.sharedValidationCache = defaultValidationCache'             }         } @@ -112,13 +117,13 @@     c <- TLS.credentialLoadX509Chain pub certs priv     case c of         Right c'@(X509.CertificateChain c'', _) ->-            return def+            return defaultServerParams'                 {   TLS.serverCACertificates =  c''-                ,   TLS.serverShared = def+                ,   TLS.serverShared = defaultShared'                     {                         TLS.sharedCredentials = TLS.Credentials [c']                     }-                ,   TLS.serverSupported = def { TLS.supportedCiphers = TLS.ciphersuite_strong }+                ,   TLS.serverSupported = defaultSupported' { TLS.supportedCiphers = TLS.ciphersuite_strong }                 }         Left err -> error err @@ -138,3 +143,30 @@             {   TLS.sharedCAStore = caStore             }         }++-- Compatibility shims for tls < 2.0 vs >= 2.0+#if MIN_VERSION_tls(2,0,0)+defaultServerParams' :: TLS.ServerParams+defaultServerParams' = TLS.defaultParamsServer++defaultShared' :: TLS.Shared+defaultShared' = TLS.defaultShared++defaultSupported' :: TLS.Supported+defaultSupported' = TLS.defaultSupported++defaultValidationCache' :: TLS.ValidationCache+defaultValidationCache' = TLS.defaultValidationCache+#else+defaultServerParams' :: TLS.ServerParams+defaultServerParams' = def++defaultShared' :: TLS.Shared+defaultShared' = def++defaultSupported' :: TLS.Supported+defaultSupported' = def++defaultValidationCache' :: TLS.ValidationCache+defaultValidationCache' = def+#endif
src/Database/MySQL/Connection.hs view
@@ -1,3 +1,6 @@+{-# LANGUAGE CPP #-}+{-# LANGUAGE PackageImports #-}+ {-| Module      : Database.MySQL.Connection Description : Connection managment@@ -20,7 +23,11 @@ import qualified Data.Binary                     as Binary import qualified Data.Binary.Put                 as Binary import           Data.Bits-import qualified Data.ByteArray                  as BA+#if MIN_VERSION_crypton(1,1,0)+import qualified "ram" Data.ByteArray             as BA+#else+import qualified "memory" Data.ByteArray          as BA+#endif import           Data.ByteString                 (ByteString) import qualified Data.ByteString                 as B import qualified Data.ByteString.Lazy            as L