Welcome to the most active Linux Forum on the web.
Go Back > Forums > Linux Forums > Linux - Newbie
User Name
Linux - Newbie This Linux forum is for members that are new to Linux.
Just starting out and have a question? If it is not in the man pages or the how-to's this is the place!


  Search this Thread
Old 09-22-2008, 01:07 AM   #1
LQ Newbie
Registered: Sep 2008
Posts: 2

Rep: Reputation: 0
IPC fails between user process and root process

I am using a CGI process to spawn a new process using execl system call. Both the CGI and the spawned processes are owned by user "www". The spawned process need to communicate with a system process owned by "root". The user "www" has lower privileges than the "root".

I have tried pipes and msg queues for IPC between the root process and the www process, but unfortunately both fail.

Am I doing something wrong? Generally speaking can a process with lower privilege send messages to a higher privilege process or to root process in Linux? If yes, is there a method that I am unaware of.

Old 09-22-2008, 02:25 AM   #2
Senior Member
Registered: May 2008
Location: planet earth
Distribution: Debian
Posts: 1,732

Rep: Reputation: 50
Pipes have permissions, so it is a matter of setting the permissions correctly. Be extremely careful passing data like this to a root-owned process; it opens up the system like WinDuhs.

An alternative is to use UNIX sockets (but you still need to assume that data coming into the root side cannot be trusted).

Are you sure there's no other way to get data without a root process?


Thread Tools Search this Thread
Search this Thread:

Advanced Search

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off

Similar Threads
Thread Thread Starter Forum Replies Last Post
Start a program for a user as root, with process belonging to user gnashley Programming 4 03-19-2007 02:58 PM
Boot process as non-root user fatman Debian 6 06-07-2005 05:08 PM
IPC Process! UltraSoul Solaris / OpenSolaris 1 02-04-2005 01:44 PM
IPC message between process (Sync) davidho3 Linux - Networking 1 07-24-2004 09:20 AM
IPC message between process (Sync) davidho3 Programming 1 07-24-2004 08:37 AM > Forums > Linux Forums > Linux - Newbie

All times are GMT -5. The time now is 09:07 PM.

Main Menu
Write for LQ is looking for people interested in writing Editorials, Articles, Reviews, and more. If you'd like to contribute content, let us know.
Main Menu
RSS1  Latest Threads
RSS1  LQ News
Twitter: @linuxquestions
Facebook: linuxquestions Google+: linuxquestions
Open Source Consulting | Domain Registration