← 回總覽

利用 CDP 与浏览器控制台绕过 API 签名校验的技术实现

📅 2026-03-15 09:42 yan5xu 人工智能 3 分鐘 3163 字 評分: 86
CDP Agent 爬虫技术 小红书逆向 浏览器自动化
📌 一句话摘要 通过 CDP 在浏览器控制台直接调用网页内部方法和 fetch,实现绕过复杂签名算法的数据抓取。 📝 详细摘要 作者分享了一种巧妙的 Agent 操作网页思路:通过 CDP (Chrome DevTools Protocol) 在浏览器控制台直接调用 `fetch` 或网页内部的 Vue Store 方法。这种方法在处理如小红书等具有复杂签名算法的平台时,可以避开繁琐的逆向工程,直接利用浏览器已有的登录态和内部逻辑来“解锁”并获取数据,本质上是让网页逻辑为 Agent 所用。 📊 文章信息 AI 评分:86 来源:yan5xu(@yan5xu) 作者:yan5xu 分类:
Skip to main content ![Image 1: LogoBestBlogs](https://www.bestblogs.dev/ "BestBlogs.dev")Toggle navigation menu Toggle navigation menuArticlesPodcastsVideosTweetsSourcesNewsletters

⌘K

Change language Switch ThemeSign In

Narrow Mode

Bypassing API Signature Verification with CDP and Browser Console =================================================================

Bypassing API Signature Verification with CDP and Browser Console ================================================================= ![Image 2: yan5xu](https://www.bestblogs.dev/en/tweets?sourceId=SOURCE_e332a8ea) ### yan5xu

@yan5xu

我之前也没想到,让 agent 通过 cdp 操作网页和直接用 js 使用 api 在我脑子里一直是分开的,知道我昨天看 @jakevin7 的 twitter-cli,里面有很多内容其实在做登录态的处理,然后脑子里立马就蹦出来,我cdp 开一个网页,然后在 console 里面用浏览器的 fetch,这些问题岂不是都没了。然后试一把,发现卧槽能行。就开干了。

特别是在做小红书的时候,小红书有一套签名算法,正常路线是要做逆向,我和 claude code 讨论之后发现直接调用小红书自己的 Vue Store 方法触发请求,同时 hook XHR 截获原始 API 响应😂就是拿小红书自己来解锁自己。github.com/epiral/bb-site…s

Mar 15, 2026, 1:42 AM View on X

3 Replies

5 Retweets

39 Likes

2,371 Views ![Image 3: yan5xu](https://www.bestblogs.dev/en/tweets?sourceid=e332a8ea) yan5xu @yan5xu

One Sentence Summary

By directly calling internal web page methods and fetch in the browser console via CDP, complex signature algorithms can be bypassed for data scraping.

Summary

The author shares an ingenious approach for Agent-driven web page interaction: directly invoking fetch or internal Vue Store methods within the browser console via CDP (Chrome DevTools Protocol). This method allows bypassing tedious reverse engineering when dealing with platforms like Xiaohongshu, which employ complex signature algorithms. Essentially, it leverages the browser's existing login state and internal logic to 'unlock' and retrieve data, turning the web page's own logic to the Agent's advantage.

AI Score

86

Influence Score 17

Published At Today

Language

Chinese

Tags

CDP

Agent

Web Scraping

Xiaohongshu Reverse Engineering

Browser Automation HomeArticlesPodcastsVideosTweets

Bypassing API Signature Verification with CDP and Browser... ===============

查看原文 → 發佈: 2026-03-15 09:42:52 收錄: 2026-03-15 14:01:02

🤖 問 AI

針對這篇文章提問,AI 會根據文章內容回答。按 Ctrl+Enter 送出。