[LON-CAPA-cvs] cvs: loncom(version_2_11_X) /auth migrateuser.pm

raeburn raeburn at source.lon-capa.org
Thu Aug 1 11:38:36 EDT 2019


raeburn		Thu Aug  1 15:38:36 2019 EDT

  Modified files:              (Branch: version_2_11_X)
    /loncom/auth	migrateuser.pm 
  Log:
  - For 2.11
    Backport 1.35, 1.45
  
  
Index: loncom/auth/migrateuser.pm
diff -u loncom/auth/migrateuser.pm:1.25 loncom/auth/migrateuser.pm:1.25.2.1
--- loncom/auth/migrateuser.pm:1.25	Mon Dec  5 00:51:43 2016
+++ loncom/auth/migrateuser.pm	Thu Aug  1 15:38:36 2019
@@ -1,7 +1,7 @@
 # The LearningOnline Network
 # Starts a user off based of an existing token.
 #
-# $Id: migrateuser.pm,v 1.25 2016/12/05 00:51:43 raeburn Exp $
+# $Id: migrateuser.pm,v 1.25.2.1 2019/08/01 15:38:36 raeburn Exp $
 #
 # Copyright Michigan State University Board of Trustees
 #
@@ -171,6 +171,11 @@
                     }
                 }
             }
+            unless ($hosthere) {
+                if (($dataref->{'balancer'}) && ($dataref->{'balcookie'})) {
+                    &Apache::lonnet::delbalcookie($dataref->{'balcookie'},$dataref->{'balancer'});
+                }
+            }
         }
         if ($dataref->{'sso.login'}) {
             $url .= '/adm/roles';
@@ -244,6 +249,13 @@
     if ($home =~ /(con_lost|no_such_host)/) { return &goto_login($r,$udom); }
 
     my $extra_env = &sso_check(\%data);
+    if (($data{'balancer'}) && ($data{'server'}) && ($data{'balcookie'})) {
+        if (ref($extra_env) eq 'HASH') {
+            $extra_env->{'request.balancercookie'} = $data{'server'}.':'.$data{'balcookie'};
+        } else {
+            $extra_env = { 'request.balancercookie' => $data{'server'}.':'.$data{'balcookie'} };
+        }
+    }
 
     my %form;
     if ($data{'symb'} ne '') {




More information about the LON-CAPA-cvs mailing list