Django is vulnerable to Denial of Service (DoS)
53
Medium Risk
Django's check_for_language helper caches each checked language code as a key in an in-memory translation cache. When the set_language view is routed, externally supplied POST data can submit many distinct, very long language codes that are retained as cache keys and consume process memory. This enables a denial-of-service condition, though the impact is bounded by the request size limit and the cache's maximum entry count. The fix rejects language codes longer than 500 characters before the cached lookup.
You are affected if you are using a version that falls within the vulnerable range and your application explicitly routes the django.views.i18n.set_language view.
Django is vulnerable to Denial of Service (DoS) in versions 5.2.0 - 5.2.16 and 6.0.0 - 6.0.7.
Upgrade the Django library to the patch version.
Connect your repositories to instantly see whether vulnerable or malicious packages exist in your codebase.
Free. No credit card required.

I consent to receiving marketing communications based on Aikido’s Privacy Policy.
SOC 2Compliant
ISO 27001Compliant