[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-devel
Subject:    Running part of the code with superuser privileges
From:       Iván Forcada Atienza <ivan () swscanner ! org>
Date:       2006-05-28 16:02:04
Message-ID: 20060528160204.GA6340 () masao ! forcada ! info
[Download RAW message or body]

[Attachment #2 (multipart/signed)]


Hi all.

First of all, note that i'm not sure if this topic fits well with this
mailing list. If so, please accept my apologies and feel free to add the
'OT' keyword to the subject.

I'm developing a kde application which needs to perform some tasks
related with network interfaces. Some of these tasks need superuser 
privileges.

I know I could run the full program as root, and that I could launch
another process as root that runs i.e. ifconfig, but I would like to
avoid that situations if possible.

So, I was thinking about the possibility of (using fork() or something
like that) running part of the code as normal user, and the other part
as root. I'm a newbie programmer and have no experience with fork() :-(

Is it possible?? Any other workaround to achieve this?? Examples, docs??

Thanks in advance!! :-)

-- 
__________________________________________________________________
Iván Forcada Atienza:
  correo: ivan@forcada.info
  jabber: ivanfor@jabber.guadawireless.org
------------------------------------------------------------------
Nodo guada21 en GuadaWireless usando Debian GNU/Linux:
  http://el21.guadawireless.net
------------------------------------------------------------------
"Software is like sex: it's better when it's free" (Linus Torvalds)

[Attachment #5 (application/pgp-signature)]

>> Visit http://mail.kde.org/mailman/listinfo/kde-devel#unsub to unsubscribe <<


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic