Network Security Internet Technology Development Database Servers Mobile Phone Android Software Apple Software Computer Software News IT Information

In addition to Weibo, there is also WeChat

Please pay attention

WeChat public account

Shulou

How does the crawler use Mitmproxy to crack app

2025-04-06 Update From: SLTechnology News&Howtos shulou NAV: SLTechnology News&Howtos > Development >

Share

Shulou(Shulou.com)06/03 Report--

This article will explain in detail how the crawler uses Mitmproxy to crack app. The content of the article is of high quality, so the editor shares it for you as a reference. I hope you will have a certain understanding of the relevant knowledge after reading this article.

Mitmproxy is the proxy,MITM for MITM, or man-in-the-middle attack (Man-in-the-middle attack). The agent used for man-in-the-middle attack will first forward the request like a normal agent to ensure the communication between the server and the client, and then will check and record the intercepted data or tamper with the data in real time, causing the specific behavior of the server or the client.

Using Fiddler, you can filter out browser requests for a particular URL, and view and analyze its data.

However, it can not achieve a highly customized requirement, similar to: "intercept the request to the browser for the URL, leave the returned content empty, and save the real returned content to a database, and send an email notification if an exception occurs". For mitmproxy, this requirement can be easily achieved by loading custom python scripts.

But mitmproxy does not really launch man-in-the-middle attacks against innocent people, because mitmproxy works at the HTTP layer, and the current popularity of HTTPS gives clients the ability to detect and evade man-in-the-middle attacks, so for mitmproxy to work properly, clients (APP or browsers) must actively trust mitmproxy's SSL certificate or ignore certificate exceptions, which means that APP or browser belongs to the developer-obvious This is not in the underground industry, but in development or testing.

At present, it is widely used to simulate crawlers, that is, using mobile phone simulator and headless browser to crawl the data of APP or website. Mitmproxy as an agent can intercept and store the data obtained by the crawler, or modify the data to adjust the behavior of the crawler.

(1) install Python2 and Python3 environment (2) App crawler artifact mitmproxy

Install mitmproxy in Mac/Windows environment

Python3pip3 install mitmproxy or python2pip install mitmproxy (3) button wizard (4) force bag grabbing tool postern

Https://github.com/postern-overwal/postern-stuff

Start mitmproxy

To start mitmproxy, you can use any of the three commands mitmproxy, mitmdump, and mitmweb. These three commands have the same function, and all of them can load custom scripts. The only difference is the difference in the interface.

After the mitmproxy command starts, it provides a command line interface so that the user can see the request in real time, filter the request and view the request data through the command.

Use mitmproxy + python as the intercept agent

Https://www.yisu.com/article/164560.htm

Https://mitmproxy.org/

Set proxy address and port

Then select the proxy method before accessing the address in the browser, and then access it.

Installation certificate

Under normal circumstances, after mitmproxy starts, you can only grab the information requested by HTTP. To capture the information requested by HTTPS, you need to install a certificate. There are two ways to install certificates

If you do not open mitmproxy to grab the package, you will get the following error at this step

If you open mitmproxy to grab the bag

Mitmproxy startup used

Mitmweb startup used

Mitmdump startup used

=

About the crawler how to use Mitmproxy to crack app to share here, I hope the above content can be of some help to you, can learn more knowledge. If you think the article is good, you can share it for more people to see.

Welcome to subscribe "Shulou Technology Information " to get latest news, interesting things and hot topics in the IT industry, and controls the hottest and latest Internet news, technology news and IT industry trends.

Views: 0

*The comments in the above article only represent the author's personal views and do not represent the views and positions of this website. If you have more insights, please feel free to contribute and share.

Share To

Development

Wechat

© 2024 shulou.com SLNews company. All rights reserved.

12
Report