[openssl-commits] [openssl] master update

Matt Caswell matt at openssl.org
Mon May 16 16:21:28 UTC 2016


The branch master has been updated
       via  6ae545248109710365189047ba945700ab8afff3 (commit)
      from  5c4328f04f63bc288d4e069e1453ab18b0309f16 (commit)


- Log -----------------------------------------------------------------
commit 6ae545248109710365189047ba945700ab8afff3
Author: Matt Caswell <matt at openssl.org>
Date:   Mon May 16 16:54:28 2016 +0100

    Workaround an IO::Socket::IP bug
    
    Workaround an apparent IO:Socket::IP bug where a seemingly valid
    server socket is being returned even though a valid connection does not
    exist. This causes the tests to intermittently hang. We additionally check
    that the peerport looks ok to verify that the returned socket looks usable.
    
    Reviewed-by: Richard Levitte <levitte at openssl.org>

-----------------------------------------------------------------------

Summary of changes:
 util/TLSProxy/Proxy.pm | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/util/TLSProxy/Proxy.pm b/util/TLSProxy/Proxy.pm
index 950fd90..3b03ea9 100644
--- a/util/TLSProxy/Proxy.pm
+++ b/util/TLSProxy/Proxy.pm
@@ -236,7 +236,9 @@ sub clientstart
         };
 
         $retry--;
-        if ($@ || !defined($server_sock)) {
+        #Some buggy IP factories can return a defined server_sock that hasn't
+        #actually connected, so we check peerport too
+        if ($@ || !defined($server_sock) || !defined($server_sock->peerport)) {
             $server_sock->close() if defined($server_sock);
             undef $server_sock;
             if ($retry) {


More information about the openssl-commits mailing list