Bug 446199

Summary: *** buffer overflow detected ***: apachetop terminated
Product: [Fedora] Fedora Reporter: Robert Scheck <redhat-bugzilla>
Component: apachetopAssignee: Aurelien Bompard <gauret>
Status: CLOSED CURRENTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: high Docs Contact:
Priority: low    
Version: 9CC: me
Target Milestone: ---   
Target Release: ---   
Hardware: All   
OS: Linux   
Whiteboard:
Fixed In Version: 0.12.6-5.fc9 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2008-06-22 20:43:43 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Attachments:
Description Flags
apachetop-0.12.6-maxpathlen.patch none

Description Robert Scheck 2008-05-13 14:00:05 UTC
Description of problem:
Please note, that the following problem also applies to Fedora 9.

robert@tux:~ > apachetop -f /var/log/httpd/access_log
*** buffer overflow detected ***: apachetop terminated
======= Backtrace: =========
/lib/libc.so.6(__fortify_fail+0x48)[0x3cec48]
/lib/libc.so.6[0x3ccd40]
/lib/libc.so.6[0x3cd4a8]
apachetop(__gxx_personality_v0+0x46d)[0x80496a5]
apachetop[0x804a2d6]
/lib/libc.so.6(__libc_start_main+0xe6)[0x2ee5d6]
apachetop(__gxx_personality_v0+0xd9)[0x8049311]
======= Memory map: ========
00110000-0012c000 r-xp 00000000 68:02 2965506    /lib/ld-2.8.so
0012c000-0012d000 r-xp 0001c000 68:02 2965506    /lib/ld-2.8.so
0012d000-0012e000 rwxp 0001d000 68:02 2965506    /lib/ld-2.8.so
0012e000-0012f000 r-xp 0012e000 00:00 0          [vdso]
0012f000-00160000 r-xp 00000000 68:02 2965525    /lib/libreadline.so.5.2
00160000-00164000 rwxp 00031000 68:02 2965525    /lib/libreadline.so.5.2
00164000-00165000 rwxp 00164000 00:00 0
00165000-00186000 r-xp 00000000 68:02 2965732    /lib/libncurses.so.5.6
00186000-00187000 rwxp 00020000 68:02 2965732    /lib/libncurses.so.5.6
00187000-001b0000 r-xp 00000000 68:02 2965518    /lib/libpcre.so.0.0.1
001b0000-001b1000 rwxp 00028000 68:02 2965518    /lib/libpcre.so.0.0.1
001b1000-00296000 r-xp 00000000 68:02 393288     /usr/lib/libstdc++.so.6.0.10
00296000-0029a000 r-xp 000e4000 68:02 393288     /usr/lib/libstdc++.so.6.0.10
0029a000-0029b000 rwxp 000e8000 68:02 393288     /usr/lib/libstdc++.so.6.0.10
0029b000-002a1000 rwxp 0029b000 00:00 0
002a1000-002c8000 r-xp 00000000 68:02 2965678    /lib/libm-2.8.so
002c8000-002c9000 r-xp 00026000 68:02 2965678    /lib/libm-2.8.so
002c9000-002ca000 rwxp 00027000 68:02 2965678    /lib/libm-2.8.so
002ca000-002d7000 r-xp 00000000 68:02 2965617    /lib/libgcc_s-4.3.0-20080428.so.1
002d7000-002d8000 rwxp 0000c000 68:02 2965617    /lib/libgcc_s-4.3.0-20080428.so.1
002d8000-0043b000 r-xp 00000000 68:02 2965520    /lib/libc-2.8.so
0043b000-0043d000 r-xp 00163000 68:02 2965520    /lib/libc-2.8.so
0043d000-0043e000 rwxp 00165000 68:02 2965520    /lib/libc-2.8.so
0043e000-00441000 rwxp 0043e000 00:00 0
00441000-00457000 r-xp 00000000 68:02 2965736    /lib/libtinfo.so.5.6
00457000-0045a000 rwxp 00015000 68:02 2965736    /lib/libtinfo.so.5.6
0045a000-0045d000 r-xp 00000000 68:02 2965644    /lib/libdl-2.8.so
0045d000-0045e000 r-xp 00002000 68:02 2965644    /lib/libdl-2.8.so
0045e000-0045f000 rwxp 00003000 68:02 2965644    /lib/libdl-2.8.so
08048000-08051000 r-xp 00000000 68:02 377773     /usr/bin/apachetop
08051000-08052000 rw-p 00009000 68:02 377773     /usr/bin/apachetop
0960c000-0962d000 rw-p 0960c000 00:00 0
b7f3c000-b7f40000 rw-p b7f3c000 00:00 0
bfb28000-bfb3d000 rw-p bffea000 00:00 0          [stack]
Canceled
robert@tux:~ > 

Version-Release number of selected component (if applicable):
apachetop-0.12.6-4

How reproducible:
Everytime, just: apachetop -f /var/log/httpd/access_log

Actual results:
*** buffer overflow detected ***: apachetop terminated

Expected results:
Just working...

Additional info:
(gdb) bt
#0  0x0012e402 in __kernel_vsyscall ()
#1  0x00302660 in raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
#2  0x00304028 in abort () at abort.c:88
#3  0x0033f5bd in __libc_message (do_abort=2, fmt=0x411bbd "*** %s ***: %s
terminated\n") at ../sysdeps/unix/sysv/linux/libc_fatal.c:170
#4  0x003cec48 in __fortify_fail (msg=0x411b8c "buffer overflow detected") at
fortify_fail.c:32
#5  0x003ccd40 in __chk_fail () at chk_fail.c:29
#6  0x003cd4a8 in __realpath_chk (buf=0xbffdd9c8 "/var/log/httpd/access_log",
resolved=0xbffd3e48 "8 /\tpáC", resolvedlen=128) at realpath_chk.c:30
#7  0x080496a5 in new_file ()
#8  0x0804a2d6 in main ()
(gdb) bt full
#0  0x0012e402 in __kernel_vsyscall ()
No symbol table info available.
#1  0x00302660 in raise (sig=6) at ../nptl/sysdeps/unix/sysv/linux/raise.c:64
        resultvar = <value optimized out>
        pid = 4444148
        selftid = 5642
#2  0x00304028 in abort () at abort.c:88
        act = {__sigaction_handler = {sa_handler = 0xbffd36ac, sa_sigaction =
0xbffd36ac}, sa_mask = {__val = {4131897, 1233472, 0, 1233472, 0, 3221043000,
134517521, 1234520, 3, 951, 134514798, 3,
      134513068, 134513140, 3858732, 9, 3221042928, 3, 3233108, 4444148, 9, 7,
3221043044, 3980792, 3, 3221042928, 9, 0, 4263955, 4263951, 4267973, 4266865}},
sa_flags = 4266889, sa_restorer = 0x411b85}
        sigs = {__val = {32, 0 <repeats 31 times>}}
#3  0x0033f5bd in __libc_message (do_abort=2, fmt=0x411bbd "*** %s ***: %s
terminated\n") at ../sysdeps/unix/sysv/linux/libc_fatal.c:170
        ap = 0xbffd3d88 "ôÏC"
        fd = 3
        on_2 = <value optimized out>
        list = <value optimized out>
        nlist = 5
        cp = <value optimized out>
        written = 6
#4  0x003cec48 in __fortify_fail (msg=0x411b8c "buffer overflow detected") at
fortify_fail.c:32
No locals.
#5  0x003ccd40 in __chk_fail () at chk_fail.c:29
No locals.
#6  0x003cd4a8 in __realpath_chk (buf=0xbffdd9c8 "/var/log/httpd/access_log",
resolved=0xbffd3e48 "8 /\tpáC", resolvedlen=128) at realpath_chk.c:30
No locals.
#7  0x080496a5 in new_file ()
No symbol table info available.
#8  0x0804a2d6 in main ()
No symbol table info available.
(gdb)

Comment 1 Bug Zapper 2008-05-14 11:05:15 UTC
Changing version to '9' as part of upcoming Fedora 9 GA.
More information and reason for this action is here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 2 Robert Scheck 2008-05-17 18:56:32 UTC
Ping?

Comment 3 Brad Walker 2008-06-03 03:44:41 UTC
apachetop-0.12.6-4.fc9.x86_64 does the same for me.

Comment 4 Robert Scheck 2008-06-21 14:22:14 UTC
Created attachment 309968 [details]
apachetop-0.12.6-maxpathlen.patch

This patch solves the problem for me. Looks like behaviour changed a bit
compared with previous versions of Fedora. New apachetop-0.12.6-5 package
will fix this for Fedora 9 and Rawhide.

Comment 5 Robert Scheck 2008-06-21 14:35:16 UTC
Package: apachetop-0.12.6-5.fc10 Tag: dist-f10 Status: complete
Package: apachetop-0.12.6-5.fc9 Tag: dist-f9-updates-candidate Status: complete

Comment 6 Fedora Update System 2008-06-21 14:48:38 UTC
apachetop-0.12.6-5.fc9 has been submitted as an update for Fedora 9

Comment 7 Fedora Update System 2008-06-22 20:43:41 UTC
apachetop-0.12.6-5.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.

Comment 8 Fedora Update System 2008-07-26 05:55:57 UTC
apachetop-0.12.6-5.fc9 has been pushed to the Fedora 9 stable repository.  If problems still persist, please make note of it in this bug report.