当前位置:网站首页>Reptile learning 4 winter vacation series (3)
Reptile learning 4 winter vacation series (3)
2022-07-04 11:20:00 【Kosisi】
Online cloud suppression hot reviews crawl
These two parameters are encrypted , Our task is to simulate the encryption process of Netease cloud , Encryption parameters are passed to the browser .
1) New tools ,call stack Called stack , That is, when I send a request to the file on the left , What are they? js Script execution process , Arranged from bottom to top
2) To set breakpoints , View parameter and variable values
3) Learn to simulate website rendering process through stack
4) Learn to simplify the process of website encryption
Judge whether the parameters can be fixed , If it can be fixed , You can get relevant parameters from the web page , Minimize random parameters .
What we need to do now is to figure out how the program is encrypted .
Out of line
It's too complicated
Don't look at the lack of code , But it's complicated , What is involved . Code is the essence , By fixing parameters , Encrypt the final required parameters ; But finding and implementing this encryption process is very strong . I was confused about this project , Take a break .
It's impossible to estimate the probability just by looking at the code and notes , A face of meng , Of course, we should exclude the great gods #pycrypto Module is to provide encryption algorithm
#base64 Modules are used to convert to bytes , Give Way utf-8 It can be recognized
#json The module is transformed into json String in
The following is the encryption rules obtained from the website following the process , Our task is to understand the principle of encryption , Then we restore the encryption process , The simplification of the tutorial is too strong .
# The encryption process ( The encryption algorithm on the intercepted website )
function a(a=16) {
# Back to c Is random 16 A string
var d, e, b = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ0123456789", c = "";
for (d = 0; a > d; d += 1)# loop 16 Time
e = Math.random() * b.length,# random number
e = Math.floor(e),# integer
c += b.charAt(e);# Take the string xxx Location
return c
}
function b(a, b) {
# a Is the content to be encrypted ,
var c = CryptoJS.enc.Utf8.parse(b) # c yes b, therefore b It's the key
, d = CryptoJS.enc.Utf8.parse("0102030405060708")
, e = CryptoJS.enc.Utf8.parse(a) # e Is the data
, f = CryptoJS.AES.encrypt(e, c, {
# One key is missing ,c It's an encrypted key
iv: d, # Offset
mode: CryptoJS.mode.CBC # Encryption mode CBC
});
return f.toString()
}
function c(a, b, c) {
var d, e;
return setMaxDigits(131),
d = new RSAKeyPair(b,"",c),
e = encryptedString(d, a)
}
function d(d, e, f, g) {
d: data data, e:010001, f: Very long fixed value , g:0CoJUm6Qyw8W8jud
var h = {
} # An empty object
, i = a(16); # i yes 16 Random values of bits
return h.encText = b(d, g), # g It's the key
h.encText = b(h.encText, i), # Back to you params,i It's also a key
h.encSecKey = c(i, e, f), # What you get is encSecKey, So both parameters are obtained
# hold i Hold on , Then the generated parameter is also a fixed value , because i e f Only i Random number , And c() No random numbers
h
# These four sentences are return h, Need to see b() and c()
}
I've seen that the subsequent operation is to clean the crawled information , Then sort out the key hot words , Form hot word posters .
边栏推荐
- Test question bank management system - database design [easy to understand]
- Software testing related resources
- How to deal with the relationship between colleagues
- About the use of URL, href, SRC attributes
- Common built-in modules
- VPS安装Virtualmin面板
- Canoe - the third simulation project - bus simulation-1 overview
- thread
- Postman interface test
- Application of slice
猜你喜欢
F12 clear the cookies of the corresponding web address
Canoe - the third simulation project - bus simulation - 3-1 project implementation
Send a request using paste raw text
2021 annual summary - it seems that I have done everything except studying hard
Automatic translation between Chinese and English
Summary of Shanghai Jiaotong University postgraduate entrance examination module -- cryptography
Canoe - description of common database attributes
Global function Encyclopedia
Deepmind proposed a Zuan AI, which specially outputs network attack language
OSI model notes
随机推荐
Canoe: what is vtsystem
Common built-in modules
If function in SQL
QQ set group information
JMeter correlation technology
Introduction of network security research direction of Shanghai Jiaotong University
Canoe: distinguish VT, VN and vteststudio from their development history
Personal thoughts on the development of game automation protocol testing tool
Summary of automated testing framework
Application of slice
Summary of Shanghai Jiaotong University postgraduate entrance examination module firewall technology
Is Sanli futures safe? How to open a futures account? How to reduce the handling charge of futures at present?
Appscan installation steps
Canoe - the second simulation engineering - xvehicle - 2 panel design (operation)
re. Sub() usage
XMIND installation
Swagger and OpenAPI
守护进程Xinted和日志记录Syslogd
Process communication and thread explanation
Sys module