How to use JavaScript to crack the encrypted source code of all webpages

Source: Internet
Author: User

Currently, source code encryption is very popular. source code encryption is applied to authors who want to protect their own resources or to prevent others from discovering that webpages have Trojans.
It's easy to crack it. I just got it done with one trick. Is it just a little exciting? Yes. Come with me! Comeon gogogo!

1/first, let's take a look at the source code of a Web page. In order not to waste everyone's time, I will upload a web page (encrypted) in the free space, in order to let everyone see the results, I am very simple (really very simple) to look at his source code, there are a lot of methods, I casually use
What is this? Is this the legend of the secret? I have a joke. Are you not clear? Let's proceed to step 2!

2/then we will go to the leading role:
Copy codeThe Code is as follows:
Javascript: ssf-document.doc umentElement. outerHTML; document. write ('<body> </body>'); document. body. innerText = s;



This is the code, ah! Very long! Let's see if we can break the original code.
Enter this code in the address bar, or press ctrl + o to enter the code.
This is the case.

<HTML> </HTML>
[Ctrl + A select all Note: If you need to introduce external Js, You need to refresh it to execute]



After
<META http-equiv = Content-Type content = "text/html; charset = gb2312"> </HEAD>
<BODY> hello! </BODY> </HTML>

Have you understood it now!
Principle: No matter how the webpage is encrypted, it will eventually be restored to the htm code that the browser can parse. While documentElement. outerHTML is the result of restoration, isn't it very easy!

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.