LDAP bind error

i am new to rails …

in java ldap server is connecting without problem

username=""
password=""
LDAPConnection ld = new LDAPConnection();
ld.connect( “192.168.1.1”, 389);
con=ld.authenticate (
“uid=”+username+",ou=People,dc=srishtisoft,dc=com",password);

/// con—>true

but in rails

  ldap_con = Net::LDAP.new({:host => '192.168.1.1',
                            :port => 389,
                            :auth=>
                               {
                                :method=>:simple,
                                :username => username,
                                :password => password
                               }
                            })
 @con=ldap_con.bind

#@con —>false (always )

what is wrong here
any help please…

This forum is not affiliated to the Ruby language, Ruby on Rails framework, nor any Ruby applications discussed here.

| Privacy Policy | Terms of Service | Remote Ruby Jobs