Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 59131 - xtraceroute segfaults when executing traceroute is denied
Summary: xtraceroute segfaults when executing traceroute is denied
Status: RESOLVED UPSTREAM
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: Current packages (show other bugs)
Hardware: x86 Linux
: High normal (vote)
Assignee: Gentoo Netmon project
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-08-02 04:14 UTC by Jan Tegtmeier
Modified: 2004-08-20 07:01 UTC (History)
0 users

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Jan Tegtmeier 2004-08-02 04:14:15 UTC
With a fresh installation of traceroute [TR] and xtraceroute [XTR], XTR segfaults when running a trace by a user without permission to execute TR (not in the wheel group):

===============================
jan $ xtraceroute 
[... TIP-Text removed ...]
GLib-CRITICAL **: file gmain.c: line 500 (g_source_remove): assertion `tag > 0' failed.
Segmentation fault
jan $ 
===============================

The strace shows:
===============================
jan $ strace -f xtraceroute
[...lots of stuff deleted...]
[pid 10438] execve("/usr/sbin/traceroute", ["traceroute", "-q", "2", "-w", "20", "-m", "40", "195.4.42.1"], [/* 45 vars */]) = -1 EACCES (Permission denied)
[pid 10438] dup(2)                      = 0
[pid 10438] fcntl64(0, F_GETFL)         = 0x1 (flags O_WRONLY)
[pid 10438] close(0)                    = 0
[pid 10438] write(2, "exec: Permission denied\n", 24) = 24
[pid 10438] exit_group(1)               = ?
Process 10438 detached
gettimeofday({1091444771, 52174}, NULL) = 0
--- SIGCHLD (Child exited) @ 0 (0) ---
waitpid(10438, NULL, 0)                 = 10438
rt_sigreturn(0xbfffd618)                = 0
read(0, "e", 1)                         = 1
[...parent process now reads more of the errormsg from stdin up to last \n...]
read(0, "\n", 1)                        = 1
--- SIGSEGV (Segmentation fault) @ 0 (0) ---
+++ killed by SIGSEGV +++
jan $ 
===============================

And finally why this happens:
===============================
jan $ ls -la /usr/sbin/traceroute
-rws--x---  1 root wheel 18900 Aug  2 12:32 /usr/sbin/traceroute
jan $ id
uid=1000(jan) gid=100(users) groups=100(users)
jan $
===============================

Bye,
  Jan Tegtmeier
  Tegtmeier Internet Solutions e.K.



Reproducible: Always
Steps to Reproduce:



Expected Results:  
Return a error message.
Comment 1 Eldad Zack (RETIRED) gentoo-dev 2004-08-10 06:39:34 UTC
This issue should be taken upstream.
Comment 2 Eldad Zack (RETIRED) gentoo-dev 2004-08-20 07:01:46 UTC
I've sent an email to Bj
Comment 3 Eldad Zack (RETIRED) gentoo-dev 2004-08-20 07:01:46 UTC
I've sent an email to Björn Augustsson concerning this issue.