## CGI programs allow you to enhance the functionality of the server in a very
## straight and simple way..
##
## Documentation: /usr/share/doc/lighttpd-doc/cgi.txt
##                http://www.lighttpd.net/documentation/cgi.html

server.modules  += ( "mod_cgi" )

$HTTP["remoteip"] =~ "127.0.0.1" {
	alias.url += ( "/cgi-bin/" => "/usr/lib/cgi-bin/" )
	$HTTP["url"] =~ "^/cgi-bin/" {
		cgi.assign = ( "" => "" )
	}
}

$HTTP["url"] =~ "^/cgi-bin/" {
	cgi.assign = ( "" => "" )
}

## Warning this represents a security risk, as it allow to execute any file
## with a .pl/.php/.py even outside of /usr/lib/cgi-bin.
#
cgi.assign      = (
	".cgi" => "/usr/bin/perl"
)
#	".pl"  => "/usr/bin/perl",
#	".php" => "/usr/bin/php-cgi",
#	".py"  => "/usr/bin/python",
#)
