更新文档

This commit is contained in:
luzhisheng 2024-01-13 21:29:36 +08:00
parent 3d6f24b18f
commit fefa50117c
5 changed files with 20 additions and 85 deletions

View File

@ -0,0 +1,3 @@
文档地址
https://blog.csdn.net/u010226586/article/details/135564308

View File

@ -1,5 +0,0 @@
js逆向知识-Ja3指纹学习
https://blog.csdn.net/weixin_43411585/article/details/122314214
https://jishuin.proginn.com/p/763bfbd73fc3

View File

@ -0,0 +1,10 @@
from curl_cffi import requests
headers = {
'cookie': 'sessionid=xxxxxxxxx;'
}
# 注意这个 impersonate 参数,指定了模拟哪个浏览器
r = requests.get("https://match.yuanrenxue.cn/api/match/19?page=3", headers=headers, impersonate="chrome101")
print(r.json())

View File

@ -1,45 +1,12 @@
import requests
import json
from requests.adapters import HTTPAdapter
from requests.packages.urllib3.util.ssl_ import create_urllib3_context
CIPHERS = (
'ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:RSA+3DES:!aNULL:'
'!eNULL:!MD5'
)
url = "https://match.yuanrenxue.cn/api/match/19?page=1"
payload = {}
headers = {
'cookie': 'sessionid=ieirkmfqa2qsj29uapsh4bdaj59vggj2;'
}
class DESAdapter(HTTPAdapter):
def init_poolmanager(self, *args, **kwargs):
context = create_urllib3_context(ciphers=CIPHERS)
kwargs['ssl_context'] = context
return super(DESAdapter, self).init_poolmanager(*args, **kwargs)
response = requests.request("GET", url, headers=headers, data=payload)
def proxy_manager_for(self, *args, **kwargs):
context = create_urllib3_context(ciphers=CIPHERS)
kwargs['ssl_context'] = context
return super(DESAdapter, self).proxy_manager_for(*args, **kwargs)
s = requests.Session()
s.mount('https://match.yuanrenxue.com', DESAdapter())
def get_num(s):
num = 0
for i in range(1, 6):
url = f"https://match.yuanrenxue.com/api/match/19?page={i}"
Headers = {
"user-agent": "yuanrenxue.project",
"cookie": "sessionid=8rrqpz36de5lnyebo9jfg4bkzkda7vgt;"
}
res = s.get(url=url, headers=Headers)
res_dict = json.loads(res.text)
print(res_dict)
data = res_dict.get('data')
for i in data:
num += i['value']
print(num)
get_num(s)
print(response.text)

View File

@ -1,40 +0,0 @@
from requests.adapters import HTTPAdapter
from requests.packages.urllib3.util.ssl_ import create_urllib3_context
import random
ORIGIN_CIPHERS = ('ECDH+AESGCM:DH+AESGCM:ECDH+AES256:DH+AES256:ECDH+AES128:DH+AES:ECDH+HIGH:'
'DH+HIGH:ECDH+3DES:DH+3DES:RSA+AESGCM:RSA+AES:RSA+HIGH:RSA+3DES')
class DESAdapter(HTTPAdapter):
def __init__(self, *args, **kwargs):
"""
A TransportAdapter that re-enables 3DES support in Requests.
"""
CIPHERS = ORIGIN_CIPHERS.split(':')
random.shuffle(CIPHERS)
CIPHERS = ':'.join(CIPHERS)
self.CIPHERS = CIPHERS + ':!aNULL:!eNULL:!MD5'
super().__init__(*args, **kwargs)
def init_poolmanager(self, *args, **kwargs):
context = create_urllib3_context(ciphers=self.CIPHERS)
kwargs['ssl_context'] = context
return super(DESAdapter, self).init_poolmanager(*args, **kwargs)
def proxy_manager_for(self, *args, **kwargs):
context = create_urllib3_context(ciphers=self.CIPHERS)
kwargs['ssl_context'] = context
return super(DESAdapter, self).proxy_manager_for(*args, **kwargs)
import requests
headers = {'User-Agent': 'Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/537.36 (KHTML, like Gecko)'
' Chrome/92.0.4515.131 Safari/537.36 Edg/92.0.902.67'}
s = requests.Session()
s.headers.update(headers)
for _ in range(5):
s.mount('https://ja3er.com', DESAdapter())
resp = s.get('https://ja3er.com/json').json()
print(resp)