guix-commits
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

02/02: gnu: osip: Fix CVE-2017-7853.


From: Leo Famulari
Subject: 02/02: gnu: osip: Fix CVE-2017-7853.
Date: Wed, 14 Jun 2017 13:17:05 -0400 (EDT)

lfam pushed a commit to branch master
in repository guix.

commit 75072795bd5239f8f57daf946b4918c3acd37d27
Author: Leo Famulari <address@hidden>
Date:   Wed Jun 14 13:15:31 2017 -0400

    gnu: osip: Fix CVE-2017-7853.
    
    * gnu/packages/patches/osip-CVE-2017-7853.patch: New file.
    * gnu/local.mk (dist_patch_DATA): Add it.
    * gnu/packages/telephony.scm (osip)[source]: Use it.
---
 gnu/local.mk                                  |  1 +
 gnu/packages/patches/osip-CVE-2017-7853.patch | 40 +++++++++++++++++++++++++++
 gnu/packages/telephony.scm                    |  1 +
 3 files changed, 42 insertions(+)

diff --git a/gnu/local.mk b/gnu/local.mk
index 608ded7..8fcd2ca 100644
--- a/gnu/local.mk
+++ b/gnu/local.mk
@@ -876,6 +876,7 @@ dist_patch_DATA =                                           
\
   %D%/packages/patches/openssl-1.1.0-c-rehash-in.patch         \
   %D%/packages/patches/openssl-c-rehash-in.patch               \
   %D%/packages/patches/orpheus-cast-errors-and-includes.patch  \
+  %D%/packages/patches/osip-CVE-2017-7853.patch                        \
   %D%/packages/patches/ots-no-include-missing-file.patch       \
   %D%/packages/patches/p7zip-CVE-2016-9296.patch                       \
   %D%/packages/patches/p7zip-remove-unused-code.patch          \
diff --git a/gnu/packages/patches/osip-CVE-2017-7853.patch 
b/gnu/packages/patches/osip-CVE-2017-7853.patch
new file mode 100644
index 0000000..33d95cd
--- /dev/null
+++ b/gnu/packages/patches/osip-CVE-2017-7853.patch
@@ -0,0 +1,40 @@
+Fix CVE-2017-7853:
+
+https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2017-7853
+https://savannah.gnu.org/support/index.php?109265
+
+Patch copied from upstream source repository:
+
+https://git.savannah.gnu.org/cgit/osip.git/commit/?id=1ae06daf3b2375c34af23083394a6f010be24a45
+
+From 1ae06daf3b2375c34af23083394a6f010be24a45 Mon Sep 17 00:00:00 2001
+From: Aymeric Moizard <address@hidden>
+Date: Tue, 21 Feb 2017 17:16:26 +0100
+Subject: [PATCH]  * fix bug report: sr #109265: SIP message body length
+ underflow in libosip2-4.1.0    https://savannah.gnu.org/support/?109265   
+ also applicable to current latest version
+
+---
+ src/osipparser2/osip_message_parse.c | 6 ++++++
+ 1 file changed, 6 insertions(+)
+
+diff --git a/src/osipparser2/osip_message_parse.c 
b/src/osipparser2/osip_message_parse.c
+index 1628c60..aa35446 100644
+--- a/src/osipparser2/osip_message_parse.c
++++ b/src/osipparser2/osip_message_parse.c
+@@ -784,6 +784,12 @@ msg_osip_body_parse (osip_message_t * sip, const char 
*start_of_buf, const char
+     if ('\n' == start_of_body[0] || '\r' == start_of_body[0])
+       start_of_body++;
+ 
++    /* if message body is empty or contains a single CR/LF */
++    if (end_of_body <= start_of_body) {
++      osip_free (sep_boundary);
++      return OSIP_SYNTAXERROR;
++    }
++
+     body_len = end_of_body - start_of_body;
+ 
+     /* Skip CR before end boundary. */
+-- 
+2.13.1
+
diff --git a/gnu/packages/telephony.scm b/gnu/packages/telephony.scm
index 601bfd6..c3bf203 100644
--- a/gnu/packages/telephony.scm
+++ b/gnu/packages/telephony.scm
@@ -124,6 +124,7 @@ packet-manipulation library.")
    (source (origin
             (method url-fetch)
             (uri (string-append "mirror://gnu/osip/libosip2-" version 
".tar.gz"))
+            (patches (search-patches "osip-CVE-2017-7853.patch"))
             (sha256
              (base32
               "00yznbrm9q04wgd4b831km8iwlvwvsnwv87igf79g5vj9yakr88q"))))



reply via email to

[Prev in Thread] Current Thread [Next in Thread]