diff --git a/config/initializers/omniauth.rb b/config/initializers/omniauth.rb index 3ce3796e..b08cd1ea 100644 --- a/config/initializers/omniauth.rb +++ b/config/initializers/omniauth.rb @@ -13,7 +13,7 @@ Rails.application.config.middleware.use OmniAuth::Builder do provider :ldap, host: ENV['LDAP_SERVER'], port: ENV['LDAP_PORT'], - method: :plain, + method: ENV['LDAP_METHOD'].present? ? ENV['LDAP_METHOD'].to_sym : :plain, allow_username_or_email_login: true, uid: ENV['LDAP_UID'], base: ENV['LDAP_BASE'], diff --git a/env b/env index a66471a4..935e3456 100644 --- a/env +++ b/env @@ -38,12 +38,13 @@ GOOGLE_OAUTH2_SECRET= # LDAP Login Provider (optional) # -# You can enable LDAP authentication by providing values for LDAP_SERVER and LDAP_PORT. +# You can enable LDAP authentication by providing values for the variables below. # For information about setting up LDAP, see: # http://docs.bigbluebutton.org/install/green-light.html#ldap-oauth # LDAP_SERVER= LDAP_PORT= +LDAP_METHOD= LDAP_UID= LDAP_BASE= LDAP_BIND_DN=