public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
From: "konstantin.s.serebryany at gmail dot com" <sourceware-bugzilla@sourceware.org>
To: glibc-bugs@sourceware.org
Subject: [Bug libc/18096] New: null deref in wordexp/parse_dollars/parse_arith
Date: Mon, 09 Mar 2015 15:31:00 -0000	[thread overview]
Message-ID: <bug-18096-131@http.sourceware.org/bugzilla/> (raw)

https://sourceware.org/bugzilla/show_bug.cgi?id=18096

            Bug ID: 18096
           Summary: null deref in wordexp/parse_dollars/parse_arith
           Product: glibc
           Version: unspecified
            Status: NEW
          Severity: normal
          Priority: P2
         Component: libc
          Assignee: unassigned at sourceware dot org
          Reporter: konstantin.s.serebryany at gmail dot com
                CC: drepper.fsp at gmail dot com

#include <wordexp.h>
#include <string.h>
int main() {
  char *p = strdup("$[]");
  wordexp_t w;
  wordexp(p, &w, 0);
}

gcc we5.c && ./a.out 

    #0 0x7fe40ab0d3ae in parse_arith
/build/buildd/eglibc-2.19/posix/wordexp.c:774
    #1 0x7fe40ab0b123 in parse_dollars
/build/buildd/eglibc-2.19/posix/wordexp.c:2096
    #2 0x7fe40ab0dfeb in wordexp /build/buildd/eglibc-2.19/posix/wordexp.c:2348

2.19 and fresh trunk are affected.
Same fuzzer, see https://sourceware.org/glibc/wiki/FuzzingLibc

-- 
You are receiving this mail because:
You are on the CC list for the bug.


             reply	other threads:[~2015-03-09 15:31 UTC|newest]

Thread overview: 16+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2015-03-09 15:31 konstantin.s.serebryany at gmail dot com [this message]
2015-03-09 16:24 ` [Bug libc/18096] " konstantin.s.serebryany at gmail dot com
2015-03-09 18:56 ` konstantin.s.serebryany at gmail dot com
2015-03-11  6:44 ` carlos at redhat dot com
2015-03-11  8:57 ` schwab@linux-m68k.org
2015-03-11 13:45 ` carlos at redhat dot com
2015-03-11 14:03 ` schwab@linux-m68k.org
2015-03-11 16:12 ` konstantin.s.serebryany at gmail dot com
2015-03-11 16:20 ` carlos at redhat dot com
2015-03-11 16:34 ` carlos at redhat dot com
2015-03-11 22:23 ` bugdal at aerifal dot cx
2015-03-19 15:09 ` fweimer at redhat dot com
2015-07-12  7:44 ` neleai at seznam dot cz
2015-07-21 10:10 ` fweimer at redhat dot com
2015-08-27 22:26 ` [Bug glob/18096] " jsm28 at gcc dot gnu.org
2023-03-28 13:59 ` adhemerval.zanella at linaro dot org

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=bug-18096-131@http.sourceware.org/bugzilla/ \
    --to=sourceware-bugzilla@sourceware.org \
    --cc=glibc-bugs@sourceware.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).