Cgi Scripts in User Dir's with CERN Server

Cgi Scripts in User Dir's with CERN Server

Post by Etienne de Bru » Sat, 09 Mar 1996 04:00:00



Forgive my ignorance, but is it possible to allow users to
execute cgi scripts in their ~user/ directories?  Last time
I tried it wasn't possible.  I am running a CERN Server.

Regards

eT

 
 
 

Cgi Scripts in User Dir's with CERN Server

Post by Gertjan van Oost » Tue, 12 Mar 1996 04:00:00



Quote:> Forgive my ignorance, but is it possible to allow users to
> execute cgi scripts in their ~user/ directories?  Last time
> I tried it wasn't possible.  I am running a CERN Server.

You didn't tell what you tried and why it failed.
Anyway, try this:

        Exec    /~edebruin/cgi-bin/*    /home/edebruin/cgi-bin/*

--


 
 
 

Cgi Scripts in User Dir's with CERN Server

Post by Tod Hart » Wed, 20 Mar 1996 04:00:00




>> Forgive my ignorance, but is it possible to allow users to
>> execute cgi scripts in their ~user/ directories?  Last time
>> I tried it wasn't possible.  I am running a CERN Server.
>You didn't tell what you tried and why it failed.
>Anyway, try this:
>    Exec    /~edebruin/cgi-bin/*    /home/edebruin/cgi-bin/*
>--


Cern 3.0 doesn't have this capability.  You can get the same result by
using the trick that UUNet seems to use.  Write a CGI program which
ALL cgi users must call.  Its extended path info gives the name of the
ACTUAL cgi that is to be run, along with any other path info the cgi
needs.  Your new cgi just does a cd to the right directory, fudges the
PATH_INFO variable to look as if the user's cgi was called directly
and voila it works!  You will probably need to mess with user ids
(suid,sgid) also so that your cgi can get access to the user's
directory etc, but this is all straightforward "C" or even Perl
programming (don't use Perl for this, it makes things way slow, trust
me).  I don't have the source for something like this or I would post
it, but ask around, it has been done at least once.

Tod Harter

 
 
 

Cgi Scripts in User Dir's with CERN Server

Post by Etienne de Bru » Fri, 22 Mar 1996 04:00:00






>>> Forgive my ignorance, but is it possible to allow users to
>>> execute cgi scripts in their ~user/ directories?  Last time
>>> I tried it wasn't possible.  I am running a CERN Server.
>>Anyway, try this:
>>        Exec    /~edebruin/cgi-bin/*    /home/edebruin/cgi-bin/*
>Cern 3.0 doesn't have this capability.  You can get the same result by
>using the trick that UUNet seems to use.  Write a CGI program which
>ALL cgi users must call.  Its extended path info gives the name of the
>ACTUAL cgi that is to be run, along with any other path info the cgi
>needs.  Your new cgi just does a cd to the right directory, fudges the
>PATH_INFO variable to look as if the user's cgi was called directly
>and voila it works!  You will probably need to mess with user ids
>(suid,sgid) also so that your cgi can get access to the user's
>directory etc, but this is all straightforward "C" or even Perl
>programming (don't use Perl for this, it makes things way slow, trust
>me).  I don't have the source for something like this or I would post
>it, but ask around, it has been done at least once.

Well, I disagree on the basis of trying out the Exec command and
everything working from then on.

eT