CVE-2024-39877 Apache Airflow: DAG Author Code Execution possibility in airflow-scheduler

High 8.8 Published Updated

Authenticated DAG authors can execute arbitrary code in the scheduler context via crafted doc_md parameters, requiring an upgrade to secure the system.

Exploited in the wild
Not known
Login needed
Any signed-in user
Attackable
Over the internet
Victim action needed
Not needed
Fix
Available

What is CVE-2024-39877?

CVE-2024-39877 is a high-severity code injection vulnerability in Apache Airflow, published on 17 Jul 2024. Any signed-in user can exploit it over the network, with no action from the victim.

Official description

Apache Airflow 2.4.0, and versions before 2.9.3, has a vulnerability that allows authenticated DAG authors to craft a doc_md parameter in a way that could execute arbitrary code in the scheduler context, which should be forbidden according to the Airflow Security model. Users should upgrade to version 2.9.3 or later which has removed the vulnerability.

Weakness: CWE-277, CWE-94

Which versions are affected by CVE-2024-39877?

4 open source packages ship an affected version, including apache-airflow and airflow. It affects 1 product.

PackageAffectedFixed in
apache-airflow PyPIFrom 2.4.02.9.3
apache-airflow PyPIFrom 2.4.02.9.3
apache-airflow PyPIFrom 2.4.02.9.3
airflow BitnamiFrom 2.4.02.9.3

Products include Apache Airflow.

How do I fix CVE-2024-39877?

Upgrade apache-airflow to 2.9.3 or later.

Upgrade, and never evaluate templates, expressions or code built from user input. More about Code injection.

Is CVE-2024-39877 being exploited?

It is not confirmed as exploited in the wild, but public exploit code for CVE-2024-39877 exists.

All Apache Airflow vulnerabilities

Sources

Also known as BIT-airflow-2024-39877, ECHO-f127-5150-e1e6, GHSA-g5hv-r743-v8pm, PYSEC-2024-190.

Is CVE-2024-39877 in your software?

Upload an SBOM and sbomify checks it against every vulnerability here, every day.

Check your SBOMs for free