summaryrefslogtreecommitdiffstats
path: root/meta/recipes-core/glibc/glibc/CVE-2016-3075.patch
diff options
context:
space:
mode:
authorPascal Bach <pascal.bach@siemens.com>2016-10-14 14:26:44 +0200
committerRichard Purdie <richard.purdie@linuxfoundation.org>2016-11-08 23:47:12 +0000
commit732dd581f3e66175feccd811bc2ef9f814ee0705 (patch)
tree78ec9ff5e03386347cee87655753f5a61f363ad1 /meta/recipes-core/glibc/glibc/CVE-2016-3075.patch
parent40f4a6d075236265086cc79400dea3c14720383a (diff)
downloadpoky-732dd581f3e66175feccd811bc2ef9f814ee0705.tar.gz
glibc: fix CVE-2016-1234, CVE-2016-3075, CVE-2016-5417
Only relevant for krogoth since version 2.24+ (master, morty) is not affected. (From OE-Core rev: 88be4b40bacc7c8a08fb76fc220f491deb2c1c3a) Signed-off-by: Pascal Bach <pascal.bach@siemens.com> Signed-off-by: Armin Kuster <akuster808@gmail.com> Signed-off-by: Richard Purdie <richard.purdie@linuxfoundation.org>
Diffstat (limited to 'meta/recipes-core/glibc/glibc/CVE-2016-3075.patch')
-rw-r--r--meta/recipes-core/glibc/glibc/CVE-2016-3075.patch37
1 files changed, 37 insertions, 0 deletions
diff --git a/meta/recipes-core/glibc/glibc/CVE-2016-3075.patch b/meta/recipes-core/glibc/glibc/CVE-2016-3075.patch
new file mode 100644
index 0000000000..7b9dc4f5c3
--- /dev/null
+++ b/meta/recipes-core/glibc/glibc/CVE-2016-3075.patch
@@ -0,0 +1,37 @@
1glibc-2.23: Fix CVE-2016-3075
2
3[No upstream tracking] -- https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2016-3075
4
5resolv/nss_dns/dns-network.c: Stack overflow in _nss_dns_getnetbyname_r
6
7The defensive copy is not needed because the name may not alias the
8output buffer.
9
10Upstream-Status: Backport
11CVE: CVE-2016-3075
12Signed-off-by: Andrej Valek <andrej.valek@siemens.com>
13Signed-off-by: Pascal Bach <pascal.bach@siemens.com>
14
15diff --git a/resolv/nss_dns/dns-network.c b/resolv/nss_dns/dns-network.c
16index 2eb2f67..8f301a7 100644
17--- a/resolv/nss_dns/dns-network.c
18+++ b/resolv/nss_dns/dns-network.c
19@@ -118,17 +118,14 @@ _nss_dns_getnetbyname_r (const char *name, struct netent *result,
20 } net_buffer;
21 querybuf *orig_net_buffer;
22 int anslen;
23- char *qbuf;
24 enum nss_status status;
25
26 if (__res_maybe_init (&_res, 0) == -1)
27 return NSS_STATUS_UNAVAIL;
28
29- qbuf = strdupa (name);
30-
31 net_buffer.buf = orig_net_buffer = (querybuf *) alloca (1024);
32
33- anslen = __libc_res_nsearch (&_res, qbuf, C_IN, T_PTR, net_buffer.buf->buf,
34+ anslen = __libc_res_nsearch (&_res, name, C_IN, T_PTR, net_buffer.buf->buf,
35 1024, &net_buffer.ptr, NULL, NULL, NULL, NULL);
36 if (anslen < 0)
37 {