CVE-2024-27309
Apache Kafka: Potential incorrect access control during migration from ZK mode to KRaft mode
Description
While an Apache Kafka cluster is being migrated from ZooKeeper mode to KRaft mode, in some cases ACLs will not be correctly enforced.
Two preconditions are needed to trigger the bug:
- The administrator decides to remove an ACL
- The resource associated with the removed ACL continues to have two or more other ACLs associated with it after the removal.
When those two preconditions are met, Kafka will treat the resource as if it had only one ACL associated with it after the removal, rather than the two or more that would be correct.
The incorrect condition is cleared by removing all brokers in ZK mode, or by adding a new ACL to the affected resource. Once the migration is completed, there is no metadata loss (the ACLs all remain).
The full impact depends on the ACLs in use. If only ALLOW ACLs were configured during the migration, the impact would be limited to availability impact. if DENY ACLs were configured, the impact could include confidentiality and integrity impact depending on the ACLs configured, as the DENY ACLs might be ignored due to this vulnerability during the migration period.
Affected Maven artifacts (1)
| Artifact | Affected versions | Fixed in |
|---|---|---|
| org.apache.kafka » kafka-metadata | >= 3.5.0, < 3.6.2 | 3.6.2 |
Blast radius
37% of the dependent artifacts (29) still pull an affected version in their latest release.
| Depth | Dependent versions |
|---|---|
| Direct | 93 |
| 2 hops | 570 |
| 3 hops | 60 |
| 4 hops | 30 |
| 5 hops | 6 |
| 6 hops | 4 |
Most used dependents
- org.apache.kafka » kafka1,450 usages
- org.springframework.kafka » spring-kafka-test289 usages
- io.github.embeddedkafka » embedded-kafka74 usages
- com.github.charithe » kafka-junit47 usages
- org.apache.kafka » kafka-group-coordinator22 usages
- net.mguenther.kafka » kafka-junit15 usages
- pl.touk.nussknacker » nussknacker-kafka-test-utils13 usages
- io.kroxylicious.testing » testing-junit5-extension10 usages
- org.citrusframework » citrus-kafka9 usages
- io.kroxylicious » kroxylicious-integration-test-support9 usages
- de.muenchen.oss.digiwf » digiwf-e2e-test-starter8 usages
- io.kroxylicious.testing » testing-impl7 usages
- io.github.embeddedkafka » embedded-kafka-streams6 usages
- com.infobip.kafkistry » kafkistry-service-logic6 usages
- io.github.embeddedkafka » embedded-kafka-schema-registry5 usages
Computed from the dependency graph of build 20261124.0621 (compile and runtime scopes, nearest version wins). Exclusions and dependency management in consuming projects are not applied, so dependents are potentially affected. When several artifacts are affected, a dependent version that pulls more than one of them is counted once per artifact.
References
| Advisory | NVD CVE-2024-27309 | nvd.nist.gov |
| Package | apache/kafka | github.com |
| Web | apache/kafka commit c000b1f | github.com |
| Web | thread/6536rmzyg076lzzdw2xdktvnz163mjpy | lists.apache.org |
| Web | advisory/ntap-20240705-0002 | security.netapp.com |
| Web | lists/oss-security/2024/04/12/3 | openwall.com |
