Ldap Injection
Ldap Injection
(LIGHTWEIGHT DIRECTORY
ACCESS PROTOCOL)
(& (USER=slisberger)(&))(PASSWORD=Pwd))
OR LDAP INJECTION
(|(parameter1=value1)(parameter2=value2))
(|(type=printer )(type=scanner))
If the attacker enters Rsc1=printer)(uid=*), the
following query is sent to the server:
(|(type=printer)(uid=*))(type=scanner)) The
LDAP server responds with all the printer and
user objects.
BLIND LDAP INJECTION
Suppose that an attacker can infer from the server
responses, although the application does not show error
messages, the code injected in the LDAP filter generates a
valid response (true result) or an error (false result). The
attacker could use this behavior to ask the server true or
false questions. These types of attacks are named “Blind
Attacks”. Blind LDAP Injection attacks are slower than
classic ones but they can be easily implemented, since they
are based on binary logic, and they let the attacker extract
information from the LDAP Directory.
EXAMPLES
(& (objectClass=printer)(type=Epson*))
(&(objectClass=*)(objectClass=*))(&(objectClass=void)(type
=Epson*))
(|(objectClass=void)(objectClass=void))(&(objectClass=void)
(type=Epson*))
SECURING APPLICATIONS AGAINST
BLIND LDAP INJECTION & LDAP INJECTION ATTACKS