# Error while using LDAP for authenticate to user login

**URL:** <https://www.ruby-forum.com/t/error-while-using-ldap-for-authenticate-to-user-login/115082>\
**Category:** Rails\
**Created:** [September 20, 2007, 1:13pm UTC](https://www.ruby-forum.com/t/error-while-using-ldap-for-authenticate-to-user-login/115082 "2007-09-20T13:13:22Z")\
**Posts on this page:** 1\
**Page:** 1

<div class="post-metadata">

**Author:** ![shant](https://www.ruby-forum.com/letter_avatar_proxy/v4/letter/s/a183cd/32.png) [@shant](https://www.ruby-forum.com/u/shant)\
**Post date:** [September 20, 2007, 1:13pm UTC](https://www.ruby-forum.com/t/error-while-using-ldap-for-authenticate-to-user-login/115082/1 "2007-09-20T13:13:22Z")

</div>

Hi,

I am trying to make a simple web-application in which user should be  
authenticate by LDAP server for login.  
I am getting error while I call the bind of LDAP.  
below is my error.

Net::BER::BerError in LoginController#authenticate  
unsupported object type: class=universal, encoding=constructed, tag=28  
RAILS\_ROOT: C:/ruby/rails\_apps/ldapapp/config/…

Application Trace | Framework Trace | Full Trace  
C:/ruby/ruby/lib/ruby/gems/1.8/gems/ruby-net-ldap-0.0.4/lib/net/ber.rb:117:in  
`read_ber' C:/ruby/ruby/lib/ruby/gems/1.8/gems/ruby-net-ldap-0.0.4/lib/net/ldap.rb:1104:in`bind’  
C:/ruby/ruby/lib/ruby/gems/1.8/gems/ruby-net-ldap-0.0.4/lib/net/ldap.rb:701:in  
`bind' #{RAILS_ROOT}/lib/ldap_connect.rb:10:in`authenticate’  
#{RAILS\_ROOT}/app/controllers/login\_controller.rb:7:in `authenticate’

Thanks in advance.

Shant
