Bug 1226219 (CVE-2024-27309)

Summary: VUL-0: CVE-2024-27309: kafka: potential incorrect access control during migration from ZK mode to KRaft mode
Product: [Novell Products] SUSE Security Incidents Reporter: SMASH SMASH <smash_bz>
Component: IncidentsAssignee: Security Team bot <security-team>
Status: RESOLVED INVALID QA Contact: Security Team bot <security-team>
Severity: Normal    
Priority: P5 - None CC: camila.matos
Version: unspecified   
Target Milestone: ---   
Hardware: Other   
OS: Other   
URL: https://smash.suse.de/issue/401559/
Whiteboard: CVSSv3.1:SUSE:CVE-2024-27309:6.8:(AV:N/AC:H/PR:L/UI:N/S:U/C:H/I:H/A:N)
Found By: Security Response Team Services Priority:
Business Priority: Blocker: ---
Marketing QA Status: --- IT Deployment: ---

Description SMASH SMASH 2024-06-12 12:54:16 UTC
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:
1. The administrator decides to remove an ACL
2. 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.

References:
http://web.nvd.nist.gov/view/vuln/detail?vulnId=CVE-2024-27309
https://seclists.org/oss-sec/2024/q2/105
https://www.cve.org/CVERecord?id=CVE-2024-27309
https://lists.apache.org/thread/6536rmzyg076lzzdw2xdktvnz163mjpy
http://www.openwall.com/lists/oss-security/2024/04/12/3
https://bugzilla.redhat.com/show_bug.cgi?id=2291362
Comment 1 Camila Camargo de Matos 2024-06-12 13:07:10 UTC
As per the CVE Record page for this issue [0] and an upstream advisory [1], affected versions are only 3.5.0 through 3.5.2, and 3.6.0 through 3.6.1.

Therefore, it seems like package kafka in the below codestreams is *not* affected by this issue.

- openSUSE:Backports:SLE-15-SP5/kafka   2.1.0 
- openSUSE:Backports:SLE-15-SP6/kafka   2.1.0
- openSUSE:Factory/kafka                2.1.0

The above being said, this bug can be now closed. 

[0] https://www.cve.org/CVERecord?id=CVE-2024-27309
[1] https://lists.apache.org/thread/6536rmzyg076lzzdw2xdktvnz163mjpy
Comment 2 Camila Camargo de Matos 2024-06-12 13:15:43 UTC
(In reply to Camila Camargo de Matos from comment #1)
> As per the CVE Record page for this issue [0] and an upstream advisory [1],
> affected versions are only 3.5.0 through 3.5.2, and 3.6.0 through 3.6.1.
> 
> Therefore, it seems like package kafka in the below codestreams is *not*
> affected by this issue.
> 
> - openSUSE:Backports:SLE-15-SP5/kafka   2.1.0 
> - openSUSE:Backports:SLE-15-SP6/kafka   2.1.0
> - openSUSE:Factory/kafka                2.1.0
> 
> The above being said, this bug can be now closed. 
> 
> [0] https://www.cve.org/CVERecord?id=CVE-2024-27309
> [1] https://lists.apache.org/thread/6536rmzyg076lzzdw2xdktvnz163mjpy

Also, KRaft mode seems to only have been introduced starting at version 2.8.0.