程序師世界是廣大編程愛好者互助、分享、學習的平台,程序師世界有你更精彩!
首頁
編程語言
C語言|JAVA編程
Python編程
網頁編程
ASP編程|PHP編程
JSP編程
數據庫知識
MYSQL數據庫|SqlServer數據庫
Oracle數據庫|DB2數據庫
您现在的位置: 程式師世界 >> 編程語言 >  >> 更多編程語言 >> Python

Python crawler series of a hi spelling reverse algorithm

編輯:Python

Python A reverse algorithm of the crawler series

The applet crawler receives the order 、app Crawler receiving order 、 Web crawlers receive orders 、 Interface customization 、 Website development 、 Applet development > Click here to contact us <

Please scan the QR code below for wechat

The code is for learning and communication only , Do not use for illegal purposes

Go straight to the code

import execjs
js = '''
function p(e, t) {

var a = (65535 & e) + (65535 & t), n = (e >> 16) + (t >> 16) + (a >> 16);
return n << 16 | 65535 & a;
}
function I(e, t) {

return j(N(e, t));
}
function w(e, t, a) {

return t ? a ? N(t, e) : I(t, e) : a ? C(e) : S(e);
}
function P() {

return (65536 * (1 + Math.random()) | 0).toString(16).substring(1);
}
function T() {

return [ P() + P(), P(), P(), P(), P() + P() + P() + P() ].join("-");
}
var L = {

md5: w,
genGuid: T
}
function sign(a){

let n, r = getSignString(a);
let signStr = r
return signStr;
}
'''
ctx = execjs.compile(js)
def getSign(data):
'''
Signature method
:param data: Signature parameter ( Dictionaries )
:return:
'''
signStr = ctx.call("sign", data)
return signStr
if __name__ == '__main__':
# Signature parameter
data = {
"longitude": 106.56641, "latitude": 24.85152, "buid": 325, "time": 1621413926788}
data = {
"buid": 325, "time": 1621416028888}
print(getSign(data))

  1. 上一篇文章:
  2. 下一篇文章:
Copyright © 程式師世界 All Rights Reserved