Gentoo Websites Logo
Go to: Gentoo Home Documentation Forums Lists Bugs Planet Store Wiki Get Gentoo!
Bug 38130 - Location /perl/*.pl does not account for files in subdirectories in commonapache2.conf
Summary: Location /perl/*.pl does not account for files in subdirectories in commonapa...
Status: RESOLVED FIXED
Alias: None
Product: Gentoo Linux
Classification: Unclassified
Component: [OLD] Server (show other bugs)
Hardware: All Linux
: High minor (vote)
Assignee: Apache Team - Bugzilla Reports
URL:
Whiteboard:
Keywords:
Depends on:
Blocks:
 
Reported: 2004-01-13 19:20 UTC by Richard Cantzler
Modified: 2004-06-03 09:24 UTC (History)
1 user (show)

See Also:
Package list:
Runtime testing required: ---


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Richard Cantzler 2004-01-13 19:20:18 UTC
The line
    <Location /perl/*.pl>
should read
    <Location ~ "^/perl/.*\.pl$">

This allows perl scripts in subdirectories to be handled by mod_perl.



Reproducible: Always
Steps to Reproduce:
1. emerge regular apache & perl
2. create a perl script in /perl/subdir/file.pl
3. attempt to run script (fails)
4. change config line as seen in Details (/perl/*.pl to ~ "^/perl/.*\.pl$")
5. attempt to run script (succeeds)

Actual Results:  
You see the source of the .pl file instead of the scripts output.


Expected Results:  
Show the scripts output.
Comment 1 SpanKY gentoo-dev 2004-01-13 20:35:11 UTC
wont ^/perl/.*\.pl$ match /perl/../some-evil.pl ?
Comment 2 Richard Cantzler 2004-01-14 12:27:33 UTC
No, ^/perl/.*\.pl$ will not match /perl/../some-evil.pl !
Apache is much to smart for this....

Give it a try.

Go to http://domain/perl/../some-evil.pl
or even http://domain/perl/../../some-evil.pl

Apache will redirect you to http://domain/some-evil.pl

Comment 3 Minati jean michel 2004-05-27 02:57:47 UTC
I tried it , this seems ok to me.
Comment 4 Chuck Short (RETIRED) gentoo-dev 2004-06-03 09:24:56 UTC
It is turned off by default, but added.

Thanks