Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Ldap server for developer

Tags:

ldap

I am developing a project and that requires ldap validation. But, I don't have a developer/qa ldap server.

Does a small ldap server exist for windows for testing/development?.

I just want to test to validate a active account and detect if it is blocked or not, so i don't want to install a whole domain to do that.

---never mind---

I tried an compiled openldap but I was unable to understand it. Simply, I don't get how to connect to it, how to create a account and how to validate, the client ldap returned me some obfuscate error message, i tried several ways to do it and finally i give up.

Finally, i installed a domain, it was absurdly easy to install (2008 r2), restart the server and that's it.

Anyways, thanks for the advice of opendlap and aldps

like image 441
magallanes Avatar asked Jan 20 '11 13:01

magallanes


People also ask

How do I create a LDAP server for testing?

Install Ubuntu Server Edition 8.10, boot it up and install OpenLDAP. You can probably just accept the defaults if this is just for testing, therefore your domain will be dc=example,dc=com. In the install wizard it should ask you to setup your ldap admin user, this user's DN should be *cn=admin,dc=example,dc=com`.

What is LDAP server used for?

What is LDAP? LDAP (Lightweight Directory Access Protocol) is an open and cross platform protocol used for directory services authentication. LDAP provides the communication language that applications use to communicate with other directory services servers.


8 Answers

Apache provide a directory server called "ApacheDS"(Apache Directory Server), and it provides a GUI management client called "Apache Directory Studio" which is based on Eclipse.

If you want to have a test only, this studio provides a built-in server for your test, easy to link.

You can also install the studio directly in Eclipse using this update site: http://directory.apache.org/studio/update/2.x/

like image 59
Doug Hou Avatar answered Oct 14 '22 00:10

Doug Hou


If you're on Windows and use Active Directory, have a look at Active Directory Lightweight Directory Services (AD LDS) - a LDAP server you can install and use on your dev machine.

like image 40
marc_s Avatar answered Oct 13 '22 23:10

marc_s


The open source LDAP server from OpenLDAP should give you what you need:

http://www.openldap.org/

like image 44
MrEyes Avatar answered Oct 13 '22 23:10

MrEyes


Try OpenDS it is very simple and requires only Java.

like image 43
sdorra Avatar answered Oct 14 '22 01:10

sdorra


You could roll your own LDAP server for testing pretty easily using godap: https://github.com/bradleypeabody/godap

It's written in Go. It's very small and simple.

You would basically need to copy the server example out of godap_test.go and wire it up however you need.

like image 41
Brad Peabody Avatar answered Oct 14 '22 00:10

Brad Peabody


Active Directory works fine as an LDAP server and its included in the Windows Server 2008 trial. See the answer to my question Testing LDAP Connections to Active Directory Server. I have it running in a KVM virtual machine on Linux and query it from an OpenLDAP based client.

like image 36
Gene Vincent Avatar answered Oct 13 '22 23:10

Gene Vincent


Necromancing.
I've had the same problem.

OpenDS is very easy to get up and running, and doesn't require administrator rights.
You just need to download the ZIP file and run the installer.
The installer can populate the directory with test entries, too - if you want to see some example data.
That's exactly what you're looking for when wanting a simple dev test server.

Note:
OpenDS development has seized, and was forked into OpenDJ, a commercial project by forgerock.
While OpenDS still works on Java7, only OpenDJ will work with Java8.

However, OpenDJ is still FREE and OpenSource.
You can find the sourcecode here on Bitbucket and you can grab it with git:

git clone https://stash.forgerock.org/scm/opendj/opendj.git

Forget OpenLDAP and AD-LDS; these are way too complicated for simple testing.
In addition, their user interface is horrible, and you need something that you can get up and running FAST, without admin rights, and have it populated with test data in a few minutes, not in a few weeks.
And ApacheDS will require administrator privileges, unfortunately (because it only works as windows service, and you can't start/stop these without being administrator).

So OpenDJ is the definite way to go.

Apache Directory Studio is a good client to browse, edit and import/export data via LDAP (LDIF).
However, despite Apache Directory Studio being written in Java, it adds a dependency to gtk, and only has binaries for x86/x64, which means it won't work on a Chromebook with ARM processor, or on a RaspberrryPI.

But with the test entries added automagically in OpenDJ/OpenDS (if you choose the option), you don't even need that.
When in doubt, use a web based interface that "talks LDAP".

like image 39
Stefan Steiger Avatar answered Oct 14 '22 01:10

Stefan Steiger


Try simple-ldap-server

I know its pretty late to answer this question. But for the reference of someone who runs into the same question.

I wrote a simple ldap server(using ldapjs on nodejs) for authentication testing purposes. Please feel free to use it. It's easy to configure. Can support both LDAP/LDAPS protocols, just require a json file including the user ids you want to add(or it comes with a pre-included users json file, which you can use if you want). The project is on github. (I'll add a docker image too) Feel free to visit and use

Docker image

Simple Ldap Server Git

like image 45
MarterJay Avatar answered Oct 14 '22 01:10

MarterJay