[tests] test coverage for issues (#321, #322)
[lighttpd.git] / tests / fastcgi-auth.conf
blob61b35407a1476c9d213a792233a1d03d6359c38d
1 server.document-root         = env.SRCDIR + "/tmp/lighttpd/servers/www.example.org/pages/"
3 debug.log-request-header   = "enable"
4 debug.log-response-header  = "enable"
5 debug.log-request-handling = "enable"
7 ## bind to port (default: 80)
8 server.port                 = 2048
10 ## bind to localhost (default: all interfaces)
11 server.bind                = "localhost"
12 server.errorlog            = env.SRCDIR + "/tmp/lighttpd/logs/lighttpd.error.log"
13 server.breakagelog         = env.SRCDIR + "/tmp/lighttpd/logs/lighttpd.breakage.log"
14 server.name                = "www.example.org"
15 server.tag                 = "Apache 1.3.29"
17 server.dir-listing          = "enable"
19 server.modules = (
20         "mod_rewrite",
21         "mod_access",
22         "mod_auth",
23         "mod_status",
24         "mod_expire",
25         "mod_redirect",
26         "mod_fastcgi",
27         "mod_cgi",
28         "mod_compress",
29         "mod_accesslog",
32 server.indexfiles = (
33         "index.php",
34         "index.html",
35         "index.htm",
36         "default.htm",
39 ######################## MODULE CONFIG ############################
42 accesslog.filename = env.SRCDIR + "/tmp/lighttpd/logs/lighttpd.access.log"
44 mimetype.assign = (
45         ".png"  => "image/png",
46         ".jpg"  => "image/jpeg",
47         ".jpeg" => "image/jpeg",
48         ".gif"  => "image/gif",
49         ".html" => "text/html",
50         ".htm"  => "text/html",
51         ".pdf"  => "application/pdf",
52         ".swf"  => "application/x-shockwave-flash",
53         ".spl"  => "application/futuresplash",
54         ".txt"  => "text/plain",
55         ".tar.gz" =>   "application/x-tgz",
56         ".tgz"  => "application/x-tgz",
57         ".gz"   => "application/x-gzip",
58         ".c"    => "text/plain",
59         ".conf" => "text/plain",
62 compress.cache-dir = env.SRCDIR + "/tmp/lighttpd/cache/compress/"
63 compress.filetype = (
64         "text/plain",
65         "text/html",
68 fastcgi.debug = 0
69 fastcgi.server = (
70         "/" => (
71                 "grisu" => (
72                         "host" => "127.0.0.1",
73                         "port" => 20000,
74                         "bin-path" => env.SRCDIR + "/fcgi-auth",
75                         "mode" => "authorizer",
76                         "check-local" => "disable",
77                 ),
78         ),
79         ".fcgi" => (
80                 "grisu2" => (
81                         "host" => "127.0.0.1",
82                         "port" => 10000,
83                         "bin-path" => env.SRCDIR + "/fcgi-responder",
84                         "check-local" => "disable",
85                         "max-procs" => 1,
86                 ),
87         ),
90 cgi.assign = (
91         ".pl"  => env.PERL,
92         ".cgi" => env.PERL,
95 auth.backend = "plain"
96 auth.backend.plain.userfile = env.SRCDIR + "/tmp/lighttpd/lighttpd.user"
97 auth.backend.plain.groupfile = "lighttpd.group"
99 auth.backend.ldap.hostname  = "localhost"
100 auth.backend.ldap.base-dn   = "dc=my-domain,dc=com"
101 auth.backend.ldap.filter    = "(uid=$)"
103 auth.require = (
104         "/server-status" => (
105                 "method"  => "digest",
106                 "realm"   => "download archiv",
107                 "require" => "group=www|user=jan|host=192.168.2.10",
108         ),
109         "/auth.php" => (
110                 "method"  => "basic",
111                 "realm"   => "download archiv",
112                 "require" => "user=jan",
113         ),
114         "/server-config" => (
115                 "method"  => "basic",
116                 "realm"   => "download archiv",
117                 "require" => "group=www|user=jan|host=192.168.2.10",
118         ),
121 url.access-deny = (
122         "~",
123         ".inc",
126 url.redirect = (
127         "^/redirect/$" => "http://localhost:2048/",
130 expire.url = (
131         "/buggy/" => "access 2 hours",
132         "/asdhas/" => "access plus 1 seconds 2 minutes",
136 #### status module
137 status.status-url = "/server-status"
138 status.config-url = "/server-config"
140 $HTTP["host"] == "vvv.example.org" {
141         server.document-root = env.SRCDIR + "/tmp/lighttpd/servers/www.example.org/pages/"
144 $HTTP["host"] == "zzz.example.org" {
145         server.document-root = env.SRCDIR + "/tmp/lighttpd/servers/www.example.org/pages/"
146         server.name = "zzz.example.org"