View unanswered posts | View active topics It is currently Tue Jul 05, 2022 4:55 pm



Reply to topic  [ 1 post ] 
 Perl script inherited permissions 
Author Message
Junior Member

Joined: Fri Apr 27, 2007 11:01 am
Posts: 1
Post Perl script inherited permissions
I am currently trying to code a perl script that will get the directory listing of a folder I'm hosting with Apache. The problem right now is with the way I have my server set up. In the httpd.conf, for the directory I want the perl script to be able to list all files and folders, I'm using the following rules:

Options +ExecCGI
AddHandler cgi-script cgi pl
<Files ~ "\.(mp3)$">
Order allow,deny
Deny from all
</Files>
Satisfy any
Allow from all

I have authentication set up so that when a user logs in, they are able to see all files and directories. If they are an anonymous user, I want to hide files from them within the directory. But therein lies the problem - my perl script doesn't get handed the permissions of the authenticated user, so when i use the get() command to get the directory listing, it returns back a page that is hiding the mp3 files (in this example.) So what I'm wanting to know is whether there is some rule/option/environmental that will allow the perl script to properly use the get() command with the right permissions. I don't know if there is an easier way to do what I'm trying to do, but I suppose I could have the perl script access the file system, instead of using get() and going through apache.. but this way was much easier as it is only one line of code.

Thanks, and sorry if that was confusing - I'm fairly new to all of this


Fri Apr 27, 2007 11:14 am
Report this post
Profile
Display posts from previous:  Sort by  
Reply to topic   [ 1 post ] 

Who is online

Users browsing this forum: No registered users and 0 guests


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot post attachments in this forum

Search for:
Jump to:  
cron
© Copyright 2003-2008 www.php-editors.com. The ultimate PHP Editor and PHP IDE site.