From 1d286f400c819f169e9bf895528529b48221690eaccbb2593e121972ff02a3ec Mon Sep 17 00:00:00 2001 From: Pascal Bleser Date: Sun, 2 Feb 2014 10:14:32 +0000 Subject: [PATCH] 1.7.2.3: fixes CVE-2014-0019 OBS-URL: https://build.opensuse.org/package/show/network:utilities/socat?expand=0&rev=21 --- socat-1.7.2.2.tar.bz2 | 3 --- socat-1.7.2.3.tar.bz2 | 3 +++ socat-remove_date.patch | 31 +++++++++++++++++++++++++++++++ socat.changes | 7 +++++++ socat.spec | 8 +++++--- 5 files changed, 46 insertions(+), 6 deletions(-) delete mode 100644 socat-1.7.2.2.tar.bz2 create mode 100644 socat-1.7.2.3.tar.bz2 create mode 100644 socat-remove_date.patch diff --git a/socat-1.7.2.2.tar.bz2 b/socat-1.7.2.2.tar.bz2 deleted file mode 100644 index 8dd70a8..0000000 --- a/socat-1.7.2.2.tar.bz2 +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:9a167af11a4d3809cbc66f5e2dcb39b6e371251282ef5de6ea6ff0c4be8a953c -size 433222 diff --git a/socat-1.7.2.3.tar.bz2 b/socat-1.7.2.3.tar.bz2 new file mode 100644 index 0000000..5bd3261 --- /dev/null +++ b/socat-1.7.2.3.tar.bz2 @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:0598ac54af7b138cda9e3c141bcf0cc63eeb2ab31f468a772dc3f7eb3896aad0 +size 424461 diff --git a/socat-remove_date.patch b/socat-remove_date.patch new file mode 100644 index 0000000..07bbea3 --- /dev/null +++ b/socat-remove_date.patch @@ -0,0 +1,31 @@ +diff --git a/socat.c b/socat.c +index 5062914..4c9aa1a 100644 +--- a/socat.c ++++ b/socat.c +@@ -70,8 +70,6 @@ static int socat_newchild(void); + static const char socatversion[] = + #include "./VERSION" + ; +-static const char timestamp[] = __DATE__" "__TIME__; +- + const char copyright_socat[] = "socat by Gerhard Rieger - see www.dest-unreach.org"; + #if WITH_OPENSSL + const char copyright_openssl[] = "This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit. (http://www.openssl.org/)"; +@@ -273,7 +271,7 @@ int main(int argc, const char *argv[]) { + Info(copyright_openssl); + Info(copyright_ssleay); + #endif +- Debug2("socat version %s on %s", socatversion, timestamp); ++ Debug1("socat version %s", socatversion); + xiosetenv("VERSION", socatversion, 1); /* SOCAT_VERSION */ + uname(&ubuf); /* ! here we circumvent internal tracing (Uname) */ + Debug4("running on %s version %s, release %s, machine %s\n", +@@ -363,7 +361,7 @@ void socat_version(FILE *fd) { + struct utsname ubuf; + + fputs(copyright_socat, fd); fputc('\n', fd); +- fprintf(fd, "socat version %s on %s\n", socatversion, timestamp); ++ fprintf(fd, "socat version %s\n", socatversion); + Uname(&ubuf); + fprintf(fd, " running on %s version %s, release %s, machine %s\n", + ubuf.sysname, ubuf.version, ubuf.release, ubuf.machine); diff --git a/socat.changes b/socat.changes index 5fa19b2..e1efa07 100644 --- a/socat.changes +++ b/socat.changes @@ -1,3 +1,10 @@ +------------------------------------------------------------------- +Sun Feb 02 10:09:04 UTC 2014 - pascal.bleser@opensuse.org + +- update to 1.7.2.3: security fix: + * CVE-2014-0019: socats PROXY-CONNECT address was vulnerable to a buffer + overflow with data from command line (see socat-secadv5.txt) + ------------------------------------------------------------------- Tue May 28 13:27:12 UTC 2013 - meissner@suse.com diff --git a/socat.spec b/socat.spec index 0258750..6cdbd5a 100644 --- a/socat.spec +++ b/socat.spec @@ -1,7 +1,7 @@ # # spec file for package socat # -# Copyright (c) 2013 SUSE LINUX Products GmbH, Nuernberg, Germany. +# Copyright (c) 2014 SUSE LINUX Products GmbH, Nuernberg, Germany. # Copyright (c) 2010 Pascal Bleser # # All modifications and additions to the file contributed by third parties @@ -22,7 +22,7 @@ BuildRequires: openssl-devel BuildRequires: procps BuildRequires: readline-devel BuildRequires: tcpd-devel -Version: 1.7.2.2 +Version: 1.7.2.3 Release: 0 Url: http://www.dest-unreach.org/socat/ Summary: Multipurpose relay for bidirectional data transfer @@ -30,6 +30,7 @@ License: SUSE-GPL-2.0-with-openssl-exception and MIT Group: Productivity/Networking/Other # 1.7.2.1: md5 7ddfea7e9e85f868670f94d3ea08358b Source: http://www.dest-unreach.org/socat/download/%{name}-%{version}.tar.bz2 +Patch1: socat-remove_date.patch BuildRoot: %{_tmppath}/%{name}-%{version}-build %description @@ -42,6 +43,7 @@ combination of two of these. %prep %setup +%patch1 -p1 %build export RPM_OPT_FLAGS="%{optflags} -fno-strict-aliasing" @@ -65,6 +67,6 @@ mkdir -p \ %{_bindir}/socat %{_bindir}/procan %{_bindir}/filan -%{_mandir}/man1/socat.1%{ext_man} +%{_mandir}/man1/socat.1* %changelog