问题描述
遇见「应版权方要求,无法下载」问题,我们仅能求助其他下载工具,还能有什么其他方法么;
该笔记将记录:在 Linux 中,我们用到下载管理器(用到哪个就整理哪个,所谓佛系整理);
解决方案
软件及其支持的协议
Linux clients for three top P2P networks
| 软件\协议 | HTTP(S) | ed2k | Magnet | Torrent | |
|---|---|---|---|---|---|
| cURL | √ | ||||
| Wget | √ | ||||
| aMule | √ | ||||
| rtorrent | √ | ||||
| Transmission | √ | √ | √ | BitTorrent 客户端。P2P 下载工具; | |
| uGet | |||||
| aria2 | √ | √ | √ | ||
| Thunder | √ | √ | √ | √ | 迅雷 |
| Motrix | √ | √ | √ | github.com/agalwood/Motrix | |
| Deluge | 是个 BitTorrent 客户端,P2P 下载工具; |
aria2
同时下载多个 magnet 链接:
aria2c -i uris.txt
Thunder
针对「应版权方要求,无法下载」问题
鉴于软件掌握主动权,因此这是个难以解决的问题,但是也有迂回处理之法。但是不管怎样处理,最后都要更换下载软件;
对于 thunder:// 链接,解码并下载
这个链接是 base64 编码的,直接解码就好了
# function urldecode() { : "${*//+/ }"; echo -e "${_//%/\\x}"; }
# link='thunder://QUFodHRwJTNBJTJGJTJGZmZmLnh1bmxlaXppeXVhbi5uZXQlMkYxNzEwJTJGJUU3JTk0JTlGJUU2JUI0JUJCJUU1JUE0JUE3JUU3JTg4JTg2JUU3JTgyJUI4UzA0RTAxLm1wNFpa'
# urldecode $(echo $link | sed "s%thunder://%%g" | base64 -d | sed -E 's/(AA|ZZ)//g')
http://fff.xunleiziyuan.net/1710/ 生活大爆炸 S04E01.mp4
// 注意事项:并不是每次解码之后都是 http 链接;
解码之后,我们便可使用相应的软件完成下载任务;
常用工具
代理下载,直接回传到本地:
python 有没有办法实现类似反向代理(服务器边下载资源边向用户提供下载)的功能?
构建
基于 Web 的下载工具 Web-based Download Manager
某些资源的网络质量不好,可以放在海外的服务器上下载,然后再取回。我们能够安装某些基于 Web 的下载工具,然后运行在服务器上,进行下载任务的管理。
Aria2 and WebUI-Aria2
- Aria2: http://aria2.sourceforge.net
- WebUI-Aria2: https://github.com/ziahamza/webui-aria2
参考
How can I download magnet links through the command line with rtorrent on Linux?
How to Download Torrents from the Command Line in Ubuntu
bash – How to decode URL-encoded string in shell? – Stack Overflow
Comparison of download managers – Wikipedia
aria2