feat: Egern 支持 block_quic 参数 和 HTTPS 协议

This commit is contained in:
xream committed 2025-12-05 20:28:14 +08:00
1 parent da34670a6f
commit ff614b65f5
2 files changed
+29 -2

No files matched your search

+1 -1
View File
@@ -1,6 +1,6 @@
{
"name": "sub-store",
"version": "2.20.47",
"version": "2.20.48",
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and Shadowrocket.",
"main": "src/main.js",
"scripts": {
@@ -9,6 +9,7 @@ export default function Egern_Producer() {
if (
![
'http',
'https',
'socks5',
'ss',
'trojan',
@@ -83,7 +84,7 @@ export default function Egern_Producer() {
if (proxy.type === 'http') {
proxy = {
type: 'http',
type: proxy.tls ? 'https' : 'http',
name: proxy.name,
server: proxy.server,
port: proxy.port,
@@ -91,6 +92,12 @@ export default function Egern_Producer() {
password: proxy.password,
tfo: proxy.tfo || proxy['fast-open'],
next_hop: proxy.next_hop,
...(proxy.tls
? {
sni: proxy.sni,
skip_tls_verify: proxy['skip-cert-verify'],
}
: {}),
};
} else if (proxy.type === 'socks5') {
proxy = {
@@ -364,6 +371,7 @@ export default function Egern_Producer() {
if (
[
'http',
'https',
'socks5',
'ss',
'trojan',
@@ -394,6 +402,25 @@ export default function Egern_Producer() {
};
}
}
if (
['socks5', 'ss', 'trojan', 'vless', 'vmess'].includes(
original.type,
)
) {
if (
['on', 'true', true, '1', 1].includes(
original['block-quic'],
)
) {
proxy.block_quic = true;
} else if (
['off', 'false', false, '0', 0].includes(
original['block-quic'],
)
) {
proxy.block_quic = false;
}
}
if (
['ss'].includes(original.type) &&
proxy.shadow_tls &&