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