Description
bin/compile-messages.py in Django 0.95 does not quote argument strings before invoking the msgfmt program through the os.system function, which allows attackers to execute arbitrary commands via shell metacharacters in a (1) .po or (2) .mo file.
Fixed in Linux distributions
Distributions backport fixes, so the version that fixes this vulnerability differs per release — upgrade to at least the version shown. From the distributions' security trackers and advisories.
Debian
Security tracker ↗| Release | Package | Fixed in | Advisory |
|---|---|---|---|
| Debian 14 | python-django | 0.95.1-1 | — |
| Debian 13 | python-django | 0.95.1-1 | — |
| Debian 12 | python-django | 0.95.1-1 | — |
Affected packages
| Ecosystem | Package | Affected | Fixed | Record |
|---|---|---|---|---|
| PyPI | django | >= 0.95, < 1.0 | 1.0 | GHSA-qc99-g3wm-hgxr |
References
- django-po-code-execution(31627) vdb-entry
- 23826 third-party-advisory
- http://code.djangoproject.com/changeset/3592
- 22134 vdb-entry