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 for WebDAV, OneDrive, Alibaba Cloud Disk, etc., but does not support direct mounting of Baidu Cloud Disk.
Although Alibaba Cloud Disk has many resources, due to the limitations on online playback speed, I am not keen on spending more money to open a membership, so I gave up.
Baidu Cloud Disk also has a lot of resources, and some missing resources can be supplemented through offline downloads, along with high-quality playback and download speeds, etc. Most importantly, the Baidu Cloud Disk membership that has been activated is a necessity, and if it can still be utilized, why not?
Pitfalls#
After having this idea, 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 related 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 official team and received the following reply:
It seems that official support may be a long way off.
Finding an Alternative Path#
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, which allows normal playback.
- Local proxy, which requires a server with high traffic and bandwidth.
As we all know, Infuse cannot modify UA, so I initially turned my attention to the second option. However, I found that the 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 on the internet. 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 everyone.
- 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