i am new to ruby .....
in java my ldap server is connecting like
···
--------------------------------------------
username="myname"
password="*********"
LDAPConnection ld = new LDAPConnection();
ld.connect( "192.168.1.1", 389);
con=ld.authenticate
("uid="+username+",ou=People,dc=mydomain,dc=com",password);
/// con--->true
but in ruby
-----------------------------------
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.....
--
Posted via http://www.ruby-forum.com/.
Try giving the whole DN as the user name.
···
On 10/8/07, Pokkai Dokkai <bad_good_lion@yahoo.com> wrote:
i am new to ruby .....
in java my ldap server is connecting like
--------------------------------------------
username="myname"
password="*********"
LDAPConnection ld = new LDAPConnection();
ld.connect( "192.168.1.1", 389);
con=ld.authenticate
("uid="+username+",ou=People,dc=mydomain,dc=com",password);
/// con--->true
but in ruby
-----------------------------------
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.....
--
Posted via http://www.ruby-forum.com/\.
Francis Cianfrocca wrote:
Try giving the whole DN as the user name.
sorry i did't get you....
can you show a sample (how to give the whole DN as the user name )
thank you
···
--
Posted via http://www.ruby-forum.com/\.
It's in your own example:
uid=username,ou=People,dc=mydomain,dc=com
···
On 10/8/07, Pokkai Dokkai <bad_good_lion@yahoo.com> wrote:
Francis Cianfrocca wrote:
> Try giving the whole DN as the user name.
sorry i did't get you....
can you show a sample (how to give the whole DN as the user name )
Francis Cianfrocca wrote:
uid=username,ou=People,dc=mydomain,dc=com
not fine
same error....
···
--
Posted via http://www.ruby-forum.com/\.