标题: 有没有能把这个js改成php的
时间: 2020-02-17发布,2020-02-17修改
<script>var x="window@59@chars@challenge@Sun@@h@0xEDB88320@@@rOm9XFMtA3QKV7nYsPGT4lifyWwkq5vcjH2IdxUoCbhERLaz81DNB6@@@createElement@https@@join@@12@4P@@substr@document@toLowerCase@return@href@@new@@@V@@Array@@@@location@@toString@23@@charAt@@search@@catch@attachEvent@20@@@Path@@replace@36@D@cookie@captcha@f@match@addEventListener@length@charCodeAt@String@@@1581852239@function@@div@499@6@8@@9FlFf6@0xFF@a@2F@reverse@pathname@16@@e@onreadystatechange@Expires@setTimeout@while@@@firstChild@2@if@@@__jsl_clearance@@GMT@dA@3@false@innerHTML@1500@1@parseInt@@@headless@g@@for@d@@eval@@split@@else@RegExp@@0@JgSe0upZ@try@@var@@fromCharCode@Feb@@DOMContentLoaded".replace(/@*$/,"").split("@"),y="146 71=74(){104('41.28=41.87+41.48.58(/[\\?|&]63-4/,\\'\\')',122);25.62='114=73.77|142|'+(74(){146 71=36(+[((+!+[])+[]+[])+((+!+[])+78+[]+[])]),45=['61',[1.127+[]+[]][142].46((110)*[((+!+[])<<(-~{}<<-~{}))]),'%',([]%!{}+[]+[[]][142]).46((+![]))+[!!1.127+[]][142].46(-~![]-~![])+[!!1.127+[]][142].46(-~![]-~![]),'82',[!+[]+[]+[]][142].46(-~~~{})+[110],'34%85',(-~[]/(+![])+[[]][142]).46((-~![]+[(-~-~{})*[-~-~{}]]>>-~![])),'132',[1.127+[[]][142]][142].46(118),'117',[!+[]+[]+[]][142].46(-~~~{})+[110]+[{}+[]][142].46(-~![]-~![]),'22',[{}+[]+[[]][142]][142].46((+!+[]))+[{}+[]+[[]][142]][142].46((+!+[])),'7',[-~[110]]];131(146 100=142;100<45.67;100++){71.86()[100]=45[100]};27 71.18('')})()+';103=5, 88-150-53 21:44:2 116;56=/;'};111((74(){144{27 !!1.66;}51(101){27 120;}})()){25.66('152',71,120)}138{25.52('102',71)}",f=function(x,y){var a=0,b=0,c=0;x=x.split("");y=y||99;while((a=x.shift())&&(b=a.charCodeAt(0)-77.5))c=(Math.abs(b)<13?(b+48.5):parseInt(a,36))+y*c;return c},z=f(y.match(/\w/g).sort(function(x,y){return f(x)-f(y)}).pop());while(z++)try{eval(y.replace(/\b\w+\b/g, function(y){return x[f(y,z)-1]||("_"+y)}));break}catch(_){}</script>
< script >
var x = "window@59@chars@challenge@Sun@@h@0xEDB88320@@@rOm9XFMtA3QKV7nYsPGT4lifyWwkq5vcjH2IdxUoCbhERLaz81DNB6@@@createElement@https@@join@@12@4P@@substr@document@toLowerCase@return@href@@new@@@V@@Array@@@@location@@toString@23@@charAt@@search@@catch@attachEvent@20@@@Path@@replace@36@D@cookie@captcha@f@match@addEventListener@length@charCodeAt@String@@@1581852239@function@@div@499@6@8@@9FlFf6@0xFF@a@2F@reverse@pathname@16@@e@onreadystatechange@Expires@setTimeout@while@@@firstChild@2@if@@@__jsl_clearance@@GMT@dA@3@false@innerHTML@1500@1@parseInt@@@headless@g@@for@d@@eval@@split@@else@RegExp@@0@JgSe0upZ@try@@var@@fromCharCode@Feb@@DOMContentLoaded".replace(/@*$/, "").split("@"),
y = "146 71=74(){104('41.28=41.87+41.48.58(/[\\?|&]63-4/,\\'\\')',122);25.62='114=73.77|142|'+(74(){146 71=36(+[((+!+[])+[]+[])+((+!+[])+78+[]+[])]),45=['61',[1.127+[]+[]][142].46((110)*[((+!+[])<<(-~{}<<-~{}))]),'%',([]%!{}+[]+[[]][142]).46((+![]))+[!!1.127+[]][142].46(-~![]-~![])+[!!1.127+[]][142].46(-~![]-~![]),'82',[!+[]+[]+[]][142].46(-~~~{})+[110],'34%85',(-~[]/(+![])+[[]][142]).46((-~![]+[(-~-~{})*[-~-~{}]]>>-~![])),'132',[1.127+[[]][142]][142].46(118),'117',[!+[]+[]+[]][142].46(-~~~{})+[110]+[{}+[]][142].46(-~![]-~![]),'22',[{}+[]+[[]][142]][142].46((+!+[]))+[{}+[]+[[]][142]][142].46((+!+[])),'7',[-~[110]]];131(146 100=142;100<45.67;100++){71.86()[100]=45[100]};27 71.18('')})()+';103=5, 88-150-53 21:44:2 116;56=/;'};111((74(){144{27 !!1.66;}51(101){27 120;}})()){25.66('152',71,120)}138{25.52('102',71)}",
f = function(x, y) {
var a = 0,
b = 0,
c = 0;
x = x.split("");
y = y || 99;
while ((a = x.shift()) && (b = a.charCodeAt(0) - 77.5)) c = (Math.abs(b) < 13 ? (b + 48.5) : parseInt(a, 36)) + y * c;
return c
},
z = f(y.match(/\w/g).sort(function(x, y) {
return f(x) - f(y)
}).pop());
while (z++) try {
eval(y.replace(/\b\w+\b/g, function(y) {
return x[f(y, z) - 1] || ("_" + y)
}));
break
} catch (_) {} < /script>
『回复列表(9|隐藏机器人聊天)』
var _71 = function() {
setTimeout(
"location.href=location.pathname+location.search.replace(/[?|&]captcha-challenge/,'')",
1500
);
document.cookie =
"__jsl_clearance=1581852239.499|0|" +
(function() {
var _71 = Array(+[+!+[] + [] + [] + (+!+[] + 6 + [] + [])]),
_45 = [
"D",
[window.headless + [] + []][0].charAt(2 * [+!+[] << (-~{} << -~{})]),
"%",
(([] % !{}) + [] + [[]][0]).charAt(+![]) +
[!!window.headless + []][0].charAt(-~![] - ~![]) +
[!!window.headless + []][0].charAt(-~![] - ~![]),
"9FlFf6",
[!+[] + [] + []][0].charAt(-~~~{}) + [2],
"V%2F",
(-~[] / +![] + [[]][0]).charAt(
(-~![] + [-~-~{} * [-~-~{}]]) >> -~![]
),
"d",
[window.headless + [[]][0]][0].charAt(3),
"dA",
[!+[] + [] + []][0].charAt(-~~~{}) +
[2] +
[{} + []][0].charAt(-~![] - ~![]),
"4P",
[{} + [] + [[]][0]][0].charAt(+!+[]) +
[{} + [] + [[]][0]][0].charAt(+!+[]),
"h",
[-~[2]]
];
for (var _100 = 0; _100 < _45.length; _100++) {
_71.reverse()[_100] = _45[_100];
}
return _71.join("");
})() +
";Expires=Sun, 16-Feb-20 12:23:59 GMT;Path=/;";
};
if (
(function() {
try {
return !!window.addEventListener;
} catch (e) {
return false;
}
})()
) {
document.addEventListener("DOMContentLoaded", _71, false);
} else {
document.attachEvent("onreadystatechange", _71);
}
第二个是如下内容:
var _71 = function() {
setTimeout(
"location.href=location.pathname+location.search.replace(/[?|&]captcha-challenge/,'')",
1500
);
document.cookie =
"__jsl_clearance=1581852239.499|0|" +
(function() {
var _71 = Array(+[+!+[] + [] + [] + (+!+[] + 6 + [] + [])]),
_45 = [
"D",
[window.headless + [] + []][0].charAt(2 * [+!+[] << (-~{} << -~{})]),
"%",
(([] % !{}) + [] + [[]][0]).charAt(+![]) +
[!!window.headless + []][0].charAt(-~![] - ~![]) +
[!!window.headless + []][0].charAt(-~![] - ~![]),
"9FlFf6",
[!+[] + [] + []][0].charAt(-~~~{}) + [2],
"V%2F",
(-~[] / +![] + [[]][0]).charAt(
(-~![] + [-~-~{} * [-~-~{}]]) >> -~![]
),
"d",
[window.headless + [[]][0]][0].charAt(3),
"dA",
[!+[] + [] + []][0].charAt(-~~~{}) +
[2] +
[{} + []][0].charAt(-~![] - ~![]),
"4P",
[{} + [] + [[]][0]][0].charAt(+!+[]) +
[{} + [] + [[]][0]][0].charAt(+!+[]),
"h",
[-~[2]]
];
for (var _100 = 0; _100 < _45.length; _100++) {
_71.reverse()[_100] = _45[_100];
}
return _71.join("");
})() +
";Expires=Sun, 16-Feb-20 12:23:59 GMT;Path=/;";
};
if (
(function() {
try {
return !!window.addEventListener;
} catch (e) {
return false;
}
})()
) {
document.addEventListener("DOMContentLoaded", _71, false);
} else {
document.attachEvent("onreadystatechange", _71);
}
解密方法如图:
认准eval,解密毫无压力。
eval = function(code) { console.log(code); }
// 输入第一段代码(不包括<script>)
// 得到解密后的代码
// 输入第二段代码(不包括<script>)
// 得到解密后的代码
粘贴到代码编辑器里面格式化,搞定。
我才发现,第二个原来就是第一个的美化。。。
你花了这么久调试的其实是程序的自解密代码(也就是程序加的“壳”)。当然,精神可嘉,不过方法不恰当,所以要花的时间更久。
看到eval,就应该想办法先把eval执行的内容拿出来,然后问题很可能就已经解决了。如果拿到eval的内容还没有解决问题,再调试外层代码。