public inbox for glibc-bugs@sourceware.org
help / color / mirror / Atom feed
* [Bug libc/13280] New: execve(2) does not honor sysconf(_SC_ARG_MAX) in some cases.
@ 2011-10-11  8:36 sdrake at xnet dot co.nz
  2011-10-11  8:52 ` [Bug libc/13280] " schwab@linux-m68k.org
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: sdrake at xnet dot co.nz @ 2011-10-11  8:36 UTC (permalink / raw)
  To: glibc-bugs

http://sourceware.org/bugzilla/show_bug.cgi?id=13280

             Bug #: 13280
           Summary: execve(2) does not honor sysconf(_SC_ARG_MAX) in some
                    cases.
           Product: glibc
           Version: 2.13
            Status: NEW
          Severity: critical
          Priority: P2
         Component: libc
        AssignedTo: drepper.fsp@gmail.com
        ReportedBy: sdrake@xnet.co.nz
    Classification: Unclassified
              Host: x86_64-unknown-linux-gnu


Steven Drake <sdrake at xnet dot co.nz> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
              Flags|                            |testsuite+

Created attachment 5974
  --> http://sourceware.org/bugzilla/attachment.cgi?id=5974
test-skeleton.c based test case (causes execve to fail with E2BIG).

If execve is given an argv with a string that is larger than 131072
(coincidentally the ARG_MAX macro from linux/limits.h) but less than what
sysconf(_SC_ARG_MAX) return, execve fails with E2BIG.

This does not happen if the total length of the argv strings is greater
than ARG_MAX but each is shorter.

This is a problem if using "/bin/sh -c", i.e. system(3).

I'm not sure if this is a glibc or linux issue but I am reporting it here
anyway.

-- 
Configure bugmail: http://sourceware.org/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.


^ permalink raw reply	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2014-06-13 10:43 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-10-11  8:36 [Bug libc/13280] New: execve(2) does not honor sysconf(_SC_ARG_MAX) in some cases sdrake at xnet dot co.nz
2011-10-11  8:52 ` [Bug libc/13280] " schwab@linux-m68k.org
2012-03-08  4:24 ` carlos at systemhalted dot org
2014-06-13 10:43 ` fweimer at redhat dot com

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).