[wellylug] Can't run an x-app using su

jumbophut jumbophut at gmail.com
Tue Jan 3 12:35:55 NZDT 2006


On 1/3/06, David Murray  wrote:
> How about writing a prog that calls pppd, handing to pppd any necessary
> info, and that then listens to the output produced by pppd and that
> responds according to the output of pppd rather than trying to get pppd to
> call some other programme.?
>
Thanks for your response David.

I currently have solution which involves calling pppd, watching
/proc/net/dev, and taking appropriate actions.  For various reasons --
kernel or pppd bugs -- it doesn't work very well (/proc/net/dev
doesn't always get updated as it should).

> I ain't no programmer, but that would seem to be an easy workaround rather
> than getting pppd to spawn a lesser-priviliged child process.
>

Easier, yes, but it doesn't work as well as I would like.  And I can
get pppd to spawn lesser-privileged child processes without a problem,
as long as they don't use X.

> And I would have thought that SU was not intended to be called from within
> a programme, for security reasons.
>

As I noted, I'm not actually calling su from within my program.  That
was just a way to simulate an suid root process to identify the
problem interacting with X.  What happens in reality is that pppd,
which Debian installs as suid root, calls another program with root
privileges.  I can remove the root privileges and make it run as the
normal user, but that still doesn't let me run X apps.

I'm pretty sure that X and/or KDE, and the way they handle security,
are at the root of my problems.

Thanks for the suggestions though.

--
Tony (echo 'spend!,pocket awide' | sed 'y/acdeikospntw!, /l at omcgtjuba.phi/')




More information about the wellylug mailing list