TL;DR#
-
Use Alist to mount Baidu Cloud Disk.
-
Connect Alist to Infuse via WebDAV.
-
Use Surge to add User-Agent: pan.baidu.com for ^*baidupcs.com.
[Header Rewrite] http-request ^*baidupcs.com header-add User-Agent pan.baidu.com
Intro#
Currently, Infuse officially supports mounting via WebDAV, OneDrive, Alibaba Cloud Disk, etc., but does not support direct mounting of Baidu Cloud Disk.
Although Alibaba Cloud Disk has many resources, the limitation on online playback speed makes it undesirable to spend more money on a membership.
Baidu Cloud Disk also has a lot of resources, and some missing resources can be supplemented through offline downloads, along with excellent playback and download speeds. Most importantly, having an active Baidu Cloud Disk membership is essential, and if it can still be utilized, why not?
Pitfalls#
With this idea in mind, I first sought help in the official Infuse group, but it seems that no one had the need to mount Baidu Cloud Disk with Infuse; perhaps the demand is too niche, and there was no relevant discussion, so I gave up.
Considering that VidHub has already provided direct mounting for Baidu Cloud Disk, and since Infuse already supports Alibaba Cloud Disk, supporting Baidu Cloud Disk should not be too difficult. Therefore, I sent an email to the Infuse team and received the following reply:
It seems that official support may be a long way off.
Finding an Alternative#
I had long known that Alist could be used to mount Baidu Cloud Disk and then connect it to Infuse via WebDAV.
For Baidu Cloud Disk members, Alist officially provides two methods for online playback.
- Modify UA for normal playback.
- Local proxy, requiring a server with high traffic and bandwidth.
As is well known, Infuse cannot modify UA, so initially, I turned my attention to the second option. However, I found that speed was an issue, and the traffic consumption on the server was also a problem, so I had to give up.
A few days later, I mentioned this to another Infuse user and learned that network tools could be used to modify UA. Suddenly, I thought of Surge, which I use daily, and decided to give it a try.
After adding the following content to Surge's configuration file, I successfully achieved online playback:
[Header Rewrite]
http-request ^*baidupcs.com header-add User-Agent pan.baidu.com
Outro#
- This is actually a very simple matter, but it seems there is not much discussion about it online. A user on the linux.do forum raised the same question but received no answer, so I am publishing this method to save time for others.
- For Apple TV users, Surge should also be able to take over Infuse's traffic, which is worth trying.
This article is synchronized and updated to xLog by Mix Space. The original link is https://xxu.do/posts/geek/mount-BaiduNetdisk-on-infuse