Script 'mail_helper' called by obssrc Hello community, here is the log from the commit of package ghc-warp-tls for openSUSE:Factory checked in at 2021-06-01 10:39:12 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/ghc-warp-tls (Old) and /work/SRC/openSUSE:Factory/.ghc-warp-tls.new.1898 (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "ghc-warp-tls" Tue Jun 1 10:39:12 2021 rev:5 rq:896222 version:3.3.1 Changes: -------- --- /work/SRC/openSUSE:Factory/ghc-warp-tls/ghc-warp-tls.changes 2020-12-22 11:49:00.417985809 +0100 +++ /work/SRC/openSUSE:Factory/.ghc-warp-tls.new.1898/ghc-warp-tls.changes 2021-06-01 10:40:49.665156888 +0200 @@ -1,0 +2,9 @@ +Thu May 27 17:16:28 UTC 2021 - [email protected] + +- Update warp-tls to version 3.3.1. + ## 3.3.1 + + * Move exception handling over to `unliftio` for better async exception support [#845](https://github.com/yesodweb/wai/issues/845) + * Cleanly close connection when client closes connection prematurely [#844](https://github.com/yesodweb/wai/issues/844) + +------------------------------------------------------------------- Old: ---- warp-tls-3.3.0.tar.gz New: ---- warp-tls-3.3.1.tar.gz ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ ghc-warp-tls.spec ++++++ --- /var/tmp/diff_new_pack.tLJm4G/_old 2021-06-01 10:40:50.105157637 +0200 +++ /var/tmp/diff_new_pack.tLJm4G/_new 2021-06-01 10:40:50.109157643 +0200 @@ -1,7 +1,7 @@ # # spec file for package ghc-warp-tls # -# Copyright (c) 2020 SUSE LLC +# Copyright (c) 2021 SUSE LLC # # All modifications and additions to the file contributed by third parties # remain the property of their copyright owners, unless otherwise agreed @@ -18,7 +18,7 @@ %global pkg_name warp-tls Name: ghc-%{pkg_name} -Version: 3.3.0 +Version: 3.3.1 Release: 0 Summary: HTTP over TLS support for Warp via the TLS package License: MIT @@ -33,6 +33,7 @@ BuildRequires: ghc-streaming-commons-devel BuildRequires: ghc-tls-devel BuildRequires: ghc-tls-session-manager-devel +BuildRequires: ghc-unliftio-devel BuildRequires: ghc-wai-devel BuildRequires: ghc-warp-devel ExcludeArch: %{ix86} ++++++ warp-tls-3.3.0.tar.gz -> warp-tls-3.3.1.tar.gz ++++++ diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/warp-tls-3.3.0/ChangeLog.md new/warp-tls-3.3.1/ChangeLog.md --- old/warp-tls-3.3.0/ChangeLog.md 2020-06-25 03:58:59.000000000 +0200 +++ new/warp-tls-3.3.1/ChangeLog.md 2021-05-27 02:13:54.000000000 +0200 @@ -1,3 +1,8 @@ +## 3.3.1 + +* Move exception handling over to `unliftio` for better async exception support [#845](https://github.com/yesodweb/wai/issues/845) +* Cleanly close connection when client closes connection prematurely [#844](https://github.com/yesodweb/wai/issues/844) + ## 3.3.0 * Breaking changes: certFile and keyFile are not exported anymore. diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/warp-tls-3.3.0/Network/Wai/Handler/WarpTLS.hs new/warp-tls-3.3.1/Network/Wai/Handler/WarpTLS.hs --- old/warp-tls-3.3.0/Network/Wai/Handler/WarpTLS.hs 2020-06-25 03:58:59.000000000 +0200 +++ new/warp-tls-3.3.1/Network/Wai/Handler/WarpTLS.hs 2021-05-27 02:13:54.000000000 +0200 @@ -52,8 +52,8 @@ ) where import Control.Applicative ((<|>)) -import Control.Exception (Exception, throwIO, bracket, finally, handle, fromException, try, IOException, onException, SomeException(..), handleJust) -import qualified Control.Exception as E +import UnliftIO.Exception (Exception, throwIO, bracket, finally, handle, fromException, try, IOException, onException, SomeException(..), handleJust) +import qualified UnliftIO.Exception as E import Control.Monad (void, guard) import qualified Data.ByteString as S import qualified Data.ByteString.Lazy as L @@ -393,14 +393,12 @@ return (mkConn tlsset set s params, sa) mkConn :: TLS.TLSParams params => TLSSettings -> Settings -> Socket -> params -> IO (Connection, Transport) -mkConn tlsset set s params = switch `onException` close s +mkConn tlsset set s params = (safeRecv s 4096 >>= switch) `onException` close s where - switch = do - firstBS <- safeRecv s 4096 - if not (S.null firstBS) && S.head firstBS == 0x16 then - httpOverTls tlsset set s firstBS params - else - plainHTTP tlsset set s firstBS + switch firstBS + | S.null firstBS = close s >> throwIO ClientClosedConnectionPrematurely + | S.head firstBS == 0x16 = httpOverTls tlsset set s firstBS params + | otherwise = plainHTTP tlsset set s firstBS ---------------------------------------------------------------- @@ -590,6 +588,8 @@ ---------------------------------------------------------------- -data WarpTLSException = InsecureConnectionDenied +data WarpTLSException + = InsecureConnectionDenied + | ClientClosedConnectionPrematurely deriving (Show, Typeable) instance Exception WarpTLSException diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/warp-tls-3.3.0/warp-tls.cabal new/warp-tls-3.3.1/warp-tls.cabal --- old/warp-tls-3.3.0/warp-tls.cabal 2020-06-25 03:58:59.000000000 +0200 +++ new/warp-tls-3.3.1/warp-tls.cabal 2021-05-27 02:13:54.000000000 +0200 @@ -1,5 +1,5 @@ Name: warp-tls -Version: 3.3.0 +Version: 3.3.1 Synopsis: HTTP over TLS support for Warp via the TLS package License: MIT License-file: LICENSE @@ -18,7 +18,7 @@ extra-source-files: ChangeLog.md README.md Library - Build-Depends: base >= 4.10 && < 5 + Build-Depends: base >= 4.12 && < 5 , bytestring >= 0.9 , wai >= 3.2 && < 3.3 , warp >= 3.3.6 && < 3.4 @@ -28,6 +28,7 @@ , network >= 2.2.1 , streaming-commons , tls-session-manager >= 0.0.4 + , unliftio Exposed-modules: Network.Wai.Handler.WarpTLS ghc-options: -Wall if os(windows)
