文件蜈蚣,也许是最好的开源下载器[附带自动激活教程]

  • 简介

它兼容了绝大多数的下载协议,除了常见的HTTP(S),FTP,BT,磁力,迅雷链接,flashget,qqdl还支持m3u8流媒体下载

此外,也配备了IDM类似的浏览器插件,亦可以嗅探网站资源,可以简单的将其想为IDM+qBittorrentEE的增强版!

PS:因此理论上也可以用于*度网盘的直链加速,甚至因为支持Aria命令行下载,部分情况下可以不设置UA

文件蜈蚣,也许是最好的开源下载器[附带自动激活教程] 1

  • 真的完美吗?

诚然,它的下载速度和兼容性几乎无可挑剔,但依旧有些小问题,比如

1.虽然确实是免费软件,但是要以24小时为周期获取免费的激活码并输入;虽然不输并不影响正常使用,但其激活码弹窗每隔数分钟就置顶,比较烦人

2.没法像qBittorrent一样,方便的部署在如NAS之类的设备上,也没有WebUI功能(暂时,作者有计划做)

3.当前的最新版本依然不支持ed2k网络,我个人的评价是无所谓,ed2k本来就日渐式微了

  • 下载地址

  • 项目Github: https://github.com/filecxx/FileCentipede/raw/main/release/filecxx_latest_win_x64.zip
  • PS: 文件蜈蚣的作者希望这个项目能有100K的Star,有条件的咔友可以支持一下~
  • (半)自动激活

0.可以使用编译好的版本直接跳过下面的1-4步;下载地址 https://github.com/Uber-Eins/FileCentipede-Automatic-Activation/releases

1.下载Python

2.用pip install json,pyautogui,pygetwindow,pyperclip,re,requests安装一下必要的库
3.CV下面的代码到一个文本文件,拓展名改为.py
4.使用python $你刚刚创建的文件的路径来运行这个程序
import datetime
import os
from json import load,dump
from pyautogui import moveTo,click,hotkey,press
from pygetwindow import getWindowsWithTitle
from pyperclip import copy
from re import compile
from requests import get
from time import sleep

def GetActivationCodes():
    ActivationCodes = os.path.join(os.environ['APPDATA'], 'File Centipede', 'ActivationCodes.json')
    # 首先尝试从本地文件中读取激活码,如果文件存在并且包含当天日期的激活码,就直接返回它
    try:
        with open(ActivationCodes, 'r') as f:
            codes = load(f)
            today = datetime.date.today().strftime('%Y-%m-%d')
            for code in codes:
                if code["Validity Period"].startswith(today):
                    return code["ActivationCode"]
    except:
        codes = []
    
    try:
        url = 'https://filecxx.com/zh_CN/activation_code.html'
        response = get(url)
        html_content = response.text

        pattern = compile(r'(\d{4}-\d{2}-\d{2} 00:00:00 - \d{4}-\d{2}-\d{2} 00:00:00).*?\n(.+?)\n')

        results = pattern.findall(html_content)

        if results:
            for result in results:
                date = result[0]
                code = result[1]
                codes.append({"Validity Period": date, "ActivationCode": code})
            today_date = datetime.date.today()
            codes = [code for code in codes if datetime.datetime.strptime(code["Validity Period"][:10], '%Y-%m-%d').date() >= today_date]
            ActivationCodesDir = os.path.dirname(ActivationCodes)
            if not os.path.exists(ActivationCodesDir):
                os.makedirs(ActivationCodesDir)
            with open(ActivationCodes, 'w') as f:
                dump(codes, f, indent=2)
            for code in codes:
                if code["Validity Period"].startswith(today):
                    return code["ActivationCode"]
        else:
            print("没有找到符合条件的激活码")
            return None
        
    except Exception as e:
        print(e)
        return None
    
def InputActivationCode(WindowTitle,ActivationCode):
    try:
        # 查找指定标题的窗口
        target_window = getWindowsWithTitle(WindowTitle)[0]
        target_window.restore()  # 还原窗口
        target_window.activate()  # 激活窗口

        # 延时确保窗口激活
        sleep(0.15)

        # 计算输入框的中心位置
        input_box_x = (target_window.left + target_window.right) // 2
        input_box_y = (target_window.top + target_window.bottom) // 2 - 15

        # 移动鼠标到输入框中心并点击
        moveTo(input_box_x, input_box_y)
        click()

        # 清空输入框中的数据
        hotkey('ctrl', 'a')
        press('delete')

        # 将激活码复制到剪贴板
        copy(ActivationCode)

        # 粘贴激活码到输入框
        hotkey('ctrl', 'v')
        
        # 延时确保激活码输入完成
        sleep(0.15)

        # 计算确认按钮位置
        confirm_button_x = target_window.right - 60
        confirm_button_y = target_window.bottom - 30

        # 移动鼠标到确认按钮位置并点击
        moveTo(confirm_button_x, confirm_button_y)
        click()
        
        sleep(0.15)
        
        hotkey('enter')
    except IndexError:
        print(f"未找到标题为 '{WindowTitle}' 的窗口。")
    except Exception as e:
        print("发生错误:", e)

# 主进程
InputActivationCode("文件蜈蚣 - 激活码",GetActivationCodes())

 

声明:本站所有文章,如无特殊说明或标注,均为本站原创发布。任何个人或组织,在未征得UP主同意时,禁止复制、盗用、采集、发布本站内容到任何网站、书籍等各类媒体平台。如若本站内容侵犯了原著者的合法权益,可联系我们进行处理:DMCA投诉/Report
学习区-技术教程

OneDrive高速/离线下载

2023-12-7 22:23:44

学习区-技术教程

利用Tampermonkey(油猴)快速关闭特定页面

2023-12-13 0:46:37

3 条回复 A文章作者 M管理员
  1. Hellen

    感覺是個好東西,感謝分享

个人中心
购物车
优惠劵
今日签到
有新私信 私信列表
搜索