From the course: Advanced Pen Testing Techniques for Active Directory

Unlock the full course today

Join today to access over 24,900 courses taught by industry experts.

Interact with LDAP at the command line

Interact with LDAP at the command line

- [Instructor] Let's see how we interact with a simple LDAP service. I've set up an OpenLDAP server on my Ubuntu system at IP address 10.0.2.23 and populated it with a small number of demonstration entries. We won't spend much time on OpenLDAP, but if you do want to do more, you can find all you need to know in Grant MC Williams, Linux OpenLDAP course here on LinkedIn Learning. We can enumerate LDAP directory information at the Carly terminal using Nmaps, LDAP search script, and for an OpenLDAP server, we'd expect to be able to gain anonymous access. In other words, we don't need to authenticate with credentials. We do this with Nmap minus p389 10.0.2.23 minus minus script equals LDAP search. This connects to the server, confirms port 389 is open and enumerate the whole database using anonymous access. Nmap has returned the directory objects starting with the organizational root record for cybex.nz, the directory…

Contents