diff --git a/backend/package.json b/backend/package.json index 43e836c..bf8a02e 100644 --- a/backend/package.json +++ b/backend/package.json @@ -1,6 +1,6 @@ { "name": "sub-store", - "version": "2.19.76", + "version": "2.19.77", "description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and Shadowrocket.", "main": "src/main.js", "scripts": { diff --git a/backend/src/core/proxy-utils/parsers/peggy/surge.js b/backend/src/core/proxy-utils/parsers/peggy/surge.js index 0892b2a..3686f75 100644 --- a/backend/src/core/proxy-utils/parsers/peggy/surge.js +++ b/backend/src/core/proxy-utils/parsers/peggy/surge.js @@ -105,11 +105,11 @@ wireguard = tag equals "wireguard" (section_name/no_error_alert/ip_version/under proxy.type = "wireguard-surge"; handleShadowTLS(); } -hysteria2 = tag equals "hysteria2" address (no_error_alert/ip_version/underlying_proxy/tos/allow_other_interface/interface/test_url/test_udp/test_timeout/hybrid/sni/fast_open/tfo/tls_verification/passwordk/tls_fingerprint/download_bandwidth/ecn/shadow_tls_version/shadow_tls_sni/shadow_tls_password/block_quic/port_hopping_interval/others)* { +hysteria2 = tag equals "hysteria2" address (no_error_alert/ip_version/underlying_proxy/tos/allow_other_interface/interface/test_url/test_udp/test_timeout/hybrid/sni/tls_verification/passwordk/tls_fingerprint/download_bandwidth/ecn/shadow_tls_version/shadow_tls_sni/shadow_tls_password/block_quic/port_hopping_interval/others)* { proxy.type = "hysteria2"; handleShadowTLS(); } -socks5 = tag equals "socks5" address (username password)? (usernamek passwordk)? (udp_relay/no_error_alert/ip_version/underlying_proxy/tos/allow_other_interface/interface/test_url/test_udp/test_timeout/hybrid/tfo/shadow_tls_version/shadow_tls_sni/shadow_tls_password/block_quic/others)* { +socks5 = tag equals "socks5" address (username password)? (usernamek passwordk)? (udp_relay/no_error_alert/ip_version/underlying_proxy/tos/allow_other_interface/interface/test_url/test_udp/test_timeout/hybrid/fast_open/tfo/shadow_tls_version/shadow_tls_sni/shadow_tls_password/block_quic/others)* { proxy.type = "socks5"; handleShadowTLS(); } @@ -121,7 +121,6 @@ socks5_tls = tag equals "socks5-tls" address (username password)? (usernamek pas direct = tag equals "direct" (udp_relay/ip_version/underlying_proxy/tos/allow_other_interface/interface/test_url/test_udp/test_timeout/hybrid/no_error_alert/fast_open/tfo/block_quic/others)* { proxy.type = "direct"; } - address = comma server:server comma port:port { proxy.server = server; proxy.port = port; @@ -212,7 +211,7 @@ ws_headers = comma "ws-headers" equals headers:$[^,]+ { const result = {}; pairs.forEach(pair => { const [key, value] = pair.trim().split(":"); - result[key.trim()] = value.trim().trim().replace(/^"(.*?)"$/, '$1').replace(/^'(.*?)'$/, '$1'); + result[key.trim()] = value.trim().replace(/^"(.*?)"$/, '$1').replace(/^'(.*?)'$/, '$1'); }) obfs["ws-headers"] = result; } diff --git a/backend/src/restful/index.js b/backend/src/restful/index.js index 7f5222d..1f784d9 100644 --- a/backend/src/restful/index.js +++ b/backend/src/restful/index.js @@ -119,10 +119,11 @@ export default function serve() { $app.start(); if ($.env.isNode) { - // Deprecated: SUB_STORE_BACKEND_CRON - const backend_sync_cron = - eval('process.env.SUB_STORE_BACKEND_SYNC_CRON') || - eval('process.env.SUB_STORE_BACKEND_CRON'); + // Deprecated: SUB_STORE_BACKEND_CRON, SUB_STORE_CRON + const backend_sync_cron = eval( + 'process.env.SUB_STORE_BACKEND_SYNC_CRON', + ); + if (backend_sync_cron) { $.info(`[SYNC CRON] ${backend_sync_cron} enabled`); const { CronJob } = eval(`require("cron")`); @@ -145,6 +146,17 @@ export default function serve() { true, // start // 'Asia/Shanghai' // timeZone ); + } else { + if (eval('process.env.SUB_STORE_BACKEND_CRON')) { + $.error( + `[SYNC CRON] SUB_STORE_BACKEND_CRON 已弃用, 请使用 SUB_STORE_BACKEND_SYNC_CRON`, + ); + } + if (eval('process.env.SUB_STORE_CRON')) { + $.error( + `[SYNC CRON] SUB_STORE_CRON 已弃用, 请使用 SUB_STORE_BACKEND_SYNC_CRON`, + ); + } } // 格式: 0 */2 * * *,sub,a;0 */3 * * *,col,b // 每 2 小时处理一次单条订阅 a, 每 3 小时处理一次组合订阅 b diff --git a/backend/sub-store_1748083027961.json b/backend/sub-store_1748083027961.json deleted file mode 100644 index e69de29..0000000