MongoDbMessageStore exposes an addAllowedPatterns() API that restricts which classes may be deserialized from stored ErrorMessage payloads. Its Javadoc does not state that it must be called before the store is initialized. The allow-list is copied by value into the internal converter only once, when the store is initialized. If addAllowedPatterns() is called after initialization, the new patterns are never applied. Because an empty allow-list permits every class, the store continues to deserialize arbitrary classes while the application believes it is restricted.
An attacker who can influence the serialized bytes stored in the backing MongoDB collection can cause an arbitrary Java class to be deserialized, which may lead to remote code execution through a gadget chain. Applications that configure the allow-list before the store is initialized are not affected.
References
Configurations
No configuration.
History
02 Dec 2026, 15:17
| Type | Values Removed | Values Added |
|---|---|---|
| CWE | CWE-502 |
02 Dec 2026, 08:17
| Type | Values Removed | Values Added |
|---|---|---|
| New CVE |
Information
Published : 2026-12-02 08:17
Updated : 2026-12-02 19:26
NVD link : CVE-2026-59438
Mitre link : CVE-2026-59438
CVE.ORG link : CVE-2026-59438
JSON object : View
Products Affected
No product.
CWE
CWE-502
Deserialization of Untrusted Data
