Hello community,

here is the log from the commit of package socat for openSUSE:Factory checked 
in at 2020-04-25 20:07:05
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/socat (Old)
 and      /work/SRC/openSUSE:Factory/.socat.new.2738 (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Package is "socat"

Sat Apr 25 20:07:05 2020 rev:41 rq:795509 version:1.7.3.4

Changes:
--------
--- /work/SRC/openSUSE:Factory/socat/socat.changes      2020-02-07 
15:52:38.087452500 +0100
+++ /work/SRC/openSUSE:Factory/.socat.new.2738/socat.changes    2020-04-25 
20:07:09.203402884 +0200
@@ -1,0 +2,9 @@
+Fri Apr 17 06:58:23 UTC 2020 - Martin Pluskal <mplus...@suse.com>
+
+- Update to version 1.7.3.4:
+  * bugfix release, see the CHANGES file for all changes
+- Refresh patches:
+  * socat-common-fixes.patch
+  * socat-ignore-tests-failure-boo1078346.patch
+
+-------------------------------------------------------------------

Old:
----
  socat-1.7.3.3.tar.bz2

New:
----
  socat-1.7.3.4.tar.bz2

++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++

Other differences:
------------------
++++++ socat.spec ++++++
--- /var/tmp/diff_new_pack.WZ0Ugf/_old  2020-04-25 20:07:10.227404995 +0200
+++ /var/tmp/diff_new_pack.WZ0Ugf/_new  2020-04-25 20:07:10.231405003 +0200
@@ -1,7 +1,7 @@
 #
 # spec file for package socat
 #
-# Copyright (c) 2020 SUSE LINUX GmbH, Nuernberg, Germany.
+# Copyright (c) 2020 SUSE LLC
 # Copyright (c) 2010 Pascal Bleser <pascal.ble...@opensuse.org>
 #
 # All modifications and additions to the file contributed by third parties
@@ -18,7 +18,7 @@
 
 
 Name:           socat
-Version:        1.7.3.3
+Version:        1.7.3.4
 Release:        0
 Summary:        Multipurpose relay for bidirectional data transfer
 License:        SUSE-GPL-2.0-with-openssl-exception AND MIT
@@ -65,7 +65,7 @@
 export BUILD_DATE="$(LANG=C date --utc -d "${CL_DATE}" +"%{b} %{e} %{Y} %{T}")"
 export CFLAGS="%{optflags} -fno-strict-aliasing -DHAVE_SSLv23_client_method 
-DHAVE_SSLv23_server_method -fno-common"
 %configure
-make %{?_smp_mflags} all
+%make_build all
 mkdir examples
 cp -a daemon.sh ftp.sh mail.sh proxyecho.sh readline.sh examples
 

++++++ socat-1.7.3.3.tar.bz2 -> socat-1.7.3.4.tar.bz2 ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/CHANGES new/socat-1.7.3.4/CHANGES
--- old/socat-1.7.3.3/CHANGES   2019-04-05 22:10:24.000000000 +0200
+++ new/socat-1.7.3.4/CHANGES   2020-01-05 16:07:44.000000000 +0100
@@ -1,4 +1,40 @@
 
+####################### V 1.7.3.4:
+
+Corrections:
+       Header of xiotermios_speed() declared parameter unsigned int instead of
+       speed_t, thus compiling failed on MacOS
+       Thanks to Joe Strout and others for reporting this bug.
+       Thanks to Andrew Childs and others for sending a patch.
+
+       Under certain circumstances, termios options of the first address were
+       applied to the second address, resulting in error
+       "Inappropriate ioctl for device" 
+       This affected version 1.7.3.3 only.
+       Test: TERMIOS_PH_ALL
+       Thanks to Ivan J. for reporting this issue.
+
+       Socat failed to compile when no poll() system call was found by
+       configure.
+       Thanks to Jason White for sending a patch.
+
+       Due to use of SSL_CTX_clear_mode() Socat failed to compile on old
+       systems with, e.g., OpenSSL-0.9.8. Thanks to Simon Matter and Moritz B.
+       for reporting this problem and sending initial patches.
+
+       getaddrinfo() in IP4-SENDTO and IP6-SENDTO addresses failed with
+       "ai_socktype not supported" when protocol 6 was addressed.
+       The fix removes the possibility to use service names with SCTP.
+       Test: IP_SENDTO_6
+       Thanks to S�ren for sending an initial patch.
+
+       Under certain circumstances, Socat printed the "socket ... is at EOF"
+       multiple times.
+       Test: MULTIPLE_EOF
+
+       Newer parts of test.sh used substitutions ${x,,*} or ${x^^*} that are
+       not implemented in older bash versions.
+
 ####################### V 1.7.3.3:
 
 Corrections:
@@ -55,6 +91,7 @@
        name to decide if it is an IPv4 address. This was not RFC conform. This
        fix removes the possibility for use of IPv4 addresses with IPv6, e.g.
        TCP6:127.0.0.1:80
+       Debian issue 695885
        Thanks to Nicolas Fournil for reporting this issue.
 
        Print a useful error message when single character options appear to be
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/Makefile.in 
new/socat-1.7.3.4/Makefile.in
--- old/socat-1.7.3.3/Makefile.in       2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/Makefile.in       2020-01-04 11:33:07.000000000 +0100
@@ -49,7 +49,6 @@
        xio-ip.c xio-ip4.c xio-ip6.c xio-ipapp.c xio-tcp.c \
        xio-sctp.c xio-rawip.c \
        xio-socks.c xio-proxy.c xio-udp.c \
-       xio-rawip.c \
        xio-progcall.c xio-exec.c xio-system.c xio-termios.c xio-readline.c \
        xio-pty.c xio-openssl.c xio-streams.c\
        xio-ascii.c xiolockfile.c xio-tcpwrap.c xio-ext2.c xio-tun.c
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/VERSION new/socat-1.7.3.4/VERSION
--- old/socat-1.7.3.3/VERSION   2019-04-05 22:09:29.000000000 +0200
+++ new/socat-1.7.3.4/VERSION   2020-01-05 16:07:04.000000000 +0100
@@ -1 +1 @@
-"1.7.3.3"
+"1.7.3.4"
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/config.h.in 
new/socat-1.7.3.4/config.h.in
--- old/socat-1.7.3.3/config.h.in       2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/config.h.in       2020-01-01 14:03:27.000000000 +0100
@@ -476,6 +476,9 @@
 /* Define if you have the OpenSSL ASN1_STRING_get0_data function */
 #undef HAVE_ASN1_STRING_get0_data
 
+/* Define if you have the OpenSSL SSL_CTX_clear_mode macro or function */
+#undef HAVE_SSL_CTX_clear_mode
+
 /* Define if you have the flock function */
 #undef HAVE_FLOCK
 
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/configure new/socat-1.7.3.4/configure
--- old/socat-1.7.3.3/configure 2019-04-05 22:10:58.000000000 +0200
+++ new/socat-1.7.3.4/configure 2020-01-05 20:13:23.000000000 +0100
@@ -9127,6 +9127,12 @@
 
 fi
 
+ac_fn_c_check_func "$LINENO" "SSL_CTX_clear_mode" 
"ac_cv_func_SSL_CTX_clear_mode"
+if test "x$ac_cv_func_SSL_CTX_clear_mode" = xyes; then :
+  $as_echo "#define HAVE_SSL_CTX_clear_mode 1" >>confdefs.h
+
+fi
+
 
 { $as_echo "$as_me:${as_lineno-$LINENO}: checking for type EC_KEY" >&5
 $as_echo_n "checking for type EC_KEY... " >&6; }
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/configure.ac 
new/socat-1.7.3.4/configure.ac
--- old/socat-1.7.3.3/configure.ac      2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/configure.ac      2020-01-01 14:03:27.000000000 +0100
@@ -1463,6 +1463,7 @@
 AC_CHECK_FUNC(DH_set0_pqg, AC_DEFINE(HAVE_DH_set0_pqg), AC_CHECK_LIB(crypt, 
DH_set0_pqg, [LIBS=-lcrypt $LIBS]))
 AC_CHECK_FUNC(ASN1_STRING_get0_data, AC_DEFINE(HAVE_ASN1_STRING_get0_data), 
AC_CHECK_LIB(crypt, ASN1_STRING_get0_data, [LIBS=-lcrypt $LIBS]))
 AC_CHECK_FUNC(RAND_status, AC_DEFINE(HAVE_RAND_status))
+AC_CHECK_FUNC(SSL_CTX_clear_mode, AC_DEFINE(HAVE_SSL_CTX_clear_mode))
 
 AC_MSG_CHECKING(for type EC_KEY)
 AC_CACHE_VAL(sc_cv_type_EC_TYPE,
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/filan.c new/socat-1.7.3.4/filan.c
--- old/socat-1.7.3.3/filan.c   2017-01-06 21:58:40.000000000 +0100
+++ new/socat-1.7.3.4/filan.c   2020-01-01 14:02:06.000000000 +0100
@@ -144,6 +144,7 @@
            |POLLMSG
 #endif
            ;
+#if HAVE_POLL
         if (Poll(&ufds, 1, 0) < 0) {
            Warn4("poll({%d, %hd, %hd}, 1, 0): %s",
                   ufds.fd, ufds.events, ufds.revents, strerror(errno));
@@ -200,6 +201,7 @@
            }
 #endif /* _WITH_SOCKET && defined(MSG_DONTWAIT) */
         }       
+#endif /* HAVE_POLL */
       }
    }
    fputc('\n', outfile);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/socat.c new/socat-1.7.3.4/socat.c
--- old/socat-1.7.3.3/socat.c   2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/socat.c   2020-01-04 10:26:26.000000000 +0100
@@ -1076,10 +1076,10 @@
                   XIO_RDSTREAM(sock1)->fd);    /*! */
            mayrd1 = true;
            polling = 1;        /* do not hook this eof fd to poll for 
pollintv*/
-        } else {
+        } else if (XIO_RDSTREAM(sock1)->eof <= 2) {
            Notice1("socket 1 (fd %d) is at EOF", XIO_GETRDFD(sock1));
            xioshutdown(sock2, SHUT_WR);
-           XIO_RDSTREAM(sock1)->eof = 2;
+           XIO_RDSTREAM(sock1)->eof = 3;
            XIO_RDSTREAM(sock1)->ignoreeof = false;
         }
       } else if (polling && XIO_RDSTREAM(sock1)->ignoreeof) {
@@ -1099,10 +1099,10 @@
                   XIO_RDSTREAM(sock2)->fd);
            mayrd2 = true;
            polling = 1;        /* do not hook this eof fd to poll for 
pollintv*/
-        } else {
+        } else if (XIO_RDSTREAM(sock2)->eof <= 2) {
            Notice1("socket 2 (fd %d) is at EOF", XIO_GETRDFD(sock2));
            xioshutdown(sock1, SHUT_WR);
-           XIO_RDSTREAM(sock2)->eof = 2;
+           XIO_RDSTREAM(sock2)->eof = 3;
            XIO_RDSTREAM(sock2)->ignoreeof = false;
         }
       } else if (polling && XIO_RDSTREAM(sock2)->ignoreeof) {
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/socat.spec new/socat-1.7.3.4/socat.spec
--- old/socat-1.7.3.3/socat.spec        2019-04-05 22:09:44.000000000 +0200
+++ new/socat-1.7.3.4/socat.spec        2020-01-05 16:07:25.000000000 +0100
@@ -1,6 +1,6 @@
 
 %define majorver 1.7
-%define minorver 3.3
+%define minorver 3.4
 
 Summary: socat - multipurpose relay
 Name: socat
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/sysutils.c new/socat-1.7.3.4/sysutils.c
--- old/socat-1.7.3.3/sysutils.c        2017-01-08 11:38:53.000000000 +0100
+++ new/socat-1.7.3.4/sysutils.c        2020-01-01 14:02:06.000000000 +0100
@@ -538,8 +538,8 @@
       }
       return result;
    }
-#if HAVE_POLL
    {
+#if HAVE_POLL
       int ms = 0;
       if (timeout == NULL) {
         ms = -1;
@@ -549,7 +549,6 @@
       /*! timeout */
       return Poll(fds, nfds, ms);
 #else /* HAVE_POLL */
-   } else {
       Error("poll() not available");
       return -1;
 #endif /* !HAVE_POLL */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/test.sh new/socat-1.7.3.4/test.sh
--- old/socat-1.7.3.3/test.sh   2019-04-05 21:50:30.000000000 +0200
+++ new/socat-1.7.3.4/test.sh   2020-01-05 10:54:11.000000000 +0100
@@ -67,6 +67,7 @@
 #debug="1"
 debug=
 TESTS="$@"; export TESTS
+
 # for some tests we need a network interface
 if type ip >/dev/null 2>&1; then
     INTERFACE=$(ip r get 8.8.8.8 |grep ' dev ' |head -n 1 |sed 
"s/.*dev[[:space:]][[:space:]]*\([^[:space:]][^[:space:]]*\).*/\1/")
@@ -148,6 +149,20 @@
 CAT=cat
 OD_C="od -c"
 
+toupper () {
+    case ${BASH_VERSION:0:1} in
+       [1-3]) echo "$@" |tr a-z A-Z ;;
+       [4-9]) echo "${@^^*}" ;;
+    esac
+}
+
+tolower () {
+    case ${BASH_VERSION:0:1} in
+       [1-3]) echo "$@" |tr A-Z a-z ;;
+       [4-9]) echo "${@,,*}" ;;
+    esac
+}
+
 # precision sleep; takes seconds with fractional part
 psleep () {
     local T="$1"
@@ -168,7 +183,7 @@
 fi
 #USLEEP=usleep
 
-if type ping6; then
+if type ping6 >/dev/null 2>&1; then
     PING6=ping6
 else
     PING6="ping -6"
@@ -215,7 +230,7 @@
     SUBSTUSER="$(grep -v '^[^:]*:^[^:]*:0:' /etc/passwd |tail -n 1 |cut -d: 
-f1)"
 fi
 
-if type ip >/dev/null; then
+if type ip >/dev/null 2>&1; then
     if ip -V |grep -q "^ip utility, iproute2-ss"; then
        IP=$(which ip)
     else
@@ -223,7 +238,7 @@
     fi
 fi
 
-if type ss >/dev/null; then
+if type ss >/dev/null 2>&1; then
     if ss -V |grep -q "^ss utility, iproute2-ss"; then
        SS=$(which ss)
     else
@@ -11393,7 +11408,7 @@
 
 while read KEYW FEAT ADDR IPPORT; do
 if [ -z "$KEYW" ]|| [[ "$KEYW" == \#* ]]; then continue; fi
-RUNS=${KEYW,,*}
+RUNS=$(tolower $KEYW)
 PROTO=$KEYW
 proto="$(echo "$PROTO" |tr A-Z a-z)"
 # test the max-children option on really connection oriented sockets
@@ -11410,7 +11425,7 @@
     $PRINTF "test $F_n $TEST... ${YELLOW}$FEAT not available${NORMAL}\n" $N
     numCANT=$((numCANT+1))
 elif ! runs$RUNS >/dev/null; then
-    $PRINTF "test $F_n $TEST... ${YELLOW}${RUNS^^*} not available${NORMAL}\n" 
$N
+    $PRINTF "test $F_n $TEST... ${YELLOW}$(toupper $RUNS) not 
available${NORMAL}\n" $N
     numCANT=$((numCANT+1))
 else
 case "X$IPPORT" in
@@ -11475,7 +11490,7 @@
 
 while read KEYW FEAT ADDR IPPORT SHUT; do
 if [ -z "$KEYW" ]|| [[ "$KEYW" == \#* ]]; then continue; fi
-RUNS=${KEYW,,*}
+RUNS=$(tolower $KEYW)
 PROTO=$KEYW
 proto="$(echo "$PROTO" |tr A-Z a-z)"
 # test the max-children option on pseudo connected sockets
@@ -11493,7 +11508,7 @@
     $PRINTF "test $F_n $TEST... ${YELLOW}$FEAT not available${NORMAL}\n" $N
     numCANT=$((numCANT+1))
 elif ! runs$RUNS >/dev/null; then
-    $PRINTF "test $F_n $TEST... ${YELLOW}${RUNS^^*} not available${NORMAL}\n" 
$N
+    $PRINTF "test $F_n $TEST... ${YELLOW}$(toupper $RUNS) not 
available${NORMAL}\n" $N
     numCANT=$((numCANT+1))
 else
 case "X$IPPORT" in
@@ -11877,7 +11892,7 @@
 while read ssldist MODE MODULE FIELD TESTADDRESS PEERADDRESS VALUE; do
 if [ -z "$ssldist" ] || [[ "$ssldist" == \#* ]]; then continue; fi
 #
-SSLDIST=${ssldist^^*}
+SSLDIST=$(toupper $ssldist)
 NAME="ENV_${SSLDIST}_${MODE}_${MODULE}_${FIELD}"
 case "$TESTS" in
 
*%$N%*|*%functions%*|*%ip4%*|*%ipapp%*|*%tcp%*|*%$ssldist%*|*%envvar%*|*%$NAME%*)
@@ -11974,9 +11989,9 @@
 if [ -z "$addr" ] || [[ "$addr" == \#* ]]; then continue; fi
 # some passive (listening...) filesystem based addresses did not implement the
 # umask option
-ADDR=${addr^^*}
+ADDR=$(toupper $addr)
 ADDR_=${ADDR/-/_}
-PROTO=${proto^^*}
+PROTO=$(toupper $proto)
 if [ "$diropt" = "." ]; then diropt=; fi
 if [ "$fileopt" = "." ]; then fileopt=; fi
 if [ "$addropts" = "." ]; then addropts=; fi
@@ -12047,9 +12062,9 @@
 while read addr fileopt addropts proto diropt; do
 if [ -z "$addr" ] || [[ "$addr" == \#* ]]; then continue; fi
 # test if passive (listening...) filesystem based addresses implement option 
perm
-ADDR=${addr^^*}
+ADDR=$(toupper $addr)
 ADDR_=${ADDR/-/_}
-PROTO=${proto^^*}
+PROTO=$(toupper $proto)
 if [ "$diropt" = "." ]; then diropt=; fi
 if [ "$fileopt" = "." ]; then fileopt=; fi
 if [ "$addropts" = "." ]; then addropts=; fi
@@ -12119,9 +12134,9 @@
 while read addr fileopt addropts proto diropt; do
 if [ -z "$addr" ] || [[ "$addr" == \#* ]]; then continue; fi
 # test if passive (listening...) filesystem based addresses implement option 
user
-ADDR=${addr^^*}
+ADDR=$(toupper $addr)
 ADDR_=${ADDR/-/_}
-PROTO=${proto^^*}
+PROTO=$(toupper $proto)
 if [ "$diropt" = "." ]; then diropt=; fi
 if [ "$fileopt" = "." ]; then fileopt=; fi
 if [ "$addropts" = "." ]; then addropts=; fi
@@ -12196,9 +12211,9 @@
 if [ -z "$addr" ] || [[ "$addr" == \#* ]]; then continue; fi
 # some passive (listening...) filesystem based addresses did not remove the 
file
 # system entry at the end
-ADDR=${addr^^*}
+ADDR=$(toupper $addr)
 ADDR_=${ADDR/-/_}
-PROTO=${proto^^*}
+PROTO=$(toupper $proto)
 if [ "$diropt" = "." ]; then diropt=; fi
 if [ "$fileopt" = "." ]; then fileopt=; fi
 if [ "$addropts" = "." ]; then addropts=; fi
@@ -12264,9 +12279,9 @@
 if [ -z "$addr" ] || [[ "$addr" == \#* ]]; then continue; fi
 # some passive (listening...) filesystem based addresses with fork did not 
remove
 # the file system entry at the end
-ADDR=${addr^^*}
+ADDR=$(toupper $addr)
 ADDR_=${ADDR/-/_}
-PROTO=${proto^^*}
+PROTO=$(toupper $proto)
 if [ "$diropt" = "." ]; then diropt=; fi
 if [ "$fileopt" = "." ]; then fileopt=; fi
 if [ "$addropts" = "." ]; then addropts=; fi
@@ -13005,7 +13020,7 @@
 
 NAME=SOCAT_OPT_HINT
 case "$TESTS" in
-*%$N%*|*%socat%*|*%$NAME%*)
+*%$N%*|*%functions%*|*%$NAME%*)
 TEST="$NAME: check if merging single character options is rejected"
 if ! eval $NUMCOND; then :; else
 te="$td/test$N.stderr"
@@ -13026,6 +13041,115 @@
 esac
 N=$((N+1))
 
+
+# test for a bug in Socat version 1.7.3.3 where
+# termios options of the first address were applied to the second address.
+NAME=TERMIOS_PH_ALL
+case "$TESTS" in
+*%$N%*|*%functions%*|*%bugs%*|*%termios%*|*%$NAME%*)
+TEST="$NAME: are termios options applied to the correct address"
+# add a termios option to the first address, a tty, and have a second address
+# with pipe. If no error occurs the termios option was not applied to the pipe,
+# thus the test succeeded.
+if ! eval $NUMCOND; then :; else
+tf="$td/test$N.stdout"
+te="$td/test$N.stderr"
+tdiff="$td/test$N.diff"
+da="test$N $(date) $RANDOM"
+CMD0="$TRACE $SOCAT $opts -T 1 STDIO,echo=0 EXEC:cat"
+echo "$CMD0" >$td/test$N.sh
+chmod a+x $td/test$N.sh
+printf "test $F_n $TEST... " $N
+$SOCAT /dev/null EXEC:$td/test$N.sh,pty 2>"${te}0"
+rc0=$?
+if [ $rc0 -eq 0 ]; then
+    $PRINTF "$OK\n"
+    numOK=$((numOK+1))
+else
+    $PRINTF "$FAILED\n"
+    echo "$CMD0"
+    cat "${te}0"
+    numFAIL=$((numFAIL+1))
+    listFAIL="$listFAIL $N"
+fi
+fi # NUMCOND
+ ;;
+esac
+PORT=$((PORT+1))
+N=$((N+1))
+
+
+# Due to a fallback logic before calling getaddrinfo(), intended to allow use
+# of service (port) names with SCTP, raw socket addresses where resolved with
+# socket type stream, which fails for protocol 6 (TCP)
+# Fixed after 1.7.3.3
+NAME=IP_SENDTO_6
+case "$TESTS" in
+*%$N%*|*%functions%*|*%bugs%*|*%socket%*|*%rawip%*|*%rawip4%*|*%$NAME%*)
+TEST="$NAME: IP-SENDTO::6 passes getaddrinfo()"
+# invoke socat with address IP-SENDTO:*:6; when this does not fail with
+# "ai_socktype not supported", the test succeeded
+if ! eval $NUMCOND; then :; else
+tf="$td/test$N.stdout"
+te="$td/test$N.stderr"
+tdiff="$td/test$N.diff"
+CMD0="$TRACE $SOCAT $opts -u /dev/null IP-SENDTO:127.0.0.1:6"
+printf "test $F_n $TEST... " $N
+$CMD0 >/dev/null 2>"${te}0"
+if ! grep -q "ai_socktype not supported" ${te}0; then
+    $PRINTF "$OK\n"
+    numOK=$((numOK+1))
+else
+    $PRINTF "$FAILED\n"
+    echo "$CMD0"
+    cat "${te}0"
+    numFAIL=$((numFAIL+1))
+    listFAIL="$listFAIL $N"
+fi
+fi # NUMCOND
+ ;;
+esac
+N=$((N+1))
+
+
+# test if the multiple EOF messages are fixed
+NAME=MULTIPLE_EOF
+case "$TESTS" in
+*%$N%*|*%functions%*|*%bugs%*|*%unix%*|*%socket%*|*%$NAME%*)
+TEST="$NAME: multiple EOF messages"
+# start two processes, connected via UNIX socket. The listener gets EOF from 
local address immediately; the second process then sends data. If the listener 
reports "socket 1 (fd .*) is at EOF" only once, the test succeeded
+if ! eval $NUMCOND; then :; else
+ts="$td/test$N.sock"
+tf="$td/test$N.stdout"
+te="$td/test$N.stderr"
+tdiff="$td/test$N.diff"
+da="test$N $(date) $RANDOM"
+CMD0="$TRACE $SOCAT $opts -d -d UNIX-LISTEN:$ts /dev/null"
+CMD1="$TRACE $SOCAT $opts -d -d - UNIX-CONNECT:$ts"
+printf "test $F_n $TEST... " $N
+$CMD0 >/dev/null 2>"${te}0" &
+pid0=$!
+waitunixport $ts 1
+echo "$da" |$CMD1 >"${tf}1" 2>"${te}1"
+rc1=$?
+kill $pid0 2>/dev/null; wait
+if [ $(grep "socket 2 (fd .*) is at EOF" ${te}0 |wc -l) -eq 1 ]; then
+    $PRINTF "$OK\n"
+    numOK=$((numOK+1))
+else
+    $PRINTF "$FAILED\n"
+    echo "$CMD0 &"
+    echo "$CMD1"
+    cat "${te}0"
+    cat "${te}1"
+    numFAIL=$((numFAIL+1))
+    listFAIL="$listFAIL $N"
+fi
+fi # NUMCOND
+ ;;
+esac
+N=$((N+1))
+
 
 
##################################################################################
 
#=================================================================================
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/xio-ip.c new/socat-1.7.3.4/xio-ip.c
--- old/socat-1.7.3.3/xio-ip.c  2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/xio-ip.c  2020-01-01 14:29:49.000000000 +0100
@@ -121,7 +121,7 @@
    hostname.domain (fq hostname resolving to IPv4 or IPv6 address)
  service: the port specification; may be numeric or symbolic
  family: PF_INET, PF_INET6, or PF_UNSPEC permitting both
- socktype: SOCK_STREAM, SOCK_DGRAM
+ socktype: SOCK_STREAM, SOCK_DGRAM, ...
  protocol: IPPROTO_UDP, IPPROTO_TCP
  sau: an uninitialized storage for the resulting socket address
  returns: STAT_OK, STAT_RETRYLATER
@@ -202,18 +202,9 @@
    if (node != NULL || service != NULL) {
       struct addrinfo *record;
 
-      if (socktype != SOCK_STREAM && socktype != SOCK_DGRAM) {
-        /* actual socket type value is not supported - fallback to a good one 
*/
-        socktype = SOCK_DGRAM;
-      }
-      if (protocol != IPPROTO_TCP && protocol != IPPROTO_UDP) {
-        /* actual protocol value is not supported - fallback to a good one */
-        if (socktype == SOCK_DGRAM) {
-           protocol = IPPROTO_UDP;
-        } else {
-           protocol = IPPROTO_TCP;
-        }
-      }
+      /* here was code that helped SCTP to use service names.
+        If you need this feature enhance your /etc/services with sctp entries 
*/
+
       hints.ai_flags |= AI_PASSIVE;
       hints.ai_family = family;
       hints.ai_socktype = socktype;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/xio-openssl.c 
new/socat-1.7.3.4/xio-openssl.c
--- old/socat-1.7.3.3/xio-openssl.c     2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/xio-openssl.c     2020-01-01 14:03:27.000000000 +0100
@@ -1023,6 +1023,7 @@
    }
 #endif
 
+#if defined(HAVE_SSL_CTX_clear_mode) || defined(SSL_CTX_clear_mode)
    /* It seems that OpenSSL-1.1.1 presets the mode differently.
       Without correction socat might hang in SSL_read() */
    {
@@ -1034,6 +1035,7 @@
         SSL_CTX_clear_mode(*ctx, SSL_MODE_AUTO_RETRY);
       }
    }
+#endif /* defined(HAVE_SSL_CTX_clear_mode) || defined(SSL_CTX_clear_mode) */
 
    if (opt_cafile != NULL || opt_capath != NULL) {
       if (sycSSL_CTX_load_verify_locations(*ctx, opt_cafile, opt_capath) != 1) 
{
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/xio-termios.h 
new/socat-1.7.3.4/xio-termios.h
--- old/socat-1.7.3.3/xio-termios.h     2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/xio-termios.h     2019-12-30 09:46:22.000000000 +0100
@@ -148,7 +148,7 @@
 extern int xiotermios_value(int fd, int word, tcflag_t mask, tcflag_t value);
 extern int xiotermios_char(int fd, int n, unsigned char c);
 #ifdef HAVE_TERMIOS_ISPEED
-extern int xiotermios_speed(int fd, int n, unsigned int speed);
+extern int xiotermios_speed(int fd, int n, speed_t speed);
 #endif
 extern int xiotermios_spec(int fd, int optcode);
 extern int xiotermios_flush(int fd);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/xio.h new/socat-1.7.3.4/xio.h
--- old/socat-1.7.3.3/xio.h     2017-01-21 15:42:57.000000000 +0100
+++ new/socat-1.7.3.4/xio.h     2020-01-04 10:26:26.000000000 +0100
@@ -129,7 +129,8 @@
    bool   ignoreeof;   /* option ignoreeof; do not pass eof condition to app*/
    int    eof;         /* 1..exec'd child has died, but no explicit eof
                           occurred 
-                          2..fd0 has reached EOF (definitely; never with
+                          2..fd0 has reached EOF, but check for ignoreeof
+                          3..fd0 has reached EOF (definitely; never with
                           ignoreeof! */
    size_t wsize;       /* write always this size; 0..all available */
    size_t readbytes;   /* read only so many bytes; 0...unlimited */
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' 
'--exclude=.svnignore' old/socat-1.7.3.3/xioopts.c new/socat-1.7.3.4/xioopts.c
--- old/socat-1.7.3.3/xioopts.c 2019-04-04 10:59:55.000000000 +0200
+++ new/socat-1.7.3.4/xioopts.c 2019-12-30 10:09:23.000000000 +0100
@@ -3581,7 +3581,7 @@
    }
 
 #if WITH_TERMIOS
-   if (phase == PH_FD) {
+   if (phase == PH_FD || phase == PH_ALL) {
       xiotermios_flush(fd);
    }
 #endif /* WITH_TERMIOS */

++++++ socat-common-fixes.patch ++++++
--- /var/tmp/diff_new_pack.WZ0Ugf/_old  2020-04-25 20:07:10.739406050 +0200
+++ /var/tmp/diff_new_pack.WZ0Ugf/_new  2020-04-25 20:07:10.739406050 +0200
@@ -1,7 +1,7 @@
-Index: socat-1.7.3.3/filan.c
+Index: socat-1.7.3.4/filan.c
 ===================================================================
---- socat-1.7.3.3.orig/filan.c
-+++ socat-1.7.3.3/filan.c
+--- socat-1.7.3.4.orig/filan.c
++++ socat-1.7.3.4/filan.c
 @@ -20,6 +20,10 @@
  
  #include "filan.h"
@@ -24,10 +24,10 @@
  /* global variables for configuring filan */
  bool filan_followsymlinks;
  bool filan_rawoutput;
-Index: socat-1.7.3.3/procan.c
+Index: socat-1.7.3.4/procan.c
 ===================================================================
---- socat-1.7.3.3.orig/procan.c
-+++ socat-1.7.3.3/procan.c
+--- socat-1.7.3.4.orig/procan.c
++++ socat-1.7.3.4/procan.c
 @@ -16,6 +16,9 @@
  #include "filan.h"
  
@@ -38,10 +38,10 @@
  
  #include "procan.h"
  
-Index: socat-1.7.3.3/xio-tcpwrap.c
+Index: socat-1.7.3.4/xio-tcpwrap.c
 ===================================================================
---- socat-1.7.3.3.orig/xio-tcpwrap.c
-+++ socat-1.7.3.3/xio-tcpwrap.c
+--- socat-1.7.3.4.orig/xio-tcpwrap.c
++++ socat-1.7.3.4/xio-tcpwrap.c
 @@ -13,6 +13,7 @@
  #include "xio-tcpwrap.h"
  

++++++ socat-ignore-tests-failure-boo1078346.patch ++++++
--- /var/tmp/diff_new_pack.WZ0Ugf/_old  2020-04-25 20:07:10.751406075 +0200
+++ /var/tmp/diff_new_pack.WZ0Ugf/_new  2020-04-25 20:07:10.751406075 +0200
@@ -10,11 +10,11 @@
  test.sh |    2 +-
  1 file changed, 1 insertion(+), 1 deletion(-)
 
-Index: socat-1.7.3.2/test.sh
+Index: socat-1.7.3.4/test.sh
 ===================================================================
---- socat-1.7.3.2.orig/test.sh
-+++ socat-1.7.3.2/test.sh
-@@ -12801,7 +12801,7 @@ echo "summary: $((N-1)) tests, $((numOK+
+--- socat-1.7.3.4.orig/test.sh
++++ socat-1.7.3.4/test.sh
+@@ -13224,7 +13224,7 @@ echo "summary: $((N-1)) tests, $((numOK+
  
  if [ "$numFAIL" -gt 0 ]; then
      echo "FAILED: $listFAIL"


Reply via email to