Gunicorn
Green Unicorn
A Python app server that runs Django and Flask apps behind a front end such as nginx.
Where It Sits
The small stack marks its layer. Beside it, each related technology links to its own page.
- App
- Framework
- Web ServerGunicorn
- Runtime
- Containers
- OS
- Hypervisor
- Firmware
- Hardware
- Data
About
Gunicorn is an app server for Python. It starts a set of worker processes that run the app's code and answer the requests a front end hands them. Django and Flask apps often run on it with nginx in front, as its own guide strongly recommends. It runs only on Unix-like systems such as Linux.
How to Spot It
These are signs that a system runs Gunicorn, seen from outside without signing in, such as a response header, a cookie, a path or a default port. They help you find where it runs across your own estate. A version shown to the world also tells anyone scanning which flaws might apply, so it is worth hiding.
- Response header (reached directly)
Server: gunicorn- Default port
8000 (bound to the machine itself by default)
If It Has a Flaw
Gunicorn runs the app's code in its workers, so a flaw in it reaches the app and everything the app can touch. Its guide says to keep it behind a proxy such as nginx, which shields it from slow clients. Version 22.0.0 closed request smuggling gaps, CVE-2024-1135 among them, where the front end and Gunicorn could read one request differently.
A flaw exposes what runs on it and the data it reaches.
- Framework and Libraries
Django
- Data
PostgreSQL
Rivals
Rivals do the same job on the same layer, so a system usually runs one of them in any one place. A flaw in a rival does not reach Gunicorn.
Stacks and Code
Gunicorn is part of the common stacks below, and each stack's page shows who runs every layer. Its code arrives from the sources listed, and each source's page says how bad code could get in through it.
- In Common Stacks
- A Django App
- Its Code Comes From
PyPI