Project

General

Profile

Actions

Feature #28

closed

Feature Request: Constrain CGIs in Specified Directory

Added by Anonymous about 19 years ago. Updated about 17 years ago.

Status:
Fixed
Priority:
Normal
Category:
mod_cgi
Target version:
ASK QUESTIONS IN Forums:

Description

The current configuration of CGIs,


    cgi.assign = ( ".pl"  => "/usr/bin/perl",
                   ".sh"  => "/bin/sh" )

takes every thing with extension *.sh or *.pl as CGIs. But this is not safe on
a site which allows users to upload files. Can we instead use Regular Expressions
in this configuration?


    cgi.assign = ( "^/cgi-bin/*.pl"  => "/usr/bin/perl",
                   "^/cgi-bin/*.sh"  => "/bin/sh" )

or, without Regular Expression, add a new configuration line like


cgi.constrain = ("/cgi-bin/", "/othercgi-bin/")

Thanks a lot

-- yasheng

Actions #1

Updated by jan about 19 years ago

  • Status changed from New to Assigned

$HTTPurl =~ "^/cgi-bin/" {
cgi.assign = ( ".pl" => "/usr/bin/perl" )
}

already does that. To do this inside of a virtual server you have to wait for nested conditionals.

Actions

Also available in: Atom