README.md in devise_ldap_authenticatable-0.1.2 vs README.md in devise_ldap_authenticatable-0.1.3

- old
+ new

@@ -17,12 +17,16 @@ You must use the net-ldap gem and _NOT_ the ruby-net-ldap gem. Installation ------------ -script/plugin install git@github.com:cschiewek/devise\_ldap\_authenticatable.git + gem install devise_ldap_authenticatable +and + + config.gem 'devise_ldap_authenticatable' + Setup ----- Once devise\_ldap\_authenticatable is installed, all you need to do is setup the user model which includes a small addition to the model itself and to the schema. @@ -83,21 +87,39 @@ Devise.setup do |config| # Required config.ldap_host = 'ldap.mydomain.com' config.ldap_port = 389 + config.ldap_base_dn = 'ou=People,dc=local' + config.ldap_login_attribute = 'uid' # Optional, these will default to false or nil if not set config.ldap_ssl = true config.ldap_create_user = true end * ldap\_host * The host of your LDAP server + * ldap\_port - * The port your LDAP service is listening on. No default are set. + * The port your LDAP service is listening on. + +* ldap\_base_dn + * The DN that is appended to the login before the LDAP bind is performed. + +* ldap\_login_attribute + * The attribute that is prepended to the login and the base dn to form the + full DN that is used for the bind. + * Example: + * config.ldap\_base_dn = 'ou=People,dc=local' + * config.ldap\_login_attribute = 'uid' + * So when trying to login with 'admin' for example, 'admin' would be + the value stored in login field, but the actual DN used for the bind + would be 'uid=admin,ou=People,dc=local' + * ldap\_ssl * Enables SSL (ldaps) encryption. START_TLS encryption will be added when the net-ldap gem adds support for it. + * ldap\_create\_user * If set to true, all valid LDAP users will be allowed to login and an appropriate user record will be created. If set to false, you will have to create the user record before they will be allowed to login.