Miggo Logo

CVE-2024-47825:
Cilium's CIDR deny policies may not take effect when a more narrow CIDR allow is present

4

CVSS Score
3.1

Basic Information

EPSS Score
0.05942%
Published
10/21/2024
Updated
11/1/2024
KEV Status
No
Technology
TechnologyGo

Technical Details

CVSS Vector
CVSS:3.1/AV:N/AC:H/PR:N/UI:N/S:C/C:L/I:N/A:N
Package NameEcosystemVulnerable VersionsFirst Patched Version
github.com/cilium/ciliumgo>= 1.15.0, < 1.15.101.15.10
github.com/cilium/ciliumgo>= 1.14.0, < 1.14.161.14.16

Vulnerability Intelligence
Miggo AIMiggo AI

Miggo AIRoot Cause Analysis

The vulnerability stems from the policy insertion logic in denyPreferredInsertWithChanges. The commit diff shows significant modifications to CIDR superset handling and port/protocol comparisons. The original implementation would delete deny entries when a narrower allow rule with 'enableDefaultDeny: false' or 'toEntities: all' existed, due to incorrect assumptions about CIDR relationship handling and datapath enforcement priorities. The patched version adds new conditional checks (identityIsSupersetOf, PortProtoIsBroader) and preserves critical deny entries through additional key insertion, confirming the vulnerability resided in this function's decision logic.

Vulnerable functions

Only Mi**o us*rs **n s** t*is s**tion

WAF Protection Rules

WAF Rule

### Imp**t * poli*y rul* **nyin* * pr**ix t**t is *ro***r t**n /** m*y ** i*nor** i* t**r* is - * poli*y rul* r***r*n*in* * mor* n*rrow pr**ix (`*I*RS*t` or `to*Q*N`) ***n*** - T*is n*rrow*r poli*y rul* sp**i*i*s *it**r `*n**l*****ult**ny: **ls*` o

Reasoning

T** vuln*r**ility st*ms *rom t** poli*y ins*rtion lo*i* in `**nyPr***rr**Ins*rtWit****n**s`. T** *ommit *i** s*ows si*ni*i**nt mo*i*i**tions to *I*R sup*rs*t **n*lin* *n* port/proto*ol *omp*risons. T** ori*in*l impl*m*nt*tion woul* **l*t* **ny *ntri*