目标达成 感谢每一位支持者 — 我们达成了 100% 目标!

目标: 1000 元 · 已筹: 1359 元

100%

CVE-2019-6340 PoC — Drupal 输入验证错误漏洞

来源
关联漏洞
标题: Drupal 输入验证错误漏洞 (CVE-2019-6340)
Description:Drupal是Drupal社区的一套使用PHP语言开发的开源内容管理系统。 Drupal 8.5.11之前的8.5.x版本和Drupal 8.6.10之前的8.6.x版本中存在输入验证漏洞,该漏洞源于一些字段类型没有正确地过滤数据。远程攻击者可利用该漏洞执行代码。
介绍
# Research

CVE 2019-6340


    The site as Drupal 8 core RESTful API Services module gets enabled and allows the user to send GET, PATCH or POST Request to the server. 
    
    (GET request is enough to trigger the code execution vulnerability even though PATCH method is disabled)
    
    The site has any other web services module enabled like JSON-API in Drupal 8 or REST services in Drupal 7.


REQUIREMENTS FOR POC

DOCKER.IO

DRUPAL 8.6.9

SQL 5.7

docker run -d  --name mysqldb -e MYSQL_ROOT_PASSWORD=password  mysql:5.7


docker run -d  --name drupal  --link mysqldb -p 8090:80  -e MY_SQL_USER:root -e MY_SQL_PASSWORD:password drupal:8.6.9 


exp run command

python3 exp.py http://Ip_of_drupal_container:port_assigned(if)// "command_to_execuite"




example:- python3 exp.py http://127.0.0.1:8090/ "hostname -I"



EXP ANALYSIS 

Guzzle is a PHP HTTP client that makes it easy to send HTTP requests and trivial to integrate with web services and it used as a exploit to send malicous request to drupal based websites. if we analyse the guzzle script inside exploit code(exp.py) then we can find that a "command" string is replaced with the command that we pass at runtime (eg hostname -I)


![exp](https://user-images.githubusercontent.com/126046383/220545661-f192137f-6c08-4e77-9017-632f9b21e705.png)

when we run exp command first it will look for an existing node so we have to make some nodes on our website ,basically you have add some content on the website

![drupal](https://user-images.githubusercontent.com/126046383/220547340-5bfe3bee-4d7a-4184-a981-6252b731a87f.png)

it will not access any node twice suppose you have added 5 nodes ,so after running your exploit 5 times you have to update your nodes
simply go to content and appy any action on the nodes












REQUEST AND RESPONSE 


![req](https://user-images.githubusercontent.com/126046383/220545688-a1b02910-28e3-4eba-9a87-a8df1f8fde56.png)



![res](https://user-images.githubusercontent.com/126046383/220539690-8682df02-f209-4fb3-9176-76514367cb6a.png)







文件快照

登录后查看神龙缓存的 POC 文件快照

登录查看
备注
    1. 建议优先通过来源进行访问。
    2. 本地 POC 快照面向订阅用户开放;当原始来源失效或无法访问时,本地镜像作为订阅权益的一部分提供。
    3. 持续抓取、验证、维护这份 POC 档案需要不少投入,因此本地快照已纳入付费订阅。您的订阅是让这份资料能继续走下去的关键,由衷感谢。 查看订阅方案 →