From 111de2f4b04a993abd36b506a9d84d3e3ca2e6e8 Mon Sep 17 00:00:00 2001 From: aiyingfeng Date: Thu, 3 Aug 2023 18:38:14 +0800 Subject: [PATCH] =?UTF-8?q?pc=5F=E6=8A=96=E9=9F=B3=E7=A0=B4=E8=A7=A3?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../pc_抖音破解/spider/douyin_aweme_v1_web_discover_search.py | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/抖音js逆向学习/pc_抖音破解/spider/douyin_aweme_v1_web_discover_search.py b/抖音js逆向学习/pc_抖音破解/spider/douyin_aweme_v1_web_discover_search.py index e1851a4..67dae35 100644 --- a/抖音js逆向学习/pc_抖音破解/spider/douyin_aweme_v1_web_discover_search.py +++ b/抖音js逆向学习/pc_抖音破解/spider/douyin_aweme_v1_web_discover_search.py @@ -1,4 +1,4 @@ -from douyin_search import get_ttwid, get_ac_nonce +from douyin_search import get_ttwid, get_ac_nonce, get_ac_signature from urllib.parse import quote import requests @@ -1007,7 +1007,8 @@ for search_keyword in keyword_list: print(search_keyword) encoded_text = quote(search_keyword) __ac_nonce = get_ac_nonce(encoded_text) - ttwid = get_ttwid(__ac_nonce, encoded_text) + __ac_signature = get_ac_signature(encoded_text) + ttwid = get_ttwid(__ac_nonce, __ac_signature, encoded_text) url = f"https://www.douyin.com/aweme/v1/web/discover/search/?device_platform=webapp&aid=6383&channel=channel_pc_web&" \ f"search_channel=aweme_user_web&keyword={encoded_text}&search_source=switch_tab&" \ f"query_correct_type=1&is_filter_search=0&from_group_id=&offset=0&count=10&pc_client_type=1&" \