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