▷ Ldap: what it is and what this protocol is used for
Table of contents:
- What is LDAP?
- LDAP operation
- How information is stored in LDAP
- How information is accessed in LDAP
- Structure of an access URL in LDAP
- Most important tools that use the LDAP protocol
The LDAP protocol is widely used today by companies that bet on free software by using Linux distributions to exercise the functions of an active directory in which the credentials and permissions of workers and workstations in corporate LAN networks will be managed in client / server connections.
Index of contents
In this article we will see as fully as possible what this protocol and corresponding tool consists of, along with the structure and terms most used in it.
What is LDAP?
LDAP is short for Lightweight Directory Access Protocol). It is a set of open license protocols that are used to access the information that is stored centrally in a network. This protocol is used at the application level to access remote directory services.
A remote directory is a set of objects that are hierarchically organized, such as names, addresses, etc. These objects will be made available by a series of clients connected through a network, usually internal or LAN, and will provide the identities and permissions for those users who use them.
LDAP is based on the X.500 protocol for directory sharing, and it contains this information in a hierarchical and categorized way to provide us with an intuitive structure from the point of view of management by administrators. It is, so to speak, a phone book, but with more attributes and credentials. In this case we use the term directory to refer to the organization of these objects.
In general, these directories are basically used to contain virtual user information, so that other users access and have information about the contacts that are stored here. But it is much more than this, since it is able to remotely communicate with other LDAP directories located on servers that may be on the other side of the world to access the available information. In this way, a decentralized and fully accessible information database is created.
The current version is called LDAPv3 and is defined in a publicly accessible RFC 4511 documentation sheet.
LDAP operation
LDAP is a protocol based on the connection between client and server. The data related to the directory will be stored in the LDAP server, which will be able to use a wide variety of databases for this storage, becoming very large.
Access and administration operation is very similar to Windows Active Directory. When the LDAP client connects to the server, you can perform two basic actions, either query and obtain directory information, or modify it.
- If a client consults the information, the LDAP server can connect it directly if they have a directory hosted in it, or redirect the request to another server that actually has this information. This may be local, or remote. If a client wants to modify the directory information, the server will check if the user who is accessing this directory has administrator permissions or not. Then, the information and management of an LDAP directory can be done remotely.
The connection port for the LDAP protocol is TCP 389, although, of course, it can be modified by the user and set it to the one he wishes if he indicates it to the server.
How information is stored in LDAP
In an LDAP directory we can store basically the same information as in a Windows Active Directory. The system is based on the following structure:
- Entries, called objects in Active Directory. These entries are collections of attributes with a Distinguished Name (DN) This name is used to give a unique and unrepeatable identifier to a directory entry. An entry can be the name of an organization and attributes will hang from it. Also a person can be an entry. Attributes: which have an identifier type and the corresponding values. The types are used to identify the names of attributes, for example "mail", "name", "jpegPhoto", etc. Some of the attributes that belong to an entry must be mandatory and others optional. LDIF: The LDAP Data Interchange Format is the ASCII text representation of LDAP entries. This should be the format of the files used to import information into an LDAP directory. When a blank line is written, it means the end of an entry.
dn: Trees: It is the hierarchical organization of entries. For example, in a tree structure we can find a country at the top and as the main one, and within this we will have the different states that make up the country. Within each state we will be able to list the districts, citizens and addresses of where they live, and so on. If we applied this to the Internet and computing, we could organize an LDAP directory by means of a domain name that would do the tree functions and from it would hang the different departments or organizational units of a company, employees, etc. And it is precisely in this way that directories are currently formed, thanks to the use of a DNS service, we can associate an IP address with an LDAP directory to be able to access it through the domain name. An example entry for an LDAP directory might be: dn: cn = Jose Castillo, dc = profesionalreview, dc = com cn: Jose Castillo givenName: Jose sn: Castillo telephoneNumber: +34 666 666 666 mail: [email protected] objectClass: inetOrgPerson objectClass: organizationalPerson objectClass: person objectClass: top
An LDAP server, in addition to storing a tree, can contain subtrees that include entries specific to the primary domain. Also, you can store references to other directory servers to divide the content if necessary. When making remote connections to an LDAP server, we will need the use of URL addresses to obtain information from it. The basic structure ldap: // server: port / DN? attributes? scope? filters? extensions
For example: ldap: //ldap.profesionalreview.com/cn=Jose%20Castillo, dc=profesionalreview, cd=com
We are looking for all the users in Jose Castillo's entry at profesionalreview.com. In addition to this notation, we will also have a version of LADP with SSL security certificate, whose identifier for the URL will be "ldaps:". There are currently various tools that use this protocol for client-server communication of a directory service. Most importantly, even Windows Active Directory uses this communication protocol. These are the most interesting features and most relevant information about the LDAP protocol. Of course we will try to expand information with tutorials that we are taking out on this topic. In the meantime, you may be interested in this information: We hope this information has been helpful. To add something or tell us what you think about LDAP write us in the comments.How information is accessed in LDAP
Structure of an access URL in LDAP
Most important tools that use the LDAP protocol
What is hamachi and what is it used for?
Hamachi is an application that we gamers have used for many years. We explain what it is and the uses we can give it.
UK government websites have been used and used to mine because of browsealoud
A security flaw in the Browsealoud plugin to put users' processors to mine Monero, among the affected websites have been those of the US and UK governments.
▷ What are lan, man and wan networks and what are they used for
We show you what the LAN, MAN and WAN networks are. ? Characteristics, network topologies, standards and utility of the networks that surround us