Annotation of loncom/loncapa_apache.conf, revision 1.11
1.1 harris41 1: ##
2: ## loncapa_apache.conf -- Apache HTTP LON-CAPA configuration file
3: ##
1.11 ! www 4: ## $Id: loncapa_apache.conf,v 1.10 2002/07/24 20:25:23 www Exp $
1.1 harris41 5: ##
6: ## 1/11/2002 - Scott Harrison
7: ## 2/19/2002 - Scott Harrison
8: ## 2/28/2002 - Scott Harrison
9: ## 3/2/2002 - Scott Harrison
10: ## 5/12/2002 - Scott Harrison
11:
12: #
13: # LON-CAPA Section (extensions to httpd.conf daemon configuration)
14: #
1.8 harris41 15: # ================================================================ DocumentRoot
1.1 harris41 16:
17: DocumentRoot "/home/httpd/html"
18:
19: # ======================================================================== User
20:
21: User www
22: Group www
23:
24: # ======================================================= Shared Object Modules
25:
26: LoadModule perl_module modules/libperl.so
27: AddModule mod_perl.c
28:
29: # =============================================================== Miscellaneous
30:
31: ServerAdmin korte@lite.msu.edu
32: ExtendedStatus On
33:
34: #
35: # LON-CAPA Section (extensions to srm.conf name space servicing)
36: #
37: # ===================================================================== Aliases
38:
39: Alias /prtspool/ /home/httpd/prtspool/
1.8 harris41 40: ScriptAlias /cgi-bin/ "/home/httpd/cgi-bin/"
1.1 harris41 41:
42: # ================================================================= Directories
43:
44: # ------------------------------------------------------------- Access Handlers
45:
46: <LocationMatch "^/res.*">
47: PerlAccessHandler Apache::lonacc
48: PerlHeaderParserHandler Apache::lonrep
49: ErrorDocument 403 /adm/login
50: ErrorDocument 404 /adm/notfound.html
51: ErrorDocument 406 /adm/roles
1.11 ! www 52: ErrorDocument 500 /adm/errorhandler
! 53: </LocationMatch>
! 54:
! 55: <LocationMatch "^/userfiles.*">
! 56: PerlAccessHandler Apache::lontokacc
! 57: ErrorDocument 404 /adm/notfound.html
1.1 harris41 58: ErrorDocument 500 /adm/errorhandler
59: </LocationMatch>
60:
61: <LocationMatch "^/priv.*">
62: PerlAccessHandler Apache::loncacc
63: SetHandler perl-script
64: PerlHandler Apache::lonconstruct
65: ErrorDocument 403 /adm/login
66: ErrorDocument 404 /adm/notfound.html
67: ErrorDocument 406 /adm/unauthorized.html
68: ErrorDocument 500 /adm/errorhandler
69: </LocationMatch>
70:
71: <LocationMatch "^/raw.*">
72: PerlAccessHandler Apache::lonracc
73: </LocationMatch>
74:
75: <LocationMatch "^/\~.*">
76: PerlAccessHandler Apache::loncacc
77: ErrorDocument 403 /adm/login
78: ErrorDocument 404 /adm/notfound.html
79: ErrorDocument 406 /adm/unauthorized.html
80: ErrorDocument 500 /adm/errorhandler
81: AllowOverride None
82: </LocationMatch>
83:
84: # ------------------------------------------------------------------------- RAT
85:
86: <LocationMatch "^/\~.*\.sequence$">
87: SetHandler perl-script
88: PerlHandler Apache::lonratedt
89: </LocationMatch>
90:
91: <LocationMatch "^/\~.*\.page$">
92: SetHandler perl-script
93: PerlHandler Apache::lonratedt
94: </LocationMatch>
95:
96: <LocationMatch "^/\~.*\/ratserver$">
97: SetHandler perl-script
98: PerlHandler Apache::lonratsrv
99: </LocationMatch>
100:
101: <Location /adm/ratparms>
102: PerlAccessHandler Apache::lonacc
103: SetHandler perl-script
104: PerlHandler Apache::lonratparms
105: ErrorDocument 403 /adm/login
106: ErrorDocument 500 /adm/errorhandler
107: </Location>
108:
109: # --------------------------------------------- Resource Space Content Handlers
110:
111: <LocationMatch "^/res.*/$">
112: SetHandler perl-script
113: PerlHandler Apache::lonindexer
114: </LocationMatch>
115:
116: <LocationMatch "^/(res|\~).*\.tex$">
117: SetHandler perl-script
118: PerlHandler Apache::lontex
119: </LocationMatch>
120:
121: <LocationMatch "^/res/.*\.page$>
122: SetHandler perl-script
123: PerlHandler Apache::lonpage
124: </LocationMatch>
125:
126: <LocationMatch "^/res/.*\.sequence$>
127: SetHandler perl-script
128: PerlHandler Apache::lonsequence
129: </LocationMatch>
130:
1.8 harris41 131: <LocationMatch "^/(res|\~).*\.meta$>
1.1 harris41 132: SetHandler perl-script
133: PerlHandler Apache::lonmeta
134: </LocationMatch>
135:
136: <LocationMatch "^/(res|\~).*\.(xml|html|htm|xhtml|xhtm)$">
137: SetHandler perl-script
138: PerlHandler Apache::lonxml
139: </LocationMatch>
140:
141: <LocationMatch "^/(res|\~).*\.(problem|exam|quiz|assess|survey|form|library)$">
142: SetHandler perl-script
143: PerlHandler Apache::lonhomework
144: </LocationMatch>
145:
146: <LocationMatch "^/adm/wrapper/">
147: PerlAccessHandler Apache::lonacc
148: SetHandler perl-script
149: PerlHandler Apache::lonwrapper
150: ErrorDocument 403 /adm/login
151: ErrorDocument 500 /adm/errorhandler
152: </LocationMatch>
153:
154: # -------------------------------------------------------------- Admin Programs
155:
156: <Location /adm/statistics>
157: PerlAccessHandler Apache::lonacc
158: SetHandler perl-script
159: PerlHandler Apache::lonstatistics
160: ErrorDocument 403 /adm/login
161: ErrorDocument 500 /adm/errorhandler
162: </Location>
163:
164: <Location /adm/roles>
165: PerlAccessHandler Apache::lonacc
166: SetHandler perl-script
167: PerlHandler Apache::lonroles
168: ErrorDocument 403 /adm/login
169: ErrorDocument 500 /adm/errorhandler
170: </Location>
171:
172: <Location /adm/login>
173: SetHandler perl-script
174: PerlHandler Apache::lonlogin
175: </Location>
176:
177: <Location /adm/logout>
178: PerlAccessHandler Apache::lonacc
179: SetHandler perl-script
180: PerlHandler Apache::lonlogout
181: ErrorDocument 403 /adm/login
182: </Location>
183:
184: <Location /adm/authenticate>
185: SetHandler perl-script
186: PerlHandler Apache::lonauth
187: </Location>
188:
189: <Location /adm/annotations>
190: PerlAccessHandler Apache::lonacc
191: SetHandler perl-script
192: PerlHandler Apache::admannotations
193: ErrorDocument 403 /adm/login
194: ErrorDocument 500 /adm/errorhandler
195: </Location>
196:
197: <Location /adm/bookmarks>
198: PerlAccessHandler Apache::lonacc
199: SetHandler perl-script
200: PerlHandler Apache::admbookmarks
201: ErrorDocument 403 /adm/login
202: ErrorDocument 500 /adm/errorhandler
203: </Location>
204:
205: <Location /adm/flip>
206: PerlAccessHandler Apache::lonacc
207: SetHandler perl-script
208: PerlHandler Apache::lonpageflip
209: ErrorDocument 406 /adm/roles
210: ErrorDocument 403 /adm/login
211: ErrorDocument 500 /adm/errorhandler
212: </Location>
213:
214: <Location /adm/ambiguous>
215: PerlAccessHandler Apache::lonacc
216: SetHandler perl-script
217: PerlHandler Apache::lonambiguous
218: ErrorDocument 403 /adm/login
219: ErrorDocument 500 /adm/errorhandler
220: </Location>
221:
222: <Location /adm/email>
223: PerlAccessHandler Apache::lonacc
224: SetHandler perl-script
225: PerlHandler Apache::lonmsg
226: ErrorDocument 403 /adm/login
227: ErrorDocument 500 /adm/errorhandler
228: </Location>
229:
230: <Location /adm/parmset>
231: PerlAccessHandler Apache::lonacc
232: SetHandler perl-script
233: PerlHandler Apache::lonparmset
234: ErrorDocument 403 /adm/login
235: ErrorDocument 406 /adm/roles
236: ErrorDocument 500 /adm/errorhandler
237: </Location>
238:
239: <Location /adm/grades>
240: PerlAccessHandler Apache::lonacc
241: SetHandler perl-script
242: PerlHandler Apache::grades
243: ErrorDocument 403 /adm/login
244: ErrorDocument 406 /adm/roles
245: ErrorDocument 500 /adm/errorhandler
246: </Location>
247:
248: <Location /adm/createcourse>
249: PerlAccessHandler Apache::lonacc
250: SetHandler perl-script
251: PerlHandler Apache::loncreatecourse
252: ErrorDocument 403 /adm/login
253: ErrorDocument 406 /adm/roles
254: ErrorDocument 500 /adm/errorhandler
255: </Location>
256:
257: <Location /adm/createuser>
258: PerlAccessHandler Apache::lonacc
259: SetHandler perl-script
260: PerlHandler Apache::loncreateuser
261: ErrorDocument 403 /adm/login
262: ErrorDocument 406 /adm/roles
263: ErrorDocument 500 /adm/errorhandler
264: </Location>
265:
266: <Location /adm/publish>
267: PerlAccessHandler Apache::lonacc
268: SetHandler perl-script
269: PerlHandler Apache::lonpublisher
270: ErrorDocument 403 /adm/login
271: ErrorDocument 404 /adm/notfound.html
272: ErrorDocument 406 /adm/unauthorized.html
273: ErrorDocument 500 /adm/errorhandler
274: </Location>
275:
276: <LocationMatch "^/\~.*/$">
277: PerlAccessHandler Apache::loncacc
278: SetHandler perl-script
279: PerlHandler Apache::lonpubdir
280: ErrorDocument 403 /adm/login
281: ErrorDocument 404 /adm/notfound.html
282: ErrorDocument 406 /adm/unauthorized.html
283: ErrorDocument 500 /adm/errorhandler
284: </LocationMatch>
285:
286: <Location /adm/pubdir>
287: PerlAccessHandler Apache::lonacc
288: SetHandler perl-script
289: PerlHandler Apache::lonpubdir
290: ErrorDocument 403 /adm/login
291: ErrorDocument 404 /adm/notfound.html
292: ErrorDocument 406 /adm/unauthorized.html
293: ErrorDocument 500 /adm/errorhandler
294: </Location>
295:
296: <Location /adm/retrieve>
297: PerlAccessHandler Apache::lonacc
298: SetHandler perl-script
299: PerlHandler Apache::lonretrieve
300: ErrorDocument 403 /adm/login
301: ErrorDocument 404 /adm/notfound.html
302: ErrorDocument 406 /adm/unauthorized.html
303: ErrorDocument 500 /adm/errorhandler
304: </Location>
305:
306: <Location /adm/cfile>
307: PerlAccessHandler Apache::lonacc
308: SetHandler perl-script
309: PerlHandler Apache::loncfile
310: ErrorDocument 403 /adm/login
311: ErrorDocument 404 /adm/notfound.html
312: ErrorDocument 406 /adm/unauthorized.html
313: ErrorDocument 500 /adm/errorhandler
314: </Location>
315:
316: <Location /adm/diff>
317: PerlAccessHandler Apache::lonacc
318: SetHandler perl-script
319: PerlHandler Apache::londiff
320: ErrorDocument 403 /adm/login
321: ErrorDocument 404 /adm/notfound.html
322: ErrorDocument 406 /adm/unauthorized.html
323: ErrorDocument 500 /adm/errorhandler
324: </Location>
325:
326: <Location /adm/upload>
327: PerlAccessHandler Apache::lonacc
328: SetHandler perl-script
329: PerlHandler Apache::lonupload
330: ErrorDocument 403 /adm/login
331: ErrorDocument 404 /adm/notfound.html
332: ErrorDocument 406 /adm/unauthorized.html
333: ErrorDocument 500 /adm/errorhandler
334: </Location>
335:
336: <Location /adm/assesscalc>
337: PerlAccessHandler Apache::lonacc
338: SetHandler perl-script
339: PerlHandler Apache::lonspreadsheet
340: ErrorDocument 403 /adm/login
341: ErrorDocument 406 /adm/roles
342: ErrorDocument 500 /adm/errorhandler
343: </Location>
344:
345: <Location /adm/studentcalc>
346: PerlAccessHandler Apache::lonacc
347: SetHandler perl-script
348: PerlHandler Apache::lonspreadsheet
349: ErrorDocument 403 /adm/login
350: ErrorDocument 406 /adm/roles
351: ErrorDocument 500 /adm/errorhandler
352: </Location>
353:
354: <Location /adm/classcalc>
355: PerlAccessHandler Apache::lonacc
356: SetHandler perl-script
357: PerlHandler Apache::lonspreadsheet
358: ErrorDocument 403 /adm/login
359: ErrorDocument 406 /adm/roles
360: ErrorDocument 500 /adm/errorhandler
361: </Location>
362:
363: <Location /adm/dropadd>
364: PerlAccessHandler Apache::lonacc
365: SetHandler perl-script
366: PerlHandler Apache::londropadd
367: ErrorDocument 403 /adm/login
368: ErrorDocument 406 /adm/roles
369: ErrorDocument 500 /adm/errorhandler
370: </Location>
371:
372: <Location /adm/printout>
373: PerlAccessHandler Apache::lonacc
374: SetHandler perl-script
375: PerlHandler Apache::lonprintout
376: ErrorDocument 403 /adm/login
377: ErrorDocument 500 /adm/errorhandler
378: </Location>
379:
380: <Location /adm/feedback>
381: PerlAccessHandler Apache::lonacc
382: SetHandler perl-script
383: PerlHandler Apache::lonfeedback
1.10 www 384: ErrorDocument 403 /adm/login
385: ErrorDocument 500 /adm/errorhandler
386: </Location>
387:
388: <Location /adm/coursedocs>
389: PerlAccessHandler Apache::lonacc
390: SetHandler perl-script
391: PerlHandler Apache::londocs
392: ErrorDocument 403 /adm/login
393: ErrorDocument 500 /adm/errorhandler
394: </Location>
395:
396: <Location /adm/announcements>
397: PerlAccessHandler Apache::lonacc
398: SetHandler perl-script
399: PerlHandler Apache::lonannounce
400: ErrorDocument 403 /adm/login
401: ErrorDocument 500 /adm/errorhandler
402: </Location>
403:
404: <Location /adm/chat>
405: PerlAccessHandler Apache::lonacc
406: SetHandler perl-script
407: PerlHandler Apache::lonchat
1.1 harris41 408: ErrorDocument 403 /adm/login
409: ErrorDocument 500 /adm/errorhandler
410: </Location>
411:
412: <Location /adm/evaluate>
413: PerlAccessHandler Apache::lonacc
414: SetHandler perl-script
415: PerlHandler Apache::lonevaluate
416: ErrorDocument 403 /adm/login
417: ErrorDocument 500 /adm/errorhandler
418: </Location>
419:
420: <Location /adm/preferences>
421: PerlAccessHandler Apache::lonacc
422: SetHandler perl-script
423: PerlHandler Apache::lonpreferences
424: ErrorDocument 403 /adm/login
425: ErrorDocument 500 /adm/errorhandler
426: </Location>
427:
428: <Location /adm/assignments>
429: PerlAccessHandler Apache::lonacc
430: SetHandler perl-script
431: PerlHandler Apache::lonassignments
432: ErrorDocument 403 /adm/login
433: ErrorDocument 406 /adm/roles
434: ErrorDocument 500 /adm/errorhandler
435: </Location>
436:
437: <Location /adm/communicate>
438: PerlAccessHandler Apache::lonacc
439: SetHandler perl-script
440: PerlHandler Apache::loncommunicate
441: ErrorDocument 403 /adm/login
442: ErrorDocument 500 /adm/errorhandler
443: </Location>
444:
445: <Location /adm/searchcat>
446: PerlAccessHandler Apache::lonacc
447: SetHandler perl-script
448: PerlHandler Apache::lonsearchcat
449: ErrorDocument 403 /adm/login
450: ErrorDocument 500 /adm/errorhandler
451: </Location>
452:
453: <Location /adm/navmaps>
454: PerlAccessHandler Apache::lonacc
455: SetHandler perl-script
456: PerlHandler Apache::lonnavmaps
457: ErrorDocument 403 /adm/login
458: ErrorDocument 406 /adm/roles
459: ErrorDocument 500 /adm/errorhandler
460: </Location>
461:
462: <Location /adm/groupsort>
463: PerlAccessHandler Apache::lonacc
464: SetHandler perl-script
465: PerlHandler Apache::groupsort
466: ErrorDocument 403 /adm/login
467: ErrorDocument 500 /adm/errorhandler
468: </Location>
469:
470: <Location /adm/errorhandler>
471: SetHandler perl-script
472: PerlHandler Apache::lonerrorhandler
473: </Location>
474:
1.7 bowersj2 475: <LocationMatch "^/adm/help/.*\.hlp$">
476: SetHandler perl-script
477: PerlHandler Apache::lonhelp
478: </LocationMatch>
479:
1.1 harris41 480: # ------------------------------------------------- Backdoor Adm Tests/Programs
481:
482: <Location /cgi-bin/loncron.pl>
483: AuthName "LON-CAPA Network Administration"
484: AuthType Basic
485: AuthUserFile /home/httpd/lonTabs/htpasswd
486: require user lonadm
487: </Location>
488:
489: <Location /cgi-bin/lonversions.pl>
490: AuthName "LON-CAPA Network Administration"
491: AuthType Basic
492: AuthUserFile /home/httpd/lonTabs/htpasswd
493: require user lonadm
494: </Location>
495:
496: <Location /cgi-bin/clusterstatus.pl>
497: AuthName "LON-CAPA Network Administration"
498: AuthType Basic
499: AuthUserFile /home/httpd/lonTabs/htpasswd
500: require user lonadm
501: </Location>
502:
503: <Location /cgi-bin/metadata_keywords.pl>
504: AuthName "LON-CAPA Network Administration"
505: AuthType Basic
506: AuthUserFile /home/httpd/lonTabs/htpasswd
507: require user lonadm
508: </Location>
509:
510: <Location /adm/test>
511: AuthName "LON-CAPA Network Administration"
512: AuthType Basic
513: AuthUserFile /home/httpd/lonTabs/htpasswd
514: require user lonadm
515: SetHandler perl-script
516: PerlAccessHandler Apache::lonacc
517: PerlHandler Apache::lontest
518: </Location>
519:
520: # ------------------------------------------------------- Shutting down a child
521:
522: PerlChildExitHandler Apache::lonnet::goodbye
523:
524: #
525: # LON-CAPA Section (extensions to access.conf permission configuration)
526: #
527: # =========================================================== Directory Options
528:
529: # Start out with "no"
530:
531: <Directory />
532: Options None
533: AllowOverride None
534: </Directory>
535:
536: # Yes to symbolic links and server-side includes
537:
538: <Directory /home/httpd/html>
539: Options Includes FollowSymLinks
540: AllowOverride None
541: order allow,deny
542: allow from all
543: </Directory>
544:
545: # If it is in cgi-bin, then it can be executed as a CGI script.
546:
547: <Directory /home/httpd/cgi-bin>
548: AllowOverride None
549: Options ExecCGI
550: </Directory>
551:
552: # ============================================================= Access Handlers
553:
554: # ------------------------------------------------- Allow server-status reports
555: <Location /server-status>
556: SetHandler server-status
557: AuthName "LON-CAPA Network Administration"
558: AuthType Basic
559: AuthUserFile /home/httpd/lonTabs/htpasswd
560: require user lonadm
561: </Location>
562:
563: # ------------------------ Allow LON-CAPA "low-level" connection status reports
564: <Location /lon-status>
565: AuthName "LON-CAPA Network Administration"
566: AuthType Basic
567: AuthUserFile /home/httpd/lonTabs/htpasswd
568: require user lonadm
569: </Location>
570:
571: # ------------------- Allow access to local system documentation from localhost
572: Alias /doc /usr/doc
573: <Directory /usr/doc>
574: order deny,allow
575: deny from all
576: allow from localhost
577: Options Indexes FollowSymLinks
578: </Directory>
579:
580: # ******** THESE "SHOULD" NEVER BE ALTERED BY THE USER ************************
581: # ====================================== Internal Settings / Perl Configuration
582:
583: PerlSetVar lonIDsDir /home/httpd/lonIDs
584: PerlSetVar lonTabDir /home/httpd/lonTabs
585: PerlSetVar lonUsersDir /home/httpd/lonUsers
586: PerlSetVar lonIconsURL /adm/lonIcons
587: PerlSetVar londPort 5663
588: PerlSetVar lonSysEMail korte@lite.msu.edu
589: PerlSetVar lonDaemons /home/httpd/perl
590: PerlSetVar lonSockDir /home/httpd/sockets
591: PerlSetVar lonDocRoot /home/httpd/html
592: PerlSetVar lonIncludes /home/httpd/html/res/adm/includes
593: PerlSetVar lonBrowsDet netscape:mozilla:msie:mozilla\/(\d+\.\d+)\s:9999&explorer:msie:netscape:msie\s(\d+\.\d+)\;:9999&mozilla:mozilla\/[5-9]:msie:mozilla\/(\d+\.\d+)\s:9999&amaya:amaya:mozilla:V(\d+\.\d+)\s:1
1.2 harris41 594:
595: # -----------------------------------------------------------------------------
596: # NOTE: lonSqlAccess key is the password for the MySQL user
597: # www@localhost. This value must always be "localhostkey".
598: # The only security risk occurs when somebody logs in as 'www' on your system
599: # (in which case you have much bigger problems than whether or not they
600: # can access the non-authoritative loncapa database on your machine).
601:
602: PerlSetVar lonSqlAccess localhostkey
603:
604: # -----------------------------------------------------------------------------
605:
606:
1.8 harris41 607: # ====================================== Include machine-specific configuration
1.2 harris41 608:
609: Include conf/loncapa.conf
1.1 harris41 610:
611: # ================================================== Initiate mod_perl starting
612:
613: PerlRequire conf/startup.pl
614: PerlFreshRestart On
FreeBSD-CVSweb <freebsd-cvsweb@FreeBSD.org>