Oct 9, 2026·6 min read·83 visits
Hazelcast Zero Config Compact Serialization permits arbitrary reflective class instantiation, causing sensitive memory leaks, Denial of Service, or remote code execution.
Improper validation of dynamic class resolution within Hazelcast's Zero Config Compact Serialization allows unauthenticated clients to trigger reflective class instantiation. This flaw can be exploited to read arbitrary JVM heap or off-heap memory, crash cluster nodes, or achieve arbitrary code execution under specific classpath conditions. This issue is resolved in Hazelcast versions 5.4.5, 5.5.10, 5.6.1, and 5.7.0.
Hazelcast combines stream processing with an in-memory data store, presenting a unified real-time data platform. A critical security flaw within the Zero Config Compact Serialization (ZCCS) engine allows unauthenticated network clients to exploit cluster members. This vulnerability affects both the Community and Enterprise Editions, spanning several minor version branches.
At its core, ZCCS facilitates dynamic object serialization by mapping schema declarations to Java classes present on the classpath. However, the system failed to validate the classes specified by the client before attempting reflective instantiation. This lack of validation creates a pathway for attackers to execute arbitrary memory operations and disrupt cluster operations.
By leveraging this flaw, a remote attacker can force a cluster member to load, instantiate, and populate arbitrary classes. This process can leak sensitive data from the JVM heap, corrupt memory structures, or cause the cluster node to crash. The severity of this issue is tracked as CVSS 9.3, signifying a critical vulnerability with severe operational consequences.
The vulnerability stems from the implementation of Hazelcast's dynamic serialization resolver, which processes client-provided schemas without access control or structural verification. When a client transmits a serialized object, the cluster member parses the schema to identify the target class name via the typeName property. In vulnerable versions, the ReflectiveCompactSerializer resolves this name and attempts to reconstruct the class directly.
No restrictions or allowlists were historically applied to this dynamic class resolution pipeline. Consequently, any class available on the application classpath—including standard JDK libraries, third-party libraries, and internal Hazelcast classes—could be instantiated reflectively. This behavior essentially permits arbitrary class instantiation under the control of an untrusted network client.
This lack of restriction becomes critical when combined with classes that manipulate native memory or interact with system resources. If an attacker specifies a class that manages direct byte buffers or utilizes internal APIs like sun.misc.Unsafe, they can manipulate field values to read or write arbitrary memory addresses. This structural design flaw represents a classic case of improper input validation during deserialization, tracked under CWE-20.
The primary remediation of the vulnerability is found in commit 361979da12f18950c24719db832ca6c5e7c0534f. The patch introduces a dedicated security component named ReflectiveClassFilter to intercept dynamic serialization requests. This filter enforces class boundaries before the JVM attempts class loading or instantiation.
Below is the structured implementation of the ReflectiveClassFilter introduced in the patch:
public class ReflectiveClassFilter {
private static final ClassFilter JDK_LIB_BLOCKLIST = new ClassFilter()
.addPrefixes("java.", "javax.", "com.sun.", "sun.", "jdk.");
@Nullable
private final ClassFilter blockList;
@Nullable
private final ClassFilter allowList;
public ReflectiveClassFilter(@Nonnull CompactSerializationConfig config,
@Nonnull ExtraReflectiveCompactSerializationRestrictions extraRestrictions) {
blockList = union(JDK_LIB_BLOCKLIST, defaultBlockList, extraRestrictions.propertyBlockList(), configuredBlockList);
allowList = union(extraRestrictions.propertyAllowList(), configuredAllowList);
}
public boolean isRestricted(@Nonnull Class<?> clazz) {
return clazz.getPackage() == null || isOnBlockList(clazz) || !isOnAllowList(clazz);
}
}In addition to checking the class names, the patch integrates this filter directly into the serialization flow within CompactStreamSerializer.java. The canBeSerializedAsCompact method is modified to assess whether a class is restricted before returning its serializer:
public boolean canBeSerializedAsCompact(Class<?> clazz) {
Class<? extends SerializerAdapter> assignedSerializerType = lookupSerializerType.apply(clazz);
return CompactStreamSerializerAdapter.class.isAssignableFrom(assignedSerializerType) && (
classToRegistrationMap.containsKey(clazz) || !classFilter.isRestricted(clazz));
}If the class is found to be restricted, the engine gracefully falls back to using a GenericRecord instead of throwing a severe processing error. This prevents reflective class instantiation while preserving session stability for legitimate interactions.
An exploitation attempt begins with a client establishing a standard TCP connection to the cluster's communication port, usually port 5701. Since the vulnerability resides within the core client-to-member protocol, authentication is not a strictly required barrier if the cluster operates under default or loosely configured security roles. Once connected, the malicious client begins the serialization negotiation phase.
The attacker constructs and transmits a schema payload containing a crafted typeName set to a target class. For example, the attacker might target a class that manages internal JVM resources, off-heap data pointers, or native array lengths. After the schema registration is accepted, the client sends a data operation, such as an IMap insertion or lookup, containing the binary payload mapping to that schema.
Upon receiving the payload, the target Hazelcast member parses the stream and triggers the reflective deserialization sequence. If the target class utilizes native pointers (e.g., off-heap memory addresses) mapped to serializable fields, the client-supplied values overwrite these pointers. When the member attempts to access or serialize this object back, it reads from the manipulated address, resulting in an information leak or a segmentation fault.
The impact of exploiting CVE-2026-107726 depends on the cluster environment and classpath configuration. Under typical conditions, the primary impact is a severe confidentiality leak of JVM heap memory, off-heap data structures, and process address space. Attackers can leverage this leak to extract sensitive information, such as active session data, configuration secrets, or cryptographic keys.
In environments running Hazelcast Enterprise Edition, the impact is further amplified by the platform's intensive use of native off-heap storage. By corrupting internal reference pointers, an attacker can corrupt native memory structures. This memory corruption can lead directly to system instability, triggering abrupt node crashes and resulting in cluster-wide Denial of Service (DoS).
Under specific conditions where dangerous library gadgets exist on the application classpath, this vulnerability can lead to remote code execution (RCE). An attacker can utilize the unrestricted dynamic instantiation to trigger specific gadget chains that execute system commands. The vulnerability has been assigned a CVSS score of 9.3, indicating its potential to compromise confidentiality, integrity, and availability completely.
The primary remediation path requires upgrading Hazelcast to a non-vulnerable version. Organizations should upgrade to version 5.4.5, 5.5.10, 5.6.1, or 5.7.0 and later immediately. These versions contain the complete patch and enforce strict validation on all Zero Config Compact Serialization (ZCCS) requests.
For environments where immediate upgrades are not feasible, administrators must implement workarounds by restricting the ZCCS engine via configuration. A declarative configuration must be added to the Hazelcast XML or YAML settings. This configuration restricts ZCCS to a predefined list of safe classes, packages, or prefixes.
Below is an example of an XML configuration using the zero-config-filter element to limit dynamic serialization:
<serialization>
<compact-serialization>
<zero-config-filter defaults-disabled=\"false\">
<blacklist>
<class>com.acme.app.BeanComparator</class>
</blacklist>
<whitelist>
<class>example.Foo</class>
<package>com.acme.app</package>
<prefix>com.acme.</prefix>
</whitelist>
</zero-config-filter>
</compact-serialization>
</serialization>In addition to configuration-level mitigations, network segmentations should be enforced. Access to the client communication ports (default 5701) must be strictly restricted to trusted application nodes using stateful firewalls or security groups.
| Product | Affected Versions | Fixed Version |
|---|---|---|
Hazelcast Community Edition Hazelcast | < 5.4.5 | 5.4.5 |
Hazelcast Community Edition Hazelcast | >= 5.5.0, < 5.5.10 | 5.5.10 |
Hazelcast Community Edition Hazelcast | == 5.6.0 | 5.6.1 |
| Attribute | Detail |
|---|---|
| CWE ID | CWE-20 |
| Attack Vector | Network |
| CVSS v4.0 | 9.3 (Critical) |
| EPSS Score | Not Available |
| Exploit Status | none |
| KEV Status | Not Listed |
CVE-2026-126298 (also tracked as GHSA-r53h-rw34-8h97) is an algorithmic complexity Denial of Service (DoS) vulnerability in the Natural Language Toolkit (NLTK) Python library affecting all versions prior to 3.10.4. The vulnerability resides in the nltk.tree.transforms.chomsky_normal_form function and its corresponding public method Tree.chomsky_normal_form(). When transforming a parse tree into Chomsky Normal Form using the default right-factoring strategy, the function repeatedly invokes list.pop(0) inside a loop iterating over all children of a node. In CPython, removing the initial element of a standard list requires an O(N) memory shift operation, causing the overall binarization algorithm to degrade to O(N^2) quadratic time complexity relative to the width of a node. Furthermore, converting horizontal node width into vertical tree depth bypasses initial parsing depth bounds, triggering subsequent stack exhaustion (RecursionError) when recursive methods traverse the mutated structure. Unauthenticated remote attackers who can submit bracketed tree strings to applications invoking this transformation can exhaust single-threaded CPU resources or induce unhandled application exceptions.
An algorithmic complexity vulnerability (CWE-407) in the Natural Language Toolkit (NLTK) before version 3.10.4 allows remote unauthenticated attackers to cause a denial of service via crafted Combinatory Categorial Grammar (CCG) lexicon strings. The parser in nltk.ccg.lexicon.fromstring performs repeated immutable string slicing, concatenation, and regex tail capturing, resulting in O(n^2) CPU consumption when processing wide, flat category definitions.
CVE-2026-126295 (also tracked as GHSA-fg9w-wfp5-j933) is a path confinement bypass vulnerability in the Natural Language Toolkit (NLTK) affecting versions 3.10.0 prior to 3.10.4. The flaw resides in nltk/parse/bllip.py within the BllipParser class and its factory method BllipParser.from_unified_model_dir(). Unlike sibling tool wrappers in NLTK that enforce data-root confinement via the nltk.pathsec module, BllipParser passes caller-supplied filesystem paths directly into the third-party bllipparser native C extension without validation. When an application passes untrusted input as model paths or directories to BllipParser, an attacker can force the native extension to open arbitrary files on the local filesystem. This leads to information disclosure through parser diagnostic oracles, local model tampering via shared directories, and denial of service by hanging worker threads on blocking special files (such as FIFOs or device nodes) or exhausting memory via oversized files.
CVE-2026-126300 (GHSA-ffr9-mgrr-wcvr) is an inefficient algorithmic complexity vulnerability (CWE-407) in the Natural Language Toolkit (NLTK) Python library affecting versions 3.2.5 prior to 3.10.4. The flaw resides in the quote-restoration routine of TreebankWordTokenizer.span_tokenize and NLTKWordTokenizer.span_tokenize, where repeated calls to list.pop(0) over matched quote tokens introduce quadratic O(n^2) time complexity. An unauthenticated remote attacker who supplies input containing long sequences of double-quote characters can exhaust CPU resources and degrade service availability.
The Natural Language Toolkit (NLTK) versions 3.6 through 3.10.3 contain an algorithmic complexity vulnerability in the LegalitySyllableTokenizer.tokenize method. When processing tokens composed of continuous runs of vowels, an unguarded string reversal and set membership lookup loop executes in quadratic time relative to the input token length. Remote attackers capable of submitting arbitrary text to applications utilizing this tokenizer can trigger sustained single-core CPU exhaustion and application-level denial of service.
CVE-2026-126304 is a symlink path traversal vulnerability (CWE-59) in the Natural Language Toolkit (NLTK) versions 3.10.0 prior to 3.10.4. The YCOECorpusReader class constructs internal sub-readers for the 'psd' and 'pos' subdirectories using FileSystemPathPointer.join(), which relies exclusively on lexical string-prefix validation rather than canonical path resolution. An attacker who supplies a crafted YCOE corpus containing symbolic links in place of the 'psd' or 'pos' subdirectories can bypass directory confinement and read arbitrary files from sibling corpora or sensitive directories within the NLTK data sandbox.