File: apache_sitecontrol.conf

package info (click to toggle)
libapache2-sitecontrol-perl 1.05-2
  • links: PTS, VCS
  • area: main
  • in suites: bullseye, buster, forky, sid, trixie
  • size: 208 kB
  • sloc: perl: 558; makefile: 7
file content (108 lines) | stat: -rw-r--r-- 3,690 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
<Directory /home/tkay/src/site_control2/sample>
   Order allow,deny
   Allow from all
</Directory>

Alias /sample /home/tkay/src/site_control2/sample
PerlAddVar MasonCompRoot  "sample => /home/tkay/src/site_control2/sample"

PerlModule Apache2::SiteControl

# This require is not needed if you installed Apache2::SiteControl in your
# system paths
PerlRequire "/home/tkay/src/site_control2/sample/apache_modperlinit.pl"


# Directory of protected stuff...the login page should go in /sample
<Location /sample/site>
   # Set up the method of credential verification. See SimpleAuth.pm in this
   # directory, or Apache2::SiteControl for help on making your own.
   PerlSetVar SiteControlMethod SimpleAuth

   # Turn on debugging
   PerlSetVar SiteControlDebug 1

   # Configure the factories. See Apache2::SiteControl::UserFactory and
   # Apache2::SiteControl::ManagerFactory
   PerlSetVar SiteControlManagerFactory MyPermissionFactory

   # Configure the location of the session data on server disks
   PerlSetVar SiteControlSessions /tmp/sample_sessions
   PerlSetVar SiteControlLocks /tmp/sample_sessions/locks

   # Choose a name for the instance of the authenticator. This name is
   # used as part of the remaining variable names.
   PerlSetVar AuthName sample

   # Set the path that will be protected
   PerlSetVar samplePath /sample

   # Indicate the path to the login page. Be careful, HTML::Mason can 
   # interfere with proper handling...make sure you know your dependencies.
   # See samples and Apache2::AuthCookie for more information.
   PerlSetVar sampleLoginScript /sample/samplelogin.pl

   # See Apache2::AuthCookie for descriptions of these.
   PerlSetVar sampleSatisfy All
   PerlSetVar sampleDomain .uoregon.edu
   PerlSetVar sampleCache 1
   PerlSetVar sampleExpires +2h

   SetHandler perl-script
   PerlHandler HTML::Mason::ApacheHandler

   AuthType Apache2::SiteControl
   AuthName sample

   # Tell mod_perl that you want this module to control access:
   PerlAuthenHandler Apache2::SiteControl->authenticate
   PerlAuthzHandler Apache2::SiteControl->authorize

   require valid-user
</Location>

<FilesMatch "\.pl$">
   SetHandler perl-script
   PerlHandler Apache2::Registry
   Options +ExecCGI
</FilesMatch>

<Location /sample/SampleLogin>
   # Set up the method of credential verification. See SimpleAuth.pm in this
   # directory, or Apache2::SiteControl for help on making your own.
   PerlSetVar SiteControlMethod SimpleAuth

   # Turn on debugging
   PerlSetVar SiteControlDebug 1

   # Configure the factories. See Apache2::SiteControl::UserFactory and
   # Apache2::SiteControl::ManagerFactory
   PerlSetVar SiteControlManagerFactory MyPermissionFactory

   # Configure the location of the session data on server disks
   PerlSetVar SiteControlSessions /tmp/sample_sessions
   PerlSetVar SiteControlLocks /tmp/sample_sessions/locks

   # Choose a name for the instance of the authenticator. This name is
   # used as part of the remaining variable names.
   PerlSetVar AuthName sample

   # Set the path that will be protected
   PerlSetVar samplePath /sample

   # Indicate the path to the login page. Be careful, HTML::Mason can 
   # interfere with proper handling...make sure you know your dependencies.
   # See samples and Apache2::AuthCookie for more information.
   PerlSetVar sampleLoginScript /sample/samplelogin.pl

   # See Apache2::AuthCookie for descriptions of these.
   PerlSetVar sampleSatisfy All
   PerlSetVar sampleDomain .uoregon.edu
   PerlSetVar sampleCache 1
   PerlSetVar sampleExpires +2h

   AuthType Apache2::SiteControl
   AuthName sample
   SetHandler perl-script
   PerlHandler Apache2::SiteControl->login
</Location>