Hi,

On Tue, Nov 18, 2008 at 06:32:17PM +0100, Kai Weber wrote:
> I tried to run sudo in gdb and step through the code, but I failed.
> Maybe you have a tip?

I stepped a bit through the code today and what I can get is that the
message ("not found") comes from sudo. The problem seems to be that
in sudo.c around the lines 621 - 625 when calling find_path the path is
still set to the invokers path and not to the secure path that is
inserted into the environment with which the program would be run.
I'm not yet so far to see:

a) why this happens
b) under which conditions

However I just remembered a workaround for you, as long as we don't know
the exact reason. You could configure an alias in /etc/profile:

alias sudo='PATH=$PATH:/sbin:/usr/sbin sudo'

I know that this is kind of ugly, but it works around the problem for
now:

[EMAIL PROTECTED]:~$ alias sudo='PATH=$PATH:/sbin:/usr/sbin sudo'
[EMAIL PROTECTED]:~$ sudo invoke-rc.d 
invoke-rc.d: syntax error: missing required parameter, --help assumed

>From what I currently can tell this indeed seems to be a bug.
However I'm uncertain how this is triggered, given that it seems to work
in certain situations. I'm also not sure if this deserves more work then
what we've already tried, because their is an easy workaround and it is
fixed in lenny anyway.

Regards,
Patrick



-- 
To UNSUBSCRIBE, email to [EMAIL PROTECTED]
with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

Reply via email to