[LON-CAPA-cvs] cvs: loncom /auth lonacc.pm

raeburn raeburn at source.lon-capa.org
Tue Dec 22 17:23:37 EST 2020


raeburn		Tue Dec 22 22:23:37 2020 EDT

  Modified files:              
    /loncom/auth	lonacc.pm 
  Log:
  - Modify changes in rev 1.180. Set of URLs for which symb is checked is not 
    completely contained within set of URLs for which access is checked.
  
  
Index: loncom/auth/lonacc.pm
diff -u loncom/auth/lonacc.pm:1.184 loncom/auth/lonacc.pm:1.185
--- loncom/auth/lonacc.pm:1.184	Fri Dec 18 15:23:03 2020
+++ loncom/auth/lonacc.pm	Tue Dec 22 22:23:37 2020
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Cookie Based Access Handler
 #
-# $Id: lonacc.pm,v 1.184 2020/12/18 15:23:03 raeburn Exp $
+# $Id: lonacc.pm,v 1.185 2020/12/22 22:23:37 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -616,24 +616,27 @@
         }
 # ---------------------------------------------------------------- Check access
 	my $now = time;
-        my $check_symb;
+        my ($check_symb,$check_access);
 	if ($requrl !~ m{^/(?:adm|public|(?:prt|zip)spool)/}
 	    || $requrl =~ /^\/adm\/.*\/(smppg|bulletinboard)(\?|$ )/x) {
-            my ($access,$poss_symb);
-            if (($env{'request.course.id'}) && (!$suppext)) {
-                $requrl=~/\.(\w+)$/;
-                if ((&Apache::loncommon::fileembstyle($1) eq 'ssi') ||
-                    ($requrl=~/^\/adm\/.*\/(aboutme|smppg|bulletinboard)(\?|$ )/x) ||
-                    ($requrl=~/^\/adm\/wrapper\//) ||
-                    ($requrl=~m|^/adm/coursedocs/showdoc/|) ||
-                    ($requrl=~m|\.problem/smpedit$|) ||
-                    ($requrl=~/^\/public\/.*\/syllabus$/) ||
-                    ($requrl=~/^\/adm\/(viewclasslist|navmaps)$/) ||
-                    ($requrl=~/^\/adm\/.*\/aboutme\/portfolio(\?|$)/) ||
-                    ($requrl=~m{^/adm/$cdom/$cnum/\d+/ext\.tool$})) {
-                    $check_symb = 1;
-                }
+            $check_access = 1;
+        }
+        if (($env{'request.course.id'}) && (!$suppext)) {
+            $requrl=~/\.(\w+)$/;
+            if ((&Apache::loncommon::fileembstyle($1) eq 'ssi') ||
+                ($requrl=~/^\/adm\/.*\/(aboutme|smppg|bulletinboard)(\?|$ )/x) ||
+                ($requrl=~/^\/adm\/wrapper\//) ||
+                ($requrl=~m|^/adm/coursedocs/showdoc/|) ||
+                ($requrl=~m|\.problem/smpedit$|) ||
+                ($requrl=~/^\/public\/.*\/syllabus$/) ||
+                ($requrl=~/^\/adm\/(viewclasslist|navmaps)$/) ||
+                ($requrl=~/^\/adm\/.*\/aboutme\/portfolio(\?|$)/) ||
+                ($requrl=~m{^/adm/$cdom/$cnum/\d+/ext\.tool$})) {
+                $check_symb = 1;
             }
+        }
+        if ($check_access) {
+            my ($access,$poss_symb);
             if ($check_symb) {
                 if ($env{'form.symb'}) {
                     $poss_symb=&Apache::lonnet::symbclean($env{'form.symb'});




More information about the LON-CAPA-cvs mailing list