module Wobauth

Constants

RELEASEDATE
VERSION

Public Class Methods

ldap_options() click to toggle source
# File lib/wobauth.rb, line 40
def self.ldap_options
  return {} if @@ldap_config.blank?
  if File.readable? @@ldap_config
    config = YAML.load_file(@@ldap_config)
  end
  config ||= Hash.new

  if config['ldap_options'].present?
    ldapopts = config['ldap_options']
    if ldapopts.kind_of? Hash
      ldapopts = [ldapopts]
    end
    ldapopts.each do |opts|
      opts.symbolize_keys!
      opts.each do |k,v|
        opts[k] = opts[k].symbolize_keys if opts[k].kind_of? Hash
      end
    end
  else
    nil
  end
end
remote_authentication?() click to toggle source
# File lib/wobauth.rb, line 27
def self.remote_authentication?
  if @@remote_authentication.nil?
    @@remote_authentication = User.devise_modules.include?(:remote_user_authenticatable)
  end
  @@remote_authentication
end
setup() { |self| ... } click to toggle source
# File lib/wobauth.rb, line 5
def self.setup
  yield self
end