Cloudanix VulnDB

CVE-2024-55885

None

Beego has Collision Hazards of MD5 in Cache Key Filenames

CVSS

—

EPSS

0.3%

Published

Dec 12, 2024

CISA due date

—

Cloudanix analysis

Monitor only SSVC: Track

A widely used web framework generates cache file names with an outdated and easily fooled math function, letting attackers trick the system into serving the wrong stored data to users.

Exploitation
Remote Unauthenticated
Attacker needs
None
Complexity
Theoretical
Impact
Data Tampering
Component
Application
Class
Cryptographic Weakness
Remediation
Patch
Effort
Medium
Patch risk
Low

What it actually does

Use of MD5 to derive cache filenames creates predictable collision opportunities allowing an attacker to force distinct inputs to map to the same filename and thereby overwrite or poison cached content.

Why it matters to the business

Attackers can manipulate or corrupt application cache contents, leading to incorrect responses being served to users, degraded performance, or denial-of-service conditions until caches are cleared.

How an attack unfolds

An attacker supplies carefully chosen inputs whose MD5 hashes collide on the first 128 bits used for filename generation; the colliding filenames cause the cache layer to store or retrieve the wrong objects, enabling cache poisoning or content manipulation without authentication.

How to fix it

Upgrade beego/beego to commit e7fa4835f71f47ab1d13afd638cebf661800d5a4 or later; replace MD5 with a collision-resistant hash (e.g., SHA-256) or a keyed MAC for cache filename derivation and invalidate existing caches after deployment.

How to confirm the fix worked

Confirm the running binary or source tree contains commit e7fa4835f71f47ab1d13afd638cebf661800d5a4; review cache-key generation code for removal of MD5 and re-test with known collision inputs to verify distinct filenames are produced.

Typical attack path

  1. Identify endpoints or parameters that feed into MD5-based cache key generation
  2. Craft input pairs that produce identical MD5 digests for the filename portion
  3. Submit colliding inputs to cause cache entry overwrite or misdirection
  4. Observe or trigger serving of poisoned cache content to other users

How to detect it

Search application and web-server logs for repeated requests that produce identical cache filenames from differing inputs; inspect cache directories for unexpected overwrites or files whose names match known MD5 collision patterns; review audit logs for cache-eviction or misdirection events around the time of suspicious requests.

What your security team should do

  • Immediately upgrade all beego deployments to the fixed commit
  • Add static analysis or dependency checks to block future use of MD5 for security-sensitive operations
  • Monitor cache hit/miss ratios and response anomalies as indicators of attempted manipulation
  • Plan cache invalidation and rollout within the next sprint given the published date

The record

In the context of using MD5 to generate filenames for cache keys, there are significant collision hazards that need to be considered. MD5, or Message Digest Algorithm 5, is a widely known cryptographic hash function that produces a 128-bit hash value. However, MD5 is no longer considered secure against well-funded opponents due to its vulnerability to collision attacks.

Affected packages

Ecosystem Package Introduced Fixed
Go github.com/beego/beego 0 No fix
Go github.com/beego/beego/v2 0 2.3.4
Chainguard harbor-2.11 0 2.11.2-r20
Chainguard harbor-2.11-exporter 0 2.11.2-r20
Chainguard harbor-2.11-jobservice 0 2.11.2-r20
Chainguard harbor-2.11-photon-registry 0 2.11.2-r22
Chainguard harbor-2.11-portal 0 2.11.2-r20
Chainguard harbor-2.11-portal-nginx-config 0 2.11.2-r20
Chainguard harbor-2.11-redis-compat 0 2.11.2-r20
Chainguard harbor-2.11-registryctl 0 2.11.2-r20
Chainguard harbor-2.12 0 2.12.4-r13
Chainguard harbor-2.12-exporter 0 2.12.4-r13
Chainguard harbor-2.12-jobservice 0 2.12.4-r13
Chainguard harbor-2.12-photon-registry 0 2.12.4-r15
Chainguard harbor-2.12-portal 0 2.12.4-r13
Chainguard harbor-2.12-portal-nginx-config 0 2.12.4-r13
Chainguard harbor-2.12-redis-compat 0 2.12.4-r13
Chainguard harbor-2.12-registryctl 0 2.12.4-r13
Chainguard harbor-fips-2.11 0 2.11.2-r25
Chainguard harbor-fips-2.11-db 0 2.11.2-r25
Chainguard harbor-fips-2.11-exporter 0 2.11.2-r25
Chainguard harbor-fips-2.11-jobservice 0 2.11.2-r25
Chainguard harbor-fips-2.11-photon-registry 0 2.11.2-r28
Chainguard harbor-fips-2.11-portal 0 2.11.2-r25
Chainguard harbor-fips-2.11-redis-compat 0 2.11.2-r25
Chainguard harbor-fips-2.11-registryctl 0 2.11.2-r25
Chainguard harbor-fips-2.12 0 2.12.4-r12
Chainguard harbor-fips-2.12-db 0 2.12.4-r12
Chainguard harbor-fips-2.12-exporter 0 2.12.4-r12
Chainguard harbor-fips-2.12-jobservice 0 2.12.4-r12
Chainguard harbor-fips-2.12-photon-registry 0 2.12.4-r15
Chainguard harbor-fips-2.12-portal 0 2.12.4-r12
Chainguard harbor-fips-2.12-redis-compat 0 2.12.4-r12
Chainguard harbor-fips-2.12-registryctl 0 2.12.4-r12
Wolfi harbor-2.11 0 2.11.2-r20
Wolfi harbor-2.11-jobservice 0 2.11.2-r20
Wolfi harbor-2.11-portal 0 2.11.2-r20
Wolfi harbor-2.11-portal-nginx-config 0 2.11.2-r20
Wolfi harbor-2.11-registryctl 0 2.11.2-r20
Wolfi harbor-2.12 0 2.12.4-r13
Wolfi harbor-2.12-jobservice 0 2.12.4-r13
Wolfi harbor-2.12-portal 0 2.12.4-r13
Wolfi harbor-2.12-portal-nginx-config 0 2.12.4-r13
Wolfi harbor-2.12-registryctl 0 2.12.4-r13
openSUSE:Tumbleweed govulncheck-vulndb 0 0.0.20241218T202206-1.1

Related vulnerabilities