更新 傻狗阅读_api.py
This commit is contained in:
parent
c76c2ea328
commit
1188f9a863
23
傻狗阅读_api.py
23
傻狗阅读_api.py
@ -52,7 +52,7 @@ from notify import send
|
||||
|
||||
logging.basicConfig(level=logging.INFO, format='[%(levelname)s] ===> %(message)s')
|
||||
code = "傻狗阅读_api版"
|
||||
ver = "1.2"
|
||||
ver = "1.3"
|
||||
envname = "yuanshen_api"
|
||||
|
||||
debug = False #debug模式 开启即从脚本内部获取环境变量
|
||||
@ -390,15 +390,16 @@ class yuanshen:
|
||||
if r['success']:
|
||||
logging.info('参数被加密 进行解密操作')
|
||||
code = r["decodedCode"]
|
||||
regex = r"a\((['\"])(.*?)\1,\s*(['\"])(.*?)\3,\s*(['\"])(.*?)\5\)"
|
||||
matches = re.findall(regex, code)
|
||||
if matches:
|
||||
for match in matches:
|
||||
param1, param2, param3 = match[1], match[3], match[5]
|
||||
print("参数1:", param1)
|
||||
print("参数2:", param2)
|
||||
print("参数3:", param3)
|
||||
self.read_session = param2
|
||||
t = re.findall(r'"(.*?)"', code)
|
||||
|
||||
if t:
|
||||
p1, p2, p3,p4 = t[0], t[1], t[2], t[3]
|
||||
print("参数1:", p1)
|
||||
print("参数2:", p2)
|
||||
print("参数3:", p3)
|
||||
print("参数4:", p4)
|
||||
self.read_session = p2
|
||||
self.magicnumber = p4
|
||||
|
||||
else:
|
||||
print("没有匹配到调用")
|
||||
@ -451,7 +452,7 @@ class yuanshen:
|
||||
"sign": sign,
|
||||
"time": timestamp
|
||||
}
|
||||
url = f'https://api.yd.dgtech.top/ydrw/article?_t={timestamp}'
|
||||
url = f'https://api.yd.dgtech.top/ydrw/{self.magicnumber}?_t={timestamp}'
|
||||
r = requests.post(url,json=data,headers=self.readh).json()
|
||||
if r['success']:
|
||||
self.readurl = r['data']['url']
|
||||
|
||||
Loading…
Reference in New Issue
Block a user