mirror of
https://github.com/tw93/Mole.git
synced 2026-02-04 15:39:42 +00:00
feat: Add comprehensive protection for various VPN and proxy applications and bump version.
This commit is contained in:
@@ -62,6 +62,9 @@ Mole's "Smart Uninstall" and orphan detection (`lib/clean/apps.sh`) are intentio
|
||||
- **Time Machine Preservation**
|
||||
Before cleaning failed backups, Mole checks for the `backupd` process. If a backup is currently running, the cleanup task is strictly **aborted** to prevent data corruption.
|
||||
|
||||
- **VPN & Proxy Protection**
|
||||
Mole includes a comprehensive protection layer for VPN and Proxy applications (e.g., Shadowsocks, V2Ray, Tailscale). It protects both their application bundles and data directories from automated cleanup to prevent network configuration loss.
|
||||
|
||||
## 4. Atomic Operations & Crash Safety
|
||||
|
||||
We anticipate that scripts can be interrupted (e.g., power loss, `Ctrl+C`).
|
||||
|
||||
@@ -223,7 +223,7 @@ safe_clean() {
|
||||
|
||||
# Hard-coded protection for critical apps (cannot be disabled by user)
|
||||
case "$path" in
|
||||
*clash* | *Clash* | *surge* | *Surge* | *mihomo* | *openvpn* | *OpenVPN*)
|
||||
*clash* | *Clash* | *surge* | *Surge* | *mihomo* | *openvpn* | *OpenVPN* | *verge* | *Verge* | *shadowsocks* | *Shadowsocks* | *v2ray* | *V2Ray* | *sing-box* | *tailscale* | *nordvpn* | *NordVPN* | *expressvpn* | *ExpressVPN* | *protonvpn* | *ProtonVPN* | *mullvad* | *Mullvad* | *hiddify* | *Hiddify* | *loon* | *Loon*)
|
||||
skip=true
|
||||
((skipped_count++))
|
||||
;;
|
||||
|
||||
@@ -140,10 +140,46 @@ readonly DATA_PROTECTED_BUNDLES=(
|
||||
# Network Proxy & VPN Tools (protect all variants)
|
||||
"*clash*" # All Clash variants (ClashX, ClashX Pro, Clash Verge, etc)
|
||||
"*Clash*" # Capitalized variants
|
||||
"*clash-verge*" # Explicit Clash Verge protection
|
||||
"*verge*" # Verge variants (lowercase)
|
||||
"*Verge*" # Verge variants (capitalized)
|
||||
"com.nssurge.surge-mac" # Surge
|
||||
"mihomo*" # Mihomo Party and variants
|
||||
"*openvpn*" # OpenVPN Connect and variants
|
||||
"*OpenVPN*" # OpenVPN capitalized variants
|
||||
|
||||
# Proxy Clients (Shadowsocks, V2Ray, etc)
|
||||
"*ShadowsocksX-NG*" # ShadowsocksX-NG
|
||||
"com.qiuyuzhou.*" # ShadowsocksX-NG bundle
|
||||
"*v2ray*" # V2Ray variants
|
||||
"*V2Ray*" # V2Ray variants
|
||||
"*v2box*" # V2Box
|
||||
"*V2Box*" # V2Box
|
||||
"*nekoray*" # Nekoray
|
||||
"*sing-box*" # Sing-box
|
||||
"*OneBox*" # OneBox
|
||||
"*hiddify*" # Hiddify
|
||||
"*Hiddify*" # Hiddify
|
||||
"*loon*" # Loon
|
||||
"*Loon*" # Loon
|
||||
"*quantumult*" # Quantumult X
|
||||
|
||||
# Mesh & Corporate VPNs
|
||||
"*tailscale*" # Tailscale
|
||||
"io.tailscale.*" # Tailscale bundle
|
||||
"*zerotier*" # ZeroTier
|
||||
"com.zerotier.*" # ZeroTier bundle
|
||||
"*1dot1dot1dot1*" # Cloudflare WARP
|
||||
"*cloudflare*warp*" # Cloudflare WARP
|
||||
|
||||
# Commercial VPNs
|
||||
"*nordvpn*" # NordVPN
|
||||
"*expressvpn*" # ExpressVPN
|
||||
"*protonvpn*" # ProtonVPN
|
||||
"*surfshark*" # Surfshark
|
||||
"*windscribe*" # Windscribe
|
||||
"*mullvad*" # Mullvad
|
||||
"*privateinternetaccess*" # PIA
|
||||
"net.openvpn.*" # OpenVPN bundle IDs
|
||||
|
||||
# ============================================================================
|
||||
|
||||
Reference in New Issue
Block a user