[英]Decoding an encrypted HTML file using Javascript
I am trying to decrypt the encrypted page source of an HTML file. 我正在尝试解密HTML文件的加密页面源。 I am serching for a decoding trick to decrypt a page containing facebook interface UI.
我正在寻找一种解码技巧来解密包含Facebook界面UI的页面。 It is in the following post decrypted facebook Ui page .
它在以下帖子解密的Facebook Ui页面中 。 The demo page of that post is encrypted.
该帖子的演示页面已加密。 Is there any posible way to decrypt it?
有什么可行的解密方法吗?
The code looks like this: 代码如下:
document.write(unescape("..."));
Copy the unescape("...")
part. 复制
unescape("...")
部分。 Go to JSFiddle . 转到JSFiddle 。 In the JavaScript area, type alert( , paste, and then type );
在JavaScript区域中,输入alert( ,粘贴,然后键入); .
。 Press run.
按运行。
The "encrypted" (not) source will be alert
ed. “已加密”(未)源将被
alert
。 You can copy and paste that into your text editor of choice to start analyzing it. 您可以将其复制并粘贴到所选的文本编辑器中,以开始对其进行分析。
By the way, the decrypted code looks pretty bad. 顺便说一下,解密后的代码看起来很糟糕。 I wouldn't want to learn from that.
我不想从中学到东西。
You can't "decrypt" it back to the original source at this point. 您目前无法将其“解密”回原始源。 It is "obfuscated" to the point it's not really easy to read anymore.
它被“混淆”到不再真正容易阅读的地步。
You can deminify it to make it a little easier to read by using a JavaScript deminifer/deobfuscator as discussed in the SO question Is there such a thing as a javascript deminifier (deobfuscator)? 您可以使用SO的问题中所讨论的JavaScript deminifer / deobfuscator对其进行去元素化处理,以使其更易于阅读。 是否存在诸如javascript deminifier(deobfuscator)之类的东西? JS Beautifier is one good one.
JS Beautifier是一个不错的选择。
You could also use a debugger like a browser plugin like Firebug (though it doesn't deobfuscate/deminify without plugins) or use the latest version of Google Chrome which provides one built-in. 您还可以使用调试器,例如Firebug之类的浏览器插件(尽管在没有插件的情况下它不会进行模糊处理/去杂化),也可以使用提供了内置功能的最新版Google Chrome。 In Chrome:
在Chrome中:
This still won't make it very easy to read since the author has obfuscated it pretty good. 由于作者对其进行了很好的模糊处理,因此它仍然很难读懂。 You're going to have to walk through it line by line and rebuild the script yourself if you want to go through all that trouble.
如果您想解决所有麻烦,则必须逐行浏览并自行重建脚本。
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.