Research
Security News
Malicious npm Packages Inject SSH Backdoors via Typosquatted Libraries
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
haraka-plugin-ldap-authn
Advanced tools
This haraka plugin implements authentication (authn) agains LDAP servers, i.e. it checks if the given user credentials are valid in LDAP. It can either search for the user DN first, or it can try to bind by predefined DN templates and utilizes the haraka-
This haraka plugin implements authentication (authn) agains LDAP servers, i.e. it checks if the given user credentials are valid in LDAP. It can either search for the user DN first, or it can try to bind by predefined DN templates and utilizes the haraka-plugin-ldap-pool plugin.
All configuration is done in config/authn_ldap.ini
.
The following options are configurable:
basedn
: optional, default: as used by haraka-plugin-ldap-poolscope
: optional, default: as used by haraka-plugin-ldap-poolsearchfilter
: optional, default: (&(objectclass=*)(uid=%u))%u
denotes the uid/username as given during login. As result the search filter should return the object(s) to be used for a simple bind attempt. Authentication will fail if the search filter doesn't return exactly one matching object.dn
: optional, default: undefineddn
is an array of template DN to check for the given uid. This is an alternate mode of lookup, where the plugin inserts the uid in the DN template and immediately tries to bind instead of doing a search for the DN first. A template DN looks like uid=%u,ou=users,dc=my-domain,dc=com
. The param %u
denotes the uid/username as given during login.Below are two examples to explain both modes of operation.
Given the following configuration:
searchfilter = (&(objectclass=*)(uid=%u))
Here the plugin will search for the object(s) first. The search filter should return some object's DN like uid=user1,ou=users,dc=my-domain,dc=com
. Then the plugin will attempt a simple bind with the found DN and the given password.
Given the following configuration:
dn[] = uid=%u,ou=users,dc=my-domain,dc=com
dn[] = uid=%u,ou=people,dc=my-domain,dc=com
The plugin will replace %u
with the given username and immediately attempts to simple bind with the resulting DN(s) and the given password.
While the search filter approach offers more flexibility, a limited number of DN templates might be faster as they don't need to search first.
However, there's also another noteworthy difference. Given the following LDAP data:
dn: uid=nonunique,ou=users,dc=my-domain,dc=com
uid: nonunique
dn: uid=nonunique,ou=people,dc=my-domain,dc=com
uid: nonunique
In this scenario, the search filter approach will always deny login for uid nonunique
, because the search doesn't return exactly one single result. However, if using DN templates instead the user would be able to log in.
FAQs
This haraka plugin implements authentication (authn) agains LDAP servers, i.e. it checks if the given user credentials are valid in LDAP. It can either search for the user DN first, or it can try to bind by predefined DN templates and utilizes the haraka-
We found that haraka-plugin-ldap-authn demonstrated a not healthy version release cadence and project activity because the last version was released a year ago. It has 1 open source maintainer collaborating on the project.
Did you know?
Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.
Research
Security News
Socket’s threat research team has detected six malicious npm packages typosquatting popular libraries to insert SSH backdoors.
Security News
MITRE's 2024 CWE Top 25 highlights critical software vulnerabilities like XSS, SQL Injection, and CSRF, reflecting shifts due to a refined ranking methodology.
Security News
In this segment of the Risky Business podcast, Feross Aboukhadijeh and Patrick Gray discuss the challenges of tracking malware discovered in open source softare.