HOME
Light Weight Dicrectory Access Protocol
Light Weight Dicrectory Access Protocol
LDAP stands for **Lightweight Directory Access Protocol**.
It is a protocol used to access and manage directory information over a network.
## What LDAP is Used For
LDAP is commonly used for:
* User authentication (login systems)
* Centralized user management
* Employee directories
* Permission and access control
* Single Sign-On (SSO)
Many organizations use LDAP with systems like:
* [Microsoft Active Directory](https://www.microsoft.com/windows-server/active-directory?utm_source=chatgpt.com)
* [OpenLDAP](https://www.openldap.org/?utm_source=chatgpt.com)
Add: PROSTA PEAK-Prostate Health
---
## Simple Example
When you log into a company computer:
1. Username and password are sent to the LDAP server
2. LDAP checks the directory database
3. If valid, access is granted
---
## LDAP Directory Structure
LDAP stores data in a tree-like structure.
Example:
```text
dc=company,dc=com
├── ou=Employees
│ ├── cn=John
│ └── cn=Sara
└── ou=Managers
```
### Common Terms
* **dc** = Domain Component
* **ou** = Organizational Unit
* **cn** = Common Name
---
Add: Nano Ease Nano Technologies Pain Relief
## LDAP Features
* Centralized authentication
* Fast searching
* Secure access with LDAPS
* Cross-platform support
* Hierarchical data storage
---
## LDAP vs Database
| LDAP | Database |
| ----------------------------- | -------------------------- |
| Optimized for reading | Optimized for transactions |
| Hierarchical structure | Table structure |
| Mainly for directory services | General data storage |
---
## LDAP Ports
* **389** → Standard LDAP
* **636** → Secure LDAP (LDAPS)
---
## LDAP in Java
Java can connect to LDAP using **JNDI (Java Naming and Directory Interface)**.
Add: Hemochomatosis-Iron Blood Leavels
Example connection code:
```java
Hashtable
env = new Hashtable<>();
env.put(Context.INITIAL_CONTEXT_FACTORY,
"com.sun.jndi.ldap.LdapCtxFactory");
env.put(Context.PROVIDER_URL,
"ldap://localhost:389");
DirContext ctx = new InitialDirContext(env);
```
## Popular LDAP Servers
* [OpenLDAP](https://www.openldap.org/?utm_source=chatgpt.com)
* [Apache Directory Server](https://directory.apache.org/apacheds/?utm_source=chatgpt.com)
* [389 Directory Server](https://www.port389.org/?utm_source=chatgpt.com)
* [Microsoft Active Directory](https://www.microsoft.com/windows-server/active-directory?utm_source=chatgpt.com)
Wishing you all the best,
http://www.seeyourneeds.in