CVE-2026-83557: jackson-databind: Comparable missing from DefaultBaseTypeLimitingValidator's unsafe base types (incomplete PolymorphicTypeValidator denylist)
DefaultBaseTypeLimitingValidator — the PolymorphicTypeValidator used automatically whenever @JsonTypeInfo is applied without an explicitly configured custom validator — denies polymorphic resolution only for nine specific “unsafe base types” (Object, Serializable, Closeable, AutoCloseable, Cloneable, Runnable, java.util.logging.Handler, javax.naming.Referenceable, javax.sql.DataSource). Its isSafeSubType() returns true unconditionally for every other base type. java.lang.Comparable is not in that list, despite being implemented by a very large fraction of JDK and application classes — comparable in breadth to Serializable, which is denylisted for exactly that reason. An application with an @JsonTypeInfo-annotated Comparable-typed property, and no custom validator configured, will accept a type identifier for essentially any class implementing Comparable.
References
- github.com/FasterXML/jackson-databind/commit/eb3b7fc0f9c0d27f471550ac3316b17d1987388f
- github.com/FasterXML/jackson-databind/issues/6156
- github.com/FasterXML/jackson-databind/pull/6155
- github.com/FasterXML/jackson-databind/releases/tag/jackson-databind-2.18.10
- github.com/FasterXML/jackson-databind/releases/tag/jackson-databind-2.21.6
- github.com/FasterXML/jackson-databind/releases/tag/jackson-databind-2.22.2
- github.com/FasterXML/jackson-databind/releases/tag/jackson-databind-3.1.6
- github.com/FasterXML/jackson-databind/releases/tag/jackson-databind-3.2.2
- github.com/FasterXML/jackson-databind/security/advisories/GHSA-gx83-3vf8-gh7j
- github.com/advisories/GHSA-gx83-3vf8-gh7j
- nvd.nist.gov/vuln/detail/CVE-2026-83557
Code Behaviors & Features
Detect and mitigate CVE-2026-83557 with GitLab Dependency Scanning
Secure your software supply chain by verifying that all open source dependencies used in your projects contain no disclosed vulnerabilities. Learn more about Dependency Scanning →