Questions tagged [netldap]
43 questions
7
votes
1 answer
How do I modify a Boolean LDAP Active Directory attribute using Net::LDAP?
I can successfully bind to AD LDAP, and modify and create objects.
However, if I want to update or set an attribute of type 'Boolean', then I get this error:
00000057: LdapErr: DSID-0C090C3E, comment: Error in attribute conversion operation, data…

Steve Shipway
- 3,754
- 3
- 22
- 39
4
votes
1 answer
Loading users from Active Directory into a Rails 3.1 Active Record database
Update 11/30/11
I made some changes in the code snippet where I found errors. I am now successfully authenticating for sure, but am getting this error after attempting the ldap.search call:
Using…

jgifford78
- 51
- 4
4
votes
2 answers
net-ldap create user with password
I am trying to create an AD account with a password already set using the net-ldap gem. I am able to connect to the server fine. And I am also able to add a new user without passing the :unicodepwd attribute however when the new user is created…

user3831214
- 891
- 1
- 6
- 7
4
votes
1 answer
Active Directory LDAP move user to different OU - Ruby
I have hit a snag in my integration with Active Directory. I need to be able to move users from one OU to another. I'm using net-ldap 0.5.0 which is on github master branch and dug around in the source code and found out you could do this…

David Hahn
- 740
- 9
- 26
4
votes
3 answers
Search for "Enabled" users in net-ldap for Ruby
I am using the net-ldap gem to search active directory.
I can search for users by using filter:
filter = Net::LDAP::Filter.eq("sAMAccountName", "neil*")
filter2 = ~Net::LDAP::Filter.eq("objectclass", "computer")
joined_filter =…

Neil Hoff
- 2,025
- 4
- 29
- 53
4
votes
1 answer
net ldap - Encoding::UndefinedConversionError
folks! I get the following error message and I have no idea what to do. Is this a already known net-ldap bug? I tried to update my gems and I already looked for further informations in the internet. The first part is ok, I get ally my data from my…

gadreel
- 207
- 1
- 2
- 13
3
votes
2 answers
Better way to query an LDAP users via ruby net-ldap?
Is there a better way to search for users and computers specifically using the Net-ldap gem?
Here is what I am currently having to do to get only users.
results = search :base => @base, :filter => Net::LDAP::Filter.eq("cn", "*")
@results =…

Beaon
- 347
- 1
- 4
- 16
3
votes
1 answer
Cannot enable active directory user using net-ldap
We're experiencing an issue trying to enable a active directory user(windows server 2012 r2) using the net/ldap library.
Setup
First, we create a user via this method:
def create_user(attrs)
dn = "cn=#{attrs[:cn]},cn=Users,#{@base}"
cn =…

treiff
- 1,246
- 14
- 24
3
votes
1 answer
Ruby net-ldap add user
I am trying to create a new user using ldap by doing this:
require 'net/ldap'
ldap = Net::LDAP.new
ldap.host = 'ldap'
ldap.auth('uid=myuser,ou=users,dc=my,dc=domain,dc=com', 'mypass')
ldap.bind # this executes successfully, up to this point, all…

HRÓÐÓLFR
- 5,842
- 5
- 32
- 35
3
votes
1 answer
Ruby NetLdap - Move user entry from one container to another in Samba4
I'm using net-ldap's rename method to move a user from one OU to another; however, I am getting an "Old RDN must be deleted" error:
#

Lee
- 601
- 9
- 21
3
votes
2 answers
Ruby verify the certificate of secure ldap server
I am using https://github.com/ruby-ldap/ruby-net-ldap (net-ldap) gem to verify the authenticity of a user in my rails app. But before passing data to the ldap server, I need to verify that I am talking with the same secure server.
Is there a…

mintuhouse
- 449
- 5
- 16
3
votes
1 answer
Query Ldap for group details using net-ldap library
I am trying to query an ldap server for details of any groups using the net-ldap library for ruby
require 'rubygems'
require 'net/ldap'
username = "user1"
password = "pass1"
host = 'server.address'
ldap = Net::LDAP.new :host => host, :port =>…

AaShish Upadhyay
- 243
- 3
- 12
2
votes
0 answers
Unable to connect when LDAP Channel Binding is enabled
Trying to connect to AD by enforcing the LDAP Channel Binding https://portal.msrc.microsoft.com/en-us/security-guidance/advisory/ADV190023
Ending up with the below error
=> #

Sukeerthi Adiga
- 531
- 5
- 9
2
votes
1 answer
perl LDAP entry not recognised
We are writing a Perl code (to be run from Unix) which will reset the password of a Windows AD User. (We are not using powershell as we have been asked not to use Windows scripts).
With the following Perl code, we are able to connect to the AD User…

Vivek B Ahmed
- 33
- 1
- 8
2
votes
2 answers
How to reset ldap user password without old_password? Using the Net::Ldap gem or devise_ldap_authenticatable gem
I tried to reset a user password with the gem "devise_ldap_authenticatable" but it didn't work.
The command I tried to run was.
Devise::LdapAdapter.update_password(login, new_password)
but it didn't work.
Unfortunately when it tries to bind it…

Richardsondx
- 1,227
- 1
- 15
- 25