Skip to content

Commit

Permalink
feat: 支持 anytls 协议
Browse files Browse the repository at this point in the history
  • Loading branch information
xream committed Feb 19, 2025
1 parent 0825f15 commit ffabcc9
Show file tree
Hide file tree
Showing 7 changed files with 15 additions and 5 deletions.
2 changes: 1 addition & 1 deletion backend/package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "sub-store",
"version": "2.16.47",
"version": "2.16.48",
"description": "Advanced Subscription Manager for QX, Loon, Surge, Stash and Shadowrocket.",
"main": "src/main.js",
"scripts": {
Expand Down
11 changes: 8 additions & 3 deletions backend/src/core/proxy-utils/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -423,9 +423,14 @@ function lastParse(proxy) {
}
}
if (
['trojan', 'tuic', 'hysteria', 'hysteria2', 'juicity'].includes(
proxy.type,
)
[
'trojan',
'tuic',
'hysteria',
'hysteria2',
'juicity',
'anytls',
].includes(proxy.type)
) {
proxy.tls = true;
}
Expand Down
1 change: 1 addition & 0 deletions backend/src/core/proxy-utils/parsers/index.js
Original file line number Diff line number Diff line change
Expand Up @@ -1010,6 +1010,7 @@ function Clash_All() {
const proxy = JSON.parse(line);
if (
![
'anytls',
'mieru',
'juicity',
'ss',
Expand Down
1 change: 1 addition & 0 deletions backend/src/core/proxy-utils/producers/clash.js
Original file line number Diff line number Diff line change
Expand Up @@ -141,6 +141,7 @@ export default function Clash_Producer() {
'hysteria',
'hysteria2',
'juicity',
'anytls',
].includes(proxy.type)
) {
delete proxy.tls;
Expand Down
1 change: 1 addition & 0 deletions backend/src/core/proxy-utils/producers/clashmeta.js
Original file line number Diff line number Diff line change
Expand Up @@ -160,6 +160,7 @@ export default function ClashMeta_Producer() {
'hysteria',
'hysteria2',
'juicity',
'anytls',
].includes(proxy.type)
) {
delete proxy.tls;
Expand Down
3 changes: 2 additions & 1 deletion backend/src/core/proxy-utils/producers/shadowrocket.js
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ export default function Shadowrocket_Producer() {
if (opts['include-unsupported-proxy']) return true;
if (proxy.type === 'snell' && String(proxy.version) === '4') {
return false;
} else if (['mieru'].includes(proxy.type)) {
} else if (['mieru', 'anytls'].includes(proxy.type)) {
return false;
}
return true;
Expand Down Expand Up @@ -163,6 +163,7 @@ export default function Shadowrocket_Producer() {
'hysteria',
'hysteria2',
'juicity',
'anytls',
].includes(proxy.type)
) {
delete proxy.tls;
Expand Down
1 change: 1 addition & 0 deletions backend/src/core/proxy-utils/producers/stash.js
Original file line number Diff line number Diff line change
Expand Up @@ -247,6 +247,7 @@ export default function Stash_Producer() {
'hysteria',
'hysteria2',
'juicity',
'anytls',
].includes(proxy.type)
) {
delete proxy.tls;
Expand Down

0 comments on commit ffabcc9

Please sign in to comment.