You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by John Stauffacher <st...@chapman.edu> on 2002/09/03 23:49:30 UTC
User process ownership
All,
I've run into an interesting problem which I can't seem to figure out.
Here it is: I have created a web form/perl script that sets up a users
vacation file and .forward for them. Which works. The only problem is, I
cannot write to their home directory (because Apache does not have
rights to). The users *ARE* being authenticated via LDAP -- is there any
way I can spawn a process with the ownership of the user to write to
their directories within mod perl?
-John Stauffacher
++
John Stauffacher
Network Administrator
Chapman University
stauffacher@chapman.edu
714-628-7249
RE: User process ownership
Posted by simran <si...@leonardchristian.com>.
You could do the chmod thing...but keep in mind, that it won't work
unless you have perl compiled with suid script support (i think) and
also your kernel has to support setuid scripts (which by default it
probably doesn't because of race conditions causing major unsecurity...)
On Fri, 2002-09-06 at 00:20, Mark Coffman wrote:
> Or if you really dont care about security maybe you could chmod 4755 the
> script, owned by root, to run as root. Just make sure that you clean all of
> the data you receive from the form. I kinda like the daemon idea that
> simran had.
>
> -----Original Message-----
> From: simran [mailto:simran.list@leonardchristian.com]
>
> Alternatively, you can write a daemon that runs as root that you can
> connect to that can do this...
>
>
>
>
RE: User process ownership
Posted by Mark Coffman <mc...@smill.com>.
Or if you really dont care about security maybe you could chmod 4755 the
script, owned by root, to run as root. Just make sure that you clean all of
the data you receive from the form. I kinda like the daemon idea that
simran had.
-----Original Message-----
From: simran [mailto:simran.list@leonardchristian.com]
Alternatively, you can write a daemon that runs as root that you can
connect to that can do this...
Re: User process ownership
Posted by simran <si...@leonardchristian.com>.
How about using "sudo" so that you can run a system command that can
"su" up to the correct account and do it.
Alternatively, you can write a daemon that runs as root that you can
connect to that can do this...
On Wed, 2002-09-04 at 20:09, Nico Erfurth wrote:
> John Stauffacher wrote:
> > All,
> >
> > I've run into an interesting problem which I can't seem to figure out.
> > Here it is: I have created a web form/perl script that sets up a users
> > vacation file and .forward for them. Which works. The only problem is, I
> > cannot write to their home directory (because Apache does not have
> > rights to). The users *ARE* being authenticated via LDAP -- is there any
> > way I can spawn a process with the ownership of the user to write to
> > their directories within mod perl?
>
> The best way is to write in a temp-file and run a cronjob every 5
> minutes or so.
>
> ciao
>
>
>
Re: User process ownership
Posted by Nico Erfurth <ma...@perlgolf.de>.
John Stauffacher wrote:
> All,
>
> I've run into an interesting problem which I can't seem to figure out.
> Here it is: I have created a web form/perl script that sets up a users
> vacation file and .forward for them. Which works. The only problem is, I
> cannot write to their home directory (because Apache does not have
> rights to). The users *ARE* being authenticated via LDAP -- is there any
> way I can spawn a process with the ownership of the user to write to
> their directories within mod perl?
The best way is to write in a temp-file and run a cronjob every 5
minutes or so.
ciao