RSSHub icon indicating copy to clipboard operation
RSSHub copied to clipboard

Bilibili UP 主所有视频,似乎即使自建也容易触发反爬

Open NightSpaceC opened this issue 3 years ago • 2 comments

路由地址

/bilibili/user/video-all/:uid/:disableEmbed?

完整路由地址

/bilibili/user/video-all/335098315
/bilibili/user/video-all/436361287

相关文档

https://docs.rsshub.app/social-media.html#bilibili

预期是什么?

正常返回RSS数据

实际发生了什么?

当访问第二条地址时,RSSHub报错

另外,访问两条地址后,浏览器可以正常浏览有关网页(已禁用缓存),但Python爬虫库requests_html调用有关API时会返回412

部署

自建

部署相关信息

Windows, Node: v18.7.0

额外信息

Route requested: /user/video-all/436361288
Error message: Response code 412 (Precondition Failed): target website might be blocking our access, you can host your own RSSHub instance for a better usability.
Helpful Information to provide when opening issue:
Path: /user/video-all/436361288
Node version: v18.7.0
Git Hash: 6b34eb8

这不是重复的 issue

  • [x] 我已经搜索了现有 issue,以确保该错误尚未被报告。

NightSpaceC avatar Aug 17 '22 08:08 NightSpaceC

Searching for maintainers:
  • /bilibili/user/video-all/:uid/:disableEmbed?: @CcccFz

To maintainers: if you are not willing to be disturbed, list your username in scripts/workflow/test-issue/call-maintainer.js. In this way, your username will be wrapped in an inline code block when tagged so you will not be notified.

如果有任何路由无法匹配,issue 将会被自动关闭。如果 issue 和路由无关,请使用 NOROUTE 关键词,或者留下评论。我们会重新审核。 If there is any route not found, the issue will be closed automatically. Please use NOROUTE for a route-irrelevant issue or leave a comment if it is a mistake.

github-actions[bot] avatar Aug 17 '22 08:08 github-actions[bot]

@cyx20080216 感谢您使用此路由,并指出该问题,我将在近期修复该问题

CcccFz avatar Aug 17 '22 15:08 CcccFz

@cyx20080216 B站反爬太严,/bilibili/user/video/335098315仅获取单页的视频也会被限制。待认识的爬虫高人有空时,为我指导一二

CcccFz avatar Sep 23 '22 14:09 CcccFz

知道了,谢谢,我最近也遇到了这种情况

NightSpaceC avatar Sep 24 '22 09:09 NightSpaceC

刚刚测试了一下,似乎可以通过先访问https://www.bilibili.com/获取Cookie,请求API时再带上来在一定程度上解决获取单页视频时受到的限制

NightSpaceC avatar Sep 24 '22 10:09 NightSpaceC