Inventory of common python hacking techniques (1) super simple

Inventory of common python hacking techniques (1) super simple

 

As one of the current mainstream programming languages, python has a user-friendly grammar and a large number of third-party libraries. It is currently mainly used in fields such as web crawlers, web development, data analysis, and artificial intelligence, covering a wide range of areas. But I think back to my original intention of learning python to be a hacker. I also want to be like Neo in "The Matrix", galloping on the "network battlefield" and invincible.

Inventory of common python hacking techniques (1) super simple

However, the reality is always cruel. When I try to learn hacking techniques, there is always an invisible energy that prevents me from making progress (actually I am lazy), leading me to learn to learn and become a young man.

Inventory of common python hacking techniques (1) super simple

(The picture comes from the Internet, in fact, the editor still has a bit of beauty)

In order to let friends who are learning python find some learning fun and sense of accomplishment, or let single friends show off to the goddess, I decided to share my "semi-finished products" of learning hacking with everyone. , I'm thin-skinned

Inventory of common python hacking techniques (1) super simple

Closer to home, here are 3 small examples to give you an inventory of common python hacking techniques:

One, brute force zip

You can use the zipfile library that comes with pyhton. First, you need to have a password dictionary, which can be generated by yourself or downloaded from the Internet. This time I will take the brute force cracking of a compressed package with a 6-digit compression password as an example. code show as below:

Inventory of common python hacking techniques (1) super simple

Here I directly start brute force cracking directly in the for loop. The 6-digit password at the beginning of 1 totals 20 seconds. According to this calculation, the 12-digit password will be completed in 40 seconds. It seems too simple, but it always feels a bit weird.

In theory, as long as your computer is fast enough and the dictionary is powerful enough, you can crack any encrypted compressed package (just theoretically, don’t take it seriously).

2. Keylogger

Keylogging is an ancient hacking technique, and it is still widely used at different levels. It is so extensive that I still rely on this technique to write tweets. I am really ashamed.

Inventory of common python hacking techniques (1) super simple

There are many ways to implement keylogger, here is a way for everyone

Inventory of common python hacking techniques (1) super simple

There are a total of 6 lines of code. It feels that it is not the best among many methods, but it is the most refined (or the most wasteful).

Inventory of common python hacking techniques (1) super simple

Inventory of common python hacking techniques (1) super simple

After a mess of percussion, it feels like all poems come out casually, hahaha, please call me a talent.

Three, secretly intercepted your screen

Most penetration testing frameworks and malware have the ability to take screenshots of remote targets. It can help us capture opened pictures, or other sensitive information (so don't just install unknown software).

Some screen capture software only captures the image of the currently active window or application, but this time we will capture the entire screen. The main code is as follows:

Inventory of common python hacking techniques (1) super simple

Let’s show you the results:

Inventory of common python hacking techniques (1) super simple

Is it amazing

Well, today’s sharing ends here. I don’t know if you in front of the mobile phone can learn like I did before.

ps: The content of this article is only used for learning and communication, not illegal things

You need the code in this article to follow the editor and apply for the QQ group: 721195303 for free

Guess you like

Origin blog.csdn.net/aaahtml/article/details/114358786