CVE-2023-49920: Apache Airflow: Missing CSRF protection on DAG/trigger
Apache Airflow versions 2.7.0 to 2.7.3 allowed triggering a DAG via a GET request without CSRF validation. An attacker could trick a logged-in user into executing a DAG unintentionally by visiting a malicious website.
- Triaged in 12 days
- Fixed in 19 days
- Paid in 19 days
- Disclosed after 19 days
Summary by the program
CVE-2023-49920: Apache Airflow: Missing CSRF protection on DAG/trigger Severity: moderate
Affected versions:
- Apache Airflow 2.7.0 before 2.8.0
Description: Apache Airflow, version 2.7.0 through 2.7.3, has a vulnerability that allows an attacker to trigger a DAG in a GET request without CSRF validation. As a result, it was possible for a malicious website opened in the same browser - by the user who also had Airflow UI opened - to trigger the execution of DAGs without the user's consent. Users are advised to upgrade to version 2.8.0 or later which is not affected
Credit: Tareq Ahamed ( 0xt4req) (finder) Jens Scheffler (remediation developer)
Full Security Advisory: https://lists.apache.org/thread/mnwd2vcfw3gms6ft6kl951vfbqrxsnjq
The report
During my testing, I've found that there is no CSRF protection in dag/trigger. If a user is logged in to his airflow account & has the permission to trigger a dag then an attacker can trick the user to run a dag unintentionally by the user.
Apache Airflow, version 2.7.0 through 2.7.3, has a vulnerability that allows an attacker to trigger a DAG in a GET request without CSRF validation. As a result, it was possible for a malicious website opened in the same browser - by the user who also had Airflow UI opened - to trigger the execution of DAGs without the user's consent. Users are advised to upgrade to version 2.8.0 or later which is not affected
Details:
https://lists.apache.org/thread/mnwd2vcfw3gms6ft6kl951vfbqrxsnjq
Email form the project maintainer
███████
Regards, @0xt4req
Impact
It was possible for a malicious website opened in the same browser - by the user who also had Airflow UI opened - to trigger the execution of DAGs without the user's consent
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
How it worked
Root cause
The DAG trigger endpoint accepted GET requests and did not validate a CSRF token, so any request from a logged-in user's browser could trigger a DAG.
Impact
An attacker could cause a logged-in user with permission to trigger a DAG to execute it without consent, potentially leading to unwanted actions or resource use.
What the attacker needed
Victim logged into Airflow; victim has permission to trigger a DAG; victim visits a malicious website
The fix
Upgrade to Apache Airflow 2.8.0 or later, which is not affected.
Explained by bugbounty.wiki with AI from the original and checked against quotes from it; it can still be wrong. Read the original before relying on a detail.
Not written yet. The AI write-up for this report has not been written yet. The Original tab links to the source.
CSRF (Cross-Site Request Forgery) is when a malicious website makes your browser send a request to another site where you are logged in, without your knowledge. Here, the Airflow web interface accepted a simple link (GET request) to start a data pipeline (DAG) without checking that the request came from the real Airflow page. So if you were logged in and visited a bad site, it could start a pipeline for you.
What is CSRF?
Another site makes a signed-in user's browser perform an action they did not intend.