This repository has been archived on 2024-03-16. You can view files and clone it, but cannot push or open issues or pull requests.
orbit-4-1/config/initializers/rulingcom_ldap.rb

19 lines
464 B
Ruby
Raw Permalink Normal View History

2012-02-22 06:43:24 +00:00
# Warden::Strategies.add(:check_nccu_ldap) do
# def valid?
# # code here to check whether to try and authenticate using this strategy;
# params['nccu_ldap_uid'] && params['password']
# end
# def authenticate!
# debugger
# user = User.first(conditions:{ nccu_ldap_uid: "901001" })
# if user
# success! user
# else
# success! User.create
#
# # fail!(message)
# # User.create
# end
# end
#
# end