]> woffs.de Git - fd/haskell-amqp-utils.git/commitdiff
tls version compat
authorFrank Doepper <[email protected]>
Mon, 9 Jul 2018 20:52:19 +0000 (22:52 +0200)
committerFrank Doepper <[email protected]>
Mon, 9 Jul 2018 20:52:19 +0000 (22:52 +0200)
Network/AMQP/Utils/Connection.hs
amqp-utils.cabal

index 2cde3774fcd8c6c8043adf5926beafd357d21236..30c5c25d7a524741e0321f6693dcd0bb2c548aaa 100644 (file)
@@ -1,4 +1,4 @@
-{-# LANGUAGE OverloadedStrings #-}
+{-# LANGUAGE OverloadedStrings, CPP #-}
 
 module Network.AMQP.Utils.Connection where
 
@@ -29,7 +29,15 @@ connect args = do
                   { sharedValidationCache = def
                   , sharedCAStore = globalCertificateStore
                   }
-            , clientSupported = def {supportedCiphers = ciphersuite_default}
+            , clientSupported =
+                def
+                  { supportedCiphers =
+#if MIN_VERSION_tls(1,3,9)
+                      ciphersuite_default
+#else
+                      ciphersuite_all
+#endif
+                  }
             , clientHooks =
                 def {onCertificateRequest = myCert (cert args) (key args)}
             }
index a2362fed1b5b3f9290e6a348e77192e7e7890f4b..ddf32608aeaf1a7b502ab9026105226c7aff55b7 100644 (file)
@@ -42,11 +42,11 @@ executable konsum
                        process,
                        bytestring,
                        x509-system,
-                       tls >= 1.3.9,
+                       tls,
                        amqp >=0.17
   
   ghc-options:         -threaded -Wall
-  
+
   default-language:    Haskell98
 
   other-modules:       Network.AMQP.Utils.Options,
@@ -65,7 +65,7 @@ executable agitprop
                        process,
                        bytestring,
                        x509-system,
-                       tls >= 1.3.9,
+                       tls,
                        amqp >=0.17,
                        unix >= 2.7,
                        hinotify >= 0.3.8 && < 0.3.10,
don't click here