[ARVADOS] updated: 1.3.0-1534-g383122c1b

Git user git at public.curoverse.com
Thu Aug 22 13:26:16 UTC 2019


Summary of changes:
 services/api/app/controllers/user_sessions_controller.rb | 9 +++++++--
 1 file changed, 7 insertions(+), 2 deletions(-)

       via  383122c1bc4a08772df618a415420ac3ea527051 (commit)
      from  f676243c0372529cdaa5821d4ebe9f9f59d0cd5a (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


commit 383122c1bc4a08772df618a415420ac3ea527051
Author: Peter Amstutz <pamstutz at veritasgenetics.com>
Date:   Thu Aug 22 09:25:52 2019 -0400

    15529: Add some checks to login method
    
    Arvados-DCO-1.1-Signed-off-by: Peter Amstutz <pamstutz at veritasgenetics.com>

diff --git a/services/api/app/controllers/user_sessions_controller.rb b/services/api/app/controllers/user_sessions_controller.rb
index 8639728cc..1c5842f96 100644
--- a/services/api/app/controllers/user_sessions_controller.rb
+++ b/services/api/app/controllers/user_sessions_controller.rb
@@ -152,13 +152,18 @@ class UserSessionsController < ApplicationController
     p = []
     p << "auth_provider=#{CGI.escape(params[:auth_provider])}" if params[:auth_provider]
 
-    login_cluster = ""
-    if !Rails.configuration.Login.LoginCluster.empty?
+    if !Rails.configuration.Login.LoginCluster.empty? and Rails.configuration.Login.LoginCluster != Rails.configuration.ClusterID
       cluster = Rails.configuration.RemoteClusters[Rails.configuration.Login.LoginCluster]
+      if not cluster
+        raise "LoginCluster #{Rails.configuration.Login.LoginCluster} missing from RemoteClusters"
+      end
       scheme = "https"
       if cluster['Scheme'] and !cluster['Scheme'].empty?
         scheme = cluster['Scheme']
       end
+      if !cluster['Host'] or cluster['Host'].empty?
+        raise "LoginCluster #{Rails.configuration.Login.LoginCluster} missing 'Host' in RemoteClusters"
+      end
       login_cluster = "#{scheme}://#{cluster['Host']}"
       p << "remote=#{CGI.escape(params[:remote])}" if params[:remote]
       p << "return_to=#{CGI.escape(params[:return_to])}" if params[:return_to]

-----------------------------------------------------------------------


hooks/post-receive
-- 




More information about the arvados-commits mailing list