返回ajax内容加密,js逆向破解
def bet_decode(text): code = text.split(';')[1].split('=')[1] e = ord(code[0]) ^ ord(code[1]) result = [] for x in text.split(';'): if 'OD' not in x: result.append(x) else: od = x.split('=', maxsplit=1)[1] new_od = ''.join([chr(ord(s) ^ ord(chr(e)[0])) for s in od]) if od.strip() else '' result.append(f'OD={new_od}') return ';'.join(result)