In Spring for Apache Pulsar, overly broad trusted-package matching in header mapper exposes JDK classes to deserialization
JsonPulsarHeaderMapper matched type headers against trusted packages using a prefix check, meaning that trusting any package implicitly trusted all of its subpackages. Additionally, an empty trusted-packages configuration fell back to trusting all packages rather than applying a safe default allow-list.
Affected versions:
Spring for Apache Pulsar 2.0.0 through 2.0.5; 1.2.0 through 1.2.17; 1.1.0 through 1.1.17.
Problem Types
| Type | CWE ID | Description |
|---|
| CWE | CWE-502 | CWE-502: Deserialization of Untrusted Data |
Type: CWE
Description: CWE-502: Deserialization of Untrusted Data
Metrics
| Version | Base score | Base severity | Vector |
|---|
| 3.1 | 8.1 | HIGH | CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H |
Version: 3.1
Base score: 8.1
Base severity: HIGH
Vector: CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:U/C:H/I:H/A:H
Impacts
| CAPEC ID | Description |
|---|
| N/A | A producer can supply crafted Pulsar header values that cause the consumer to deserialize arbitrary JDK types via overly broad trusted-package prefix matching in JsonPulsarHeaderMapper. |
CAPEC ID: N/A
Description: A producer can supply crafted Pulsar header values that cause the consumer to deserialize arbitrary JDK types via overly broad trusted-package prefix matching in JsonPulsarHeaderMapper.