# Directory and LDAP explained: the lobby board behind your login

> A directory is the lobby board of users, groups and devices. LDAP is the protocol apps use to ask it who someone is and what groups they belong to.

- URL: https://iamops.dev/directory-and-ldap-explained/
- Language: en
- Author: Argo
- Published: 2026-12-06
- Category: Knowledge
- Depth: Explainer
- Audience: Security leaders and architects
- Time: 5 min
- Topics: directory, LDAP, basics

## TL;DR

- A [directory](https://iamops.dev/directory-and-ldap-explained/#what-a-directory-is) stores the people, groups and devices that company apps ask about.
- The protocol apps use to ask it is the Lightweight Directory Access Protocol, [explained here](https://iamops.dev/directory-and-ldap-explained/#where-ldap-fits).
- A disabled account should fail [at the directory](https://iamops.dev/directory-and-ldap-explained/#what-to-check), not inside one app only.

**Audience: Beginners.** Anyone who has been told "the account lives in the directory" and never seen one.

**Before you start:** [OpenID Connect explained](https://iamops.dev/openid-connect-explained/) shows how an app asks a sign-in service about a person. In many companies the directory sits behind that service.

## What a directory is

A directory is a store built for reading. It keeps objects: people, groups, computers and printers. For each person it holds a name, a login name, group memberships and often a phone number. Microsoft's documentation for Active Directory Domain Services describes the same idea: a store of objects on a network, with user accounts among them.

The closest everyday picture is the board in a company lobby. It lists who works on which floor and in which team. The receptionist reads it when a visitor asks. The board does not decide who gets in. The reception does.

## Where LDAP fits

The Lightweight Directory Access Protocol (LDAP) is the way to talk to a directory. <abbr title="Request for Comments">RFC</abbr> 4511 defines it as a protocol that gives access to directory services. An app can search the directory, read an entry, compare a value, and run a bind. A bind is the check that a user name and password are correct.

<abbr title="Lightweight Directory Access Protocol">LDAP</abbr> is a question language, not a database you write to by hand. The app asks, and the directory answers with what it holds.

## Example: a VPN login

Imagine a <abbr title="virtual private network">VPN</abbr> server that takes a user name and password. It passes them to the directory in a bind. If the bind works, the server looks up the person's groups and lets in only members of a group such as vpn-users.

Now take someone who left the company last month. Her account is disabled in the directory. The VPN asks the directory, the directory refuses, and she never gets in. The sequence below shows that path.

![Sequence diagram: you enter a user name and password at a VPN server, the server binds to the directory, the directory refuses because the account is disabled, and the VPN refuses the connection.](https://iamops.dev/img/directory-and-ldap-explained.svg)

*The directory answers. The VPN decides what the answer allows.*

## Why it still matters for new apps

Most new apps do not ask the directory directly. They sign people in with a protocol such as OpenID Connect or <abbr title="Security Assertion Markup Language">SAML</abbr>, and the sign-in service in front may read the directory behind it. Another option copies accounts into each app with the <abbr title="System for Cross-domain Identity Management">SCIM</abbr> protocol, so the app never asks the directory at all.

Either way, the directory is still the place where a person's status is kept.

## What to check

Test a leaver. Disable one test account in the directory and see whether sign-in fails in every app that depends on it, and how quickly. Write down the answer.

Use an encrypted connection for every bind. A bind sends a password, and a plain connection shows that password to anyone on the path.

Limit which accounts may search the whole directory. A search that returns every user is a map for an attacker.

## Where to go next

- [SCIM explained](https://iamops.dev/scim-explained-user-accounts-automatic/): how accounts get created and removed in each app.
- [SAML and OpenID Connect compared](https://iamops.dev/saml-vs-oidc-how-an-app-learns-sign-in/): how an app learns who signed in.
- [Roles, attributes or relationships](https://iamops.dev/rbac-abac-rebac-explained/): what groups and roles decide once the person is known.

## Sources

- [RFC 4511: Lightweight Directory Access Protocol (LDAP): The Protocol](https://datatracker.ietf.org/doc/html/rfc4511)
- [Active Directory Domain Services overview, Microsoft Learn](https://learn.microsoft.com/en-us/windows-server/identity/ad-ds/get-started/virtual-dc/active-directory-domain-services-overview)

Discuss: [X](https://x.com/iamopsdev) | [LinkedIn](https://www.linkedin.com/company/iamops-dev/)
