From 5f24d5979b3f9a2d4ed83fa8d6d74193732fc628 Mon Sep 17 00:00:00 2001 From: "github-action[bot]" Date: Wed, 26 Nov 2025 19:35:56 +0100 Subject: [PATCH] Update On Wed Nov 26 19:35:55 CET 2025 --- .github/update.log | 1 + clash-meta/common/structure/structure.go | 2 +- clash-nyanpasu/backend/Cargo.lock | 25 +-- filebrowser/frontend/pnpm-lock.yaml | 169 +++++++++--------- filebrowser/frontend/src/i18n/hr.json | 4 +- .../arm64/boot/dts/qcom/ipq5018-gl-b3000.dts | 9 +- mieru/pkg/protocol/mux.go | 19 +- mieru/pkg/protocol/scheduler.go | 15 +- mieru/pkg/protocol/underlay.go | 6 + mieru/pkg/protocol/underlay_base.go | 12 ++ mieru/pkg/protocol/underlay_packet.go | 3 + mieru/pkg/protocol/underlay_stream.go | 8 + mihomo/common/structure/structure.go | 2 +- openwrt-packages/ddns-go/Makefile | 4 +- .../resources/view/passwall/Sortable.min.js | 2 + .../cbi/passwall/client/node_subscribe.lua | 2 +- .../view/passwall/node_list/node_list.htm | 102 +++++++++-- .../luci-app-passwall/po/zh-cn/passwall.po | 3 + .../root/usr/share/passwall/subscribe.lua | 4 +- .../luasrc/controller/passwall.lua | 27 ++- .../view/passwall/node_list/node_list.htm | 72 ++++++-- small/luci-app-passwall/po/zh-cn/passwall.po | 6 + .../root/usr/share/shadowsocksr/subscribe.lua | 7 +- small/v2ray-geodata/Makefile | 4 +- v2rayn/.github/workflows/build-linux.yml | 2 +- v2rayn/.github/workflows/build-osx.yml | 2 +- .../workflows/build-windows-desktop.yml | 2 +- v2rayn/.github/workflows/build-windows.yml | 2 +- .../v2rayN/ServiceLib/Handler/Fmt/BaseFmt.cs | 39 ++-- .../ViewModels/ProfilesViewModel.cs | 23 +++ .../v2rayN.Desktop/Views/ProfilesView.axaml | 8 + .../Views/ProfilesView.axaml.cs | 3 + v2rayng/.github/workflows/build.yml | 6 +- .../com/v2ray/ang/service/TProxyService.kt | 3 +- v2rayng/compile-hevtun.sh | 40 +++++ v2rayng/compile-tun2socks.sh | 26 --- youtube-dl/youtube_dl/YoutubeDL.py | 90 +++++----- youtube-dl/youtube_dl/extractor/youtube.py | 12 +- 38 files changed, 505 insertions(+), 261 deletions(-) create mode 100644 openwrt-passwall/luci-app-passwall/htdocs/luci-static/resources/view/passwall/Sortable.min.js create mode 100644 v2rayng/compile-hevtun.sh diff --git a/.github/update.log b/.github/update.log index 74818a7810..6a306fa768 100644 --- a/.github/update.log +++ b/.github/update.log @@ -1193,3 +1193,4 @@ Update On Sat Nov 22 19:36:29 CET 2025 Update On Sun Nov 23 19:36:55 CET 2025 Update On Mon Nov 24 19:40:17 CET 2025 Update On Tue Nov 25 19:40:43 CET 2025 +Update On Wed Nov 26 19:35:47 CET 2025 diff --git a/clash-meta/common/structure/structure.go b/clash-meta/common/structure/structure.go index bf79f7dd27..840e4f6cad 100644 --- a/clash-meta/common/structure/structure.go +++ b/clash-meta/common/structure/structure.go @@ -289,7 +289,7 @@ func (d *Decoder) decodeBool(name string, data any, val reflect.Value) (err erro case isInt(kind) && d.option.WeaklyTypedInput: val.SetBool(dataVal.Int() != 0) case isUint(kind) && d.option.WeaklyTypedInput: - val.SetString(strconv.FormatUint(dataVal.Uint(), 10)) + val.SetBool(dataVal.Uint() != 0) default: err = fmt.Errorf( "'%s' expected type '%s', got unconvertible type '%s'", diff --git a/clash-nyanpasu/backend/Cargo.lock b/clash-nyanpasu/backend/Cargo.lock index 8ea04ac39f..126f6b8e46 100644 --- a/clash-nyanpasu/backend/Cargo.lock +++ b/clash-nyanpasu/backend/Cargo.lock @@ -355,7 +355,7 @@ dependencies = [ "objc2-foundation 0.3.2", "parking_lot", "percent-encoding", - "windows-sys 0.52.0", + "windows-sys 0.59.0", "wl-clipboard-rs", "x11rb", ] @@ -2853,7 +2853,7 @@ source = "registry+https://github.com/rust-lang/crates.io-index" checksum = "778e2ac28f6c47af28e4907f13ffd1e1ddbd400980a9abd7c8df189bf578a5ad" dependencies = [ "libc", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -5334,14 +5334,15 @@ dependencies = [ [[package]] name = "mlua" -version = "0.11.4" +version = "0.11.5" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "9be1c2bfc684b8a228fbaebf954af7a47a98ec27721986654a4cc2c40a20cc7e" +checksum = "935ac67539907efcd7198137eb7358e052555f77fe1b2916600a2249351f2b33" dependencies = [ "bstr", "either", "erased-serde", "futures-util", + "libc", "mlua-sys", "num-traits", "parking_lot", @@ -5353,9 +5354,9 @@ dependencies = [ [[package]] name = "mlua-sys" -version = "0.8.3" +version = "0.9.0" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "3d4dc9cfc5a7698899802e97480617d9726f7da78c910db989d4d0fd4991d900" +checksum = "8c968af21bf6b19fc9ca8e7b85ee16f86e4c9e3d0591de101a5608086bda0ad8" dependencies = [ "cc", "cfg-if", @@ -6333,9 +6334,9 @@ checksum = "c08d65885ee38876c4f86fa503fb49d7b507c2b62552df7c70b2fce627e06381" [[package]] name = "open" -version = "5.3.2" +version = "5.3.3" source = "registry+https://github.com/rust-lang/crates.io-index" -checksum = "e2483562e62ea94312f3576a7aca397306df7990b8d89033e18766744377ef95" +checksum = "43bb73a7fa3799b198970490a51174027ba0d4ec504b03cd08caf513d40024bc" dependencies = [ "dunce", "is-wsl", @@ -7383,7 +7384,7 @@ dependencies = [ "once_cell", "socket2", "tracing", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -7937,7 +7938,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys 0.4.15", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -7950,7 +7951,7 @@ dependencies = [ "errno", "libc", "linux-raw-sys 0.9.4", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] @@ -9606,7 +9607,7 @@ dependencies = [ "getrandom 0.3.3", "once_cell", "rustix 1.0.8", - "windows-sys 0.52.0", + "windows-sys 0.59.0", ] [[package]] diff --git a/filebrowser/frontend/pnpm-lock.yaml b/filebrowser/frontend/pnpm-lock.yaml index 46047119ac..5a68228916 100644 --- a/filebrowser/frontend/pnpm-lock.yaml +++ b/filebrowser/frontend/pnpm-lock.yaml @@ -82,7 +82,7 @@ importers: version: 4.5.5(@vueuse/core@14.0.0(vue@3.5.25(typescript@5.9.3)))(@vueuse/integrations@14.0.0(focus-trap@7.6.2)(jwt-decode@4.0.0)(vue@3.5.25(typescript@5.9.3)))(focus-trap@7.6.2)(vue@3.5.25(typescript@5.9.3)) vue-i18n: specifier: ^11.1.10 - version: 11.2.1(vue@3.5.25(typescript@5.9.3)) + version: 11.2.2(vue@3.5.25(typescript@5.9.3)) vue-lazyload: specifier: ^3.0.0 version: 3.0.0 @@ -98,7 +98,7 @@ importers: devDependencies: '@intlify/unplugin-vue-i18n': specifier: ^11.0.1 - version: 11.0.1(@vue/compiler-dom@3.5.25)(eslint@9.39.1)(rollup@4.53.3)(typescript@5.9.3)(vue-i18n@11.2.1(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3)) + version: 11.0.1(@vue/compiler-dom@3.5.25)(eslint@9.39.1)(rollup@4.53.3)(typescript@5.9.3)(vue-i18n@11.2.2(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3)) '@tsconfig/node24': specifier: ^24.0.2 version: 24.0.3 @@ -110,7 +110,7 @@ importers: version: 24.10.1 '@typescript-eslint/eslint-plugin': specifier: ^8.37.0 - version: 8.47.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(typescript@5.9.3) + version: 8.48.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(typescript@5.9.3) '@vitejs/plugin-legacy': specifier: ^7.2.1 version: 7.2.1(terser@5.44.1)(vite@7.2.4(@types/node@24.10.1)(terser@5.44.1)(yaml@2.7.0)) @@ -122,7 +122,7 @@ importers: version: 10.2.0(eslint@9.39.1)(prettier@3.6.2) '@vue/eslint-config-typescript': specifier: ^14.6.0 - version: 14.6.0(eslint-plugin-vue@10.6.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)))(eslint@9.39.1)(typescript@5.9.3) + version: 14.6.0(eslint-plugin-vue@10.6.1(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)))(eslint@9.39.1)(typescript@5.9.3) '@vue/tsconfig': specifier: ^0.8.1 version: 0.8.1(typescript@5.9.3)(vue@3.5.25(typescript@5.9.3)) @@ -140,7 +140,7 @@ importers: version: 5.5.4(eslint-config-prettier@10.1.8(eslint@9.39.1))(eslint@9.39.1)(prettier@3.6.2) eslint-plugin-vue: specifier: ^10.5.1 - version: 10.6.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)) + version: 10.6.1(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)) postcss: specifier: ^8.5.6 version: 8.5.6 @@ -887,20 +887,20 @@ packages: vue-i18n: optional: true - '@intlify/core-base@11.2.1': - resolution: {integrity: sha512-2V1A4yaN9ElAnQ6ih3HHEc+jZ+sHV6BlQHjCsnIVlOotL5NCUgJElIxgUFiJs6zV4puoAq3hHuQIfWNp+J+8yQ==} + '@intlify/core-base@11.2.2': + resolution: {integrity: sha512-0mCTBOLKIqFUP3BzwuFW23hYEl9g/wby6uY//AC5hTgQfTsM2srCYF2/hYGp+a5DZ/HIFIgKkLJMzXTt30r0JQ==} engines: {node: '>= 16'} - '@intlify/message-compiler@11.2.1': - resolution: {integrity: sha512-J2454D3Agg3Kvgaj14gxTleJU8/H06Sisz7C2BwiHF0/i5Soyfb5ySpwn8GCL6yscDbOGj6xM+lUe6gO6BFQyg==} + '@intlify/message-compiler@11.2.2': + resolution: {integrity: sha512-XS2p8Ff5JxWsKhgfld4/MRQzZRQ85drMMPhb7Co6Be4ZOgqJX1DzcZt0IFgGTycgqL8rkYNwgnD443Q+TapOoA==} engines: {node: '>= 16'} '@intlify/shared@11.1.12': resolution: {integrity: sha512-Om86EjuQtA69hdNj3GQec9ZC0L0vPSAnXzB3gP/gyJ7+mA7t06d9aOAiqMZ+xEOsumGP4eEBlfl8zF2LOTzf2A==} engines: {node: '>= 16'} - '@intlify/shared@11.2.1': - resolution: {integrity: sha512-O67LZM4dbfr70WCsZLW+g+pIXdgQ66laLVd/FicW7iYgP/RuH0X1FDGSh+Hr9Gou/8TeldUE6KmTGdLwX2ufIA==} + '@intlify/shared@11.2.2': + resolution: {integrity: sha512-OtCmyFpSXxNu/oET/aN6HtPCbZ01btXVd0f3w00YsHOb13Kverk1jzA2k47pAekM55qbUw421fvPF1yxZ+gicw==} engines: {node: '>= 16'} '@intlify/unplugin-vue-i18n@11.0.1': @@ -1127,11 +1127,11 @@ packages: eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <5.9.0' - '@typescript-eslint/eslint-plugin@8.47.0': - resolution: {integrity: sha512-fe0rz9WJQ5t2iaLfdbDc9T80GJy0AeO453q8C3YCilnGozvOyCG5t+EZtg7j7D88+c3FipfP/x+wzGnh1xp8ZA==} + '@typescript-eslint/eslint-plugin@8.48.0': + resolution: {integrity: sha512-XxXP5tL1txl13YFtrECECQYeZjBZad4fyd3cFV4a19LkAY/bIp9fev3US4S5fDVV2JaYFiKAZ/GRTOLer+mbyQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: - '@typescript-eslint/parser': ^8.47.0 + '@typescript-eslint/parser': ^8.48.0 eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <6.0.0' @@ -1154,8 +1154,8 @@ packages: peerDependencies: typescript: '>=4.8.4 <6.0.0' - '@typescript-eslint/project-service@8.47.0': - resolution: {integrity: sha512-2X4BX8hUeB5JcA1TQJ7GjcgulXQ+5UkNb0DL8gHsHUHdFoiCTJoYLTpib3LtSDPZsRET5ygN4qqIWrHyYIKERA==} + '@typescript-eslint/project-service@8.48.0': + resolution: {integrity: sha512-Ne4CTZyRh1BecBf84siv42wv5vQvVmgtk8AuiEffKTUo3DrBaGYZueJSxxBZ8fjk/N3DrgChH4TOdIOwOwiqqw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: typescript: '>=4.8.4 <6.0.0' @@ -1168,8 +1168,8 @@ packages: resolution: {integrity: sha512-tMDbLGXb1wC+McN1M6QeDx7P7c0UWO5z9CXqp7J8E+xGcJuUuevWKxuG8j41FoweS3+L41SkyKKkia16jpX7CA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/scope-manager@8.47.0': - resolution: {integrity: sha512-a0TTJk4HXMkfpFkL9/WaGTNuv7JWfFTQFJd6zS9dVAjKsojmv9HT55xzbEpnZoY+VUb+YXLMp+ihMLz/UlZfDg==} + '@typescript-eslint/scope-manager@8.48.0': + resolution: {integrity: sha512-uGSSsbrtJrLduti0Q1Q9+BF1/iFKaxGoQwjWOIVNJv0o6omrdyR8ct37m4xIl5Zzpkp69Kkmvom7QFTtue89YQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@typescript-eslint/tsconfig-utils@8.37.0': @@ -1184,8 +1184,8 @@ packages: peerDependencies: typescript: '>=4.8.4 <6.0.0' - '@typescript-eslint/tsconfig-utils@8.47.0': - resolution: {integrity: sha512-ybUAvjy4ZCL11uryalkKxuT3w3sXJAuWhOoGS3T/Wu+iUu1tGJmk5ytSY8gbdACNARmcYEB0COksD2j6hfGK2g==} + '@typescript-eslint/tsconfig-utils@8.48.0': + resolution: {integrity: sha512-WNebjBdFdyu10sR1M4OXTt2OkMd5KWIL+LLfeH9KhgP+jzfDV/LI3eXzwJ1s9+Yc0Kzo2fQCdY/OpdusCMmh6w==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: typescript: '>=4.8.4 <6.0.0' @@ -1197,8 +1197,8 @@ packages: eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <5.9.0' - '@typescript-eslint/type-utils@8.47.0': - resolution: {integrity: sha512-QC9RiCmZ2HmIdCEvhd1aJELBlD93ErziOXXlHEZyuBo3tBiAZieya0HLIxp+DoDWlsQqDawyKuNEhORyku+P8A==} + '@typescript-eslint/type-utils@8.48.0': + resolution: {integrity: sha512-zbeVaVqeXhhab6QNEKfK96Xyc7UQuoFWERhEnj3mLVnUWrQnv15cJNseUni7f3g557gm0e46LZ6IJ4NJVOgOpw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 @@ -1212,8 +1212,8 @@ packages: resolution: {integrity: sha512-USjyxm3gQEePdUwJBFjjGNG18xY9A2grDVGuk7/9AkjIF1L+ZrVnwR5VAU5JXtUnBL/Nwt3H31KlRDaksnM7/w==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/types@8.47.0': - resolution: {integrity: sha512-nHAE6bMKsizhA2uuYZbEbmp5z2UpffNrPEqiKIeN7VsV6UY/roxanWfoRrf6x/k9+Obf+GQdkm0nPU+vnMXo9A==} + '@typescript-eslint/types@8.48.0': + resolution: {integrity: sha512-cQMcGQQH7kwKoVswD1xdOytxQR60MWKM1di26xSUtxehaDs/32Zpqsu5WJlXTtTTqyAVK8R7hvsUnIXRS+bjvA==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@typescript-eslint/typescript-estree@8.37.0': @@ -1228,8 +1228,8 @@ packages: peerDependencies: typescript: '>=4.8.4 <6.0.0' - '@typescript-eslint/typescript-estree@8.47.0': - resolution: {integrity: sha512-k6ti9UepJf5NpzCjH31hQNLHQWupTRPhZ+KFF8WtTuTpy7uHPfeg2NM7cP27aCGajoEplxJDFVCEm9TGPYyiVg==} + '@typescript-eslint/typescript-estree@8.48.0': + resolution: {integrity: sha512-ljHab1CSO4rGrQIAyizUS6UGHHCiAYhbfcIZ1zVJr5nMryxlXMVWS3duFPSKvSUbFPwkXMFk1k0EMIjub4sRRQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: typescript: '>=4.8.4 <6.0.0' @@ -1241,8 +1241,8 @@ packages: eslint: ^8.57.0 || ^9.0.0 typescript: '>=4.8.4 <5.9.0' - '@typescript-eslint/utils@8.47.0': - resolution: {integrity: sha512-g7XrNf25iL4TJOiPqatNuaChyqt49a/onq5YsJ9+hXeugK+41LVg7AxikMfM02PC6jbNtZLCJj6AUcQXJS/jGQ==} + '@typescript-eslint/utils@8.48.0': + resolution: {integrity: sha512-yTJO1XuGxCsSfIVt1+1UrLHtue8xz16V8apzPYI06W0HbEbEWHxHXgZaAgavIkoh+GeV6hKKd5jm0sS6OYxWXQ==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: eslint: ^8.57.0 || ^9.0.0 @@ -1256,8 +1256,8 @@ packages: resolution: {integrity: sha512-/++5CYLQqsO9HFGLI7APrxBJYo+5OCMpViuhV8q5/Qa3o5mMrF//eQHks+PXcsAVaLdn817fMuS7zqoXNNZGaw==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} - '@typescript-eslint/visitor-keys@8.47.0': - resolution: {integrity: sha512-SIV3/6eftCy1bNzCQoPmbWsRLujS8t5iDIZ4spZOBHqrM+yfX2ogg8Tt3PDTAVKw3sSCiUgg30uOAvK2r9zGjQ==} + '@typescript-eslint/visitor-keys@8.48.0': + resolution: {integrity: sha512-T0XJMaRPOH3+LBbAfzR2jalckP1MSG/L9eUtY0DEzUyVaXJ/t6zN0nR7co5kz0Jko/nkSYCBRkz1djvjajVTTg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} '@videojs/http-streaming@3.17.2': @@ -1668,8 +1668,8 @@ packages: eslint-config-prettier: optional: true - eslint-plugin-vue@10.6.0: - resolution: {integrity: sha512-TsoFluWxOpsJlE/l2jJygLQLWBPJ3Qdkesv7tBIunICbTcG0dS1/NBw/Ol4tJw5kHWlAVds4lUmC29/vlPUcEQ==} + eslint-plugin-vue@10.6.1: + resolution: {integrity: sha512-OMvDAFbewocYrJamF1EoSWoT4xa7/QRb/yYouEZMiroTE+WRmFUreR+kAFQHqM45W3kg5oljVfUYfH9HEwX1Bg==} engines: {node: ^18.18.0 || ^20.9.0 || >=21.1.0} peerDependencies: '@stylistic/eslint-plugin': ^2.0.0 || ^3.0.0 || ^4.0.0 || ^5.0.0 @@ -2496,8 +2496,8 @@ packages: focus-trap: '>=7.2.0' vue: '>=3.2.0' - vue-i18n@11.2.1: - resolution: {integrity: sha512-cc3Wx4eJZac9WMS8mxhfYiCipm9PBQ2Dz15piWYm7DwNcCehaKRgpolEdiqrjjT27T3Wijz3xJ7NeIc8ofIWAA==} + vue-i18n@11.2.2: + resolution: {integrity: sha512-ULIKZyRluUPRCZmihVgUvpq8hJTtOqnbGZuv4Lz+byEKZq4mU0g92og414l6f/4ju+L5mORsiUuEPYrAuX2NJg==} engines: {node: '>= 16'} peerDependencies: vue: ^3.0.0 @@ -3359,9 +3359,9 @@ snapshots: '@humanwhocodes/retry@0.4.3': {} - '@intlify/bundle-utils@11.0.1(vue-i18n@11.2.1(vue@3.5.25(typescript@5.9.3)))': + '@intlify/bundle-utils@11.0.1(vue-i18n@11.2.2(vue@3.5.25(typescript@5.9.3)))': dependencies: - '@intlify/message-compiler': 11.2.1 + '@intlify/message-compiler': 11.2.2 '@intlify/shared': 11.1.12 acorn: 8.15.0 esbuild: 0.25.12 @@ -3371,28 +3371,28 @@ snapshots: source-map-js: 1.2.1 yaml-eslint-parser: 1.2.3 optionalDependencies: - vue-i18n: 11.2.1(vue@3.5.25(typescript@5.9.3)) + vue-i18n: 11.2.2(vue@3.5.25(typescript@5.9.3)) - '@intlify/core-base@11.2.1': + '@intlify/core-base@11.2.2': dependencies: - '@intlify/message-compiler': 11.2.1 - '@intlify/shared': 11.2.1 + '@intlify/message-compiler': 11.2.2 + '@intlify/shared': 11.2.2 - '@intlify/message-compiler@11.2.1': + '@intlify/message-compiler@11.2.2': dependencies: - '@intlify/shared': 11.2.1 + '@intlify/shared': 11.2.2 source-map-js: 1.2.1 '@intlify/shared@11.1.12': {} - '@intlify/shared@11.2.1': {} + '@intlify/shared@11.2.2': {} - '@intlify/unplugin-vue-i18n@11.0.1(@vue/compiler-dom@3.5.25)(eslint@9.39.1)(rollup@4.53.3)(typescript@5.9.3)(vue-i18n@11.2.1(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3))': + '@intlify/unplugin-vue-i18n@11.0.1(@vue/compiler-dom@3.5.25)(eslint@9.39.1)(rollup@4.53.3)(typescript@5.9.3)(vue-i18n@11.2.2(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3))': dependencies: '@eslint-community/eslint-utils': 4.9.0(eslint@9.39.1) - '@intlify/bundle-utils': 11.0.1(vue-i18n@11.2.1(vue@3.5.25(typescript@5.9.3))) + '@intlify/bundle-utils': 11.0.1(vue-i18n@11.2.2(vue@3.5.25(typescript@5.9.3))) '@intlify/shared': 11.1.12 - '@intlify/vue-i18n-extensions': 8.0.0(@intlify/shared@11.1.12)(@vue/compiler-dom@3.5.25)(vue-i18n@11.2.1(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3)) + '@intlify/vue-i18n-extensions': 8.0.0(@intlify/shared@11.1.12)(@vue/compiler-dom@3.5.25)(vue-i18n@11.2.2(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3)) '@rollup/pluginutils': 5.3.0(rollup@4.53.3) '@typescript-eslint/scope-manager': 8.46.4 '@typescript-eslint/typescript-estree': 8.46.4(typescript@5.9.3) @@ -3403,7 +3403,7 @@ snapshots: unplugin: 2.3.10 vue: 3.5.25(typescript@5.9.3) optionalDependencies: - vue-i18n: 11.2.1(vue@3.5.25(typescript@5.9.3)) + vue-i18n: 11.2.2(vue@3.5.25(typescript@5.9.3)) transitivePeerDependencies: - '@vue/compiler-dom' - eslint @@ -3411,14 +3411,14 @@ snapshots: - supports-color - typescript - '@intlify/vue-i18n-extensions@8.0.0(@intlify/shared@11.1.12)(@vue/compiler-dom@3.5.25)(vue-i18n@11.2.1(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3))': + '@intlify/vue-i18n-extensions@8.0.0(@intlify/shared@11.1.12)(@vue/compiler-dom@3.5.25)(vue-i18n@11.2.2(vue@3.5.25(typescript@5.9.3)))(vue@3.5.25(typescript@5.9.3))': dependencies: '@babel/parser': 7.28.5 optionalDependencies: '@intlify/shared': 11.1.12 '@vue/compiler-dom': 3.5.25 vue: 3.5.25(typescript@5.9.3) - vue-i18n: 11.2.1(vue@3.5.25(typescript@5.9.3)) + vue-i18n: 11.2.2(vue@3.5.25(typescript@5.9.3)) '@jridgewell/gen-mapping@0.3.13': dependencies: @@ -3576,14 +3576,14 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/eslint-plugin@8.47.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(typescript@5.9.3)': + '@typescript-eslint/eslint-plugin@8.48.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(typescript@5.9.3)': dependencies: '@eslint-community/regexpp': 4.12.2 '@typescript-eslint/parser': 8.37.0(eslint@9.39.1)(typescript@5.9.3) - '@typescript-eslint/scope-manager': 8.47.0 - '@typescript-eslint/type-utils': 8.47.0(eslint@9.39.1)(typescript@5.9.3) - '@typescript-eslint/utils': 8.47.0(eslint@9.39.1)(typescript@5.9.3) - '@typescript-eslint/visitor-keys': 8.47.0 + '@typescript-eslint/scope-manager': 8.48.0 + '@typescript-eslint/type-utils': 8.48.0(eslint@9.39.1)(typescript@5.9.3) + '@typescript-eslint/utils': 8.48.0(eslint@9.39.1)(typescript@5.9.3) + '@typescript-eslint/visitor-keys': 8.48.0 eslint: 9.39.1 graphemer: 1.4.0 ignore: 7.0.5 @@ -3623,10 +3623,10 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/project-service@8.47.0(typescript@5.9.3)': + '@typescript-eslint/project-service@8.48.0(typescript@5.9.3)': dependencies: - '@typescript-eslint/tsconfig-utils': 8.47.0(typescript@5.9.3) - '@typescript-eslint/types': 8.47.0 + '@typescript-eslint/tsconfig-utils': 8.48.0(typescript@5.9.3) + '@typescript-eslint/types': 8.48.0 debug: 4.4.3 typescript: 5.9.3 transitivePeerDependencies: @@ -3642,10 +3642,10 @@ snapshots: '@typescript-eslint/types': 8.46.4 '@typescript-eslint/visitor-keys': 8.46.4 - '@typescript-eslint/scope-manager@8.47.0': + '@typescript-eslint/scope-manager@8.48.0': dependencies: - '@typescript-eslint/types': 8.47.0 - '@typescript-eslint/visitor-keys': 8.47.0 + '@typescript-eslint/types': 8.48.0 + '@typescript-eslint/visitor-keys': 8.48.0 '@typescript-eslint/tsconfig-utils@8.37.0(typescript@5.9.3)': dependencies: @@ -3655,7 +3655,7 @@ snapshots: dependencies: typescript: 5.9.3 - '@typescript-eslint/tsconfig-utils@8.47.0(typescript@5.9.3)': + '@typescript-eslint/tsconfig-utils@8.48.0(typescript@5.9.3)': dependencies: typescript: 5.9.3 @@ -3671,11 +3671,11 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/type-utils@8.47.0(eslint@9.39.1)(typescript@5.9.3)': + '@typescript-eslint/type-utils@8.48.0(eslint@9.39.1)(typescript@5.9.3)': dependencies: - '@typescript-eslint/types': 8.47.0 - '@typescript-eslint/typescript-estree': 8.47.0(typescript@5.9.3) - '@typescript-eslint/utils': 8.47.0(eslint@9.39.1)(typescript@5.9.3) + '@typescript-eslint/types': 8.48.0 + '@typescript-eslint/typescript-estree': 8.48.0(typescript@5.9.3) + '@typescript-eslint/utils': 8.48.0(eslint@9.39.1)(typescript@5.9.3) debug: 4.4.3 eslint: 9.39.1 ts-api-utils: 2.1.0(typescript@5.9.3) @@ -3687,7 +3687,7 @@ snapshots: '@typescript-eslint/types@8.46.4': {} - '@typescript-eslint/types@8.47.0': {} + '@typescript-eslint/types@8.48.0': {} '@typescript-eslint/typescript-estree@8.37.0(typescript@5.9.3)': dependencies: @@ -3721,17 +3721,16 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/typescript-estree@8.47.0(typescript@5.9.3)': + '@typescript-eslint/typescript-estree@8.48.0(typescript@5.9.3)': dependencies: - '@typescript-eslint/project-service': 8.47.0(typescript@5.9.3) - '@typescript-eslint/tsconfig-utils': 8.47.0(typescript@5.9.3) - '@typescript-eslint/types': 8.47.0 - '@typescript-eslint/visitor-keys': 8.47.0 + '@typescript-eslint/project-service': 8.48.0(typescript@5.9.3) + '@typescript-eslint/tsconfig-utils': 8.48.0(typescript@5.9.3) + '@typescript-eslint/types': 8.48.0 + '@typescript-eslint/visitor-keys': 8.48.0 debug: 4.4.3 - fast-glob: 3.3.3 - is-glob: 4.0.3 minimatch: 9.0.5 semver: 7.7.3 + tinyglobby: 0.2.15 ts-api-utils: 2.1.0(typescript@5.9.3) typescript: 5.9.3 transitivePeerDependencies: @@ -3748,12 +3747,12 @@ snapshots: transitivePeerDependencies: - supports-color - '@typescript-eslint/utils@8.47.0(eslint@9.39.1)(typescript@5.9.3)': + '@typescript-eslint/utils@8.48.0(eslint@9.39.1)(typescript@5.9.3)': dependencies: '@eslint-community/eslint-utils': 4.9.0(eslint@9.39.1) - '@typescript-eslint/scope-manager': 8.47.0 - '@typescript-eslint/types': 8.47.0 - '@typescript-eslint/typescript-estree': 8.47.0(typescript@5.9.3) + '@typescript-eslint/scope-manager': 8.48.0 + '@typescript-eslint/types': 8.48.0 + '@typescript-eslint/typescript-estree': 8.48.0(typescript@5.9.3) eslint: 9.39.1 typescript: 5.9.3 transitivePeerDependencies: @@ -3769,9 +3768,9 @@ snapshots: '@typescript-eslint/types': 8.46.4 eslint-visitor-keys: 4.2.1 - '@typescript-eslint/visitor-keys@8.47.0': + '@typescript-eslint/visitor-keys@8.48.0': dependencies: - '@typescript-eslint/types': 8.47.0 + '@typescript-eslint/types': 8.48.0 eslint-visitor-keys: 4.2.1 '@videojs/http-streaming@3.17.2(video.js@8.23.4)': @@ -3892,11 +3891,11 @@ snapshots: transitivePeerDependencies: - '@types/eslint' - '@vue/eslint-config-typescript@14.6.0(eslint-plugin-vue@10.6.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)))(eslint@9.39.1)(typescript@5.9.3)': + '@vue/eslint-config-typescript@14.6.0(eslint-plugin-vue@10.6.1(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)))(eslint@9.39.1)(typescript@5.9.3)': dependencies: '@typescript-eslint/utils': 8.37.0(eslint@9.39.1)(typescript@5.9.3) eslint: 9.39.1 - eslint-plugin-vue: 10.6.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)) + eslint-plugin-vue: 10.6.1(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)) fast-glob: 3.3.3 typescript-eslint: 8.37.0(eslint@9.39.1)(typescript@5.9.3) vue-eslint-parser: 10.2.0(eslint@9.39.1) @@ -4229,7 +4228,7 @@ snapshots: optionalDependencies: eslint-config-prettier: 10.1.8(eslint@9.39.1) - eslint-plugin-vue@10.6.0(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)): + eslint-plugin-vue@10.6.1(@typescript-eslint/parser@8.37.0(eslint@9.39.1)(typescript@5.9.3))(eslint@9.39.1)(vue-eslint-parser@10.2.0(eslint@9.39.1)): dependencies: '@eslint-community/eslint-utils': 4.9.0(eslint@9.39.1) eslint: 9.39.1 @@ -5021,10 +5020,10 @@ snapshots: focus-trap: 7.6.2 vue: 3.5.25(typescript@5.9.3) - vue-i18n@11.2.1(vue@3.5.25(typescript@5.9.3)): + vue-i18n@11.2.2(vue@3.5.25(typescript@5.9.3)): dependencies: - '@intlify/core-base': 11.2.1 - '@intlify/shared': 11.2.1 + '@intlify/core-base': 11.2.2 + '@intlify/shared': 11.2.2 '@vue/devtools-api': 6.6.4 vue: 3.5.25(typescript@5.9.3) diff --git a/filebrowser/frontend/src/i18n/hr.json b/filebrowser/frontend/src/i18n/hr.json index 04bcfa2ef8..e466a5ede3 100644 --- a/filebrowser/frontend/src/i18n/hr.json +++ b/filebrowser/frontend/src/i18n/hr.json @@ -102,7 +102,7 @@ "username": "Korisničko ime", "usernameTaken": "Korisničko ime zauzeto", "wrongCredentials": "Neispravno korisničko ime/lozinka", - "passwordTooShort": "Password must be at least {min} characters", + "passwordTooShort": "Lozinka mora sadržavati minimalno {min} znakova", "logout_reasons": { "inactivity": "Odjavljeni ste zbog neaktivnosti." } @@ -167,7 +167,7 @@ "allowNew": "Stvori nove datoteke i mape", "allowPublish": "Objavi nove objave i stranice", "allowSignup": "Dopusti registraciju korisnicima", - "hideLoginButton": "Hide the login button from public pages", + "hideLoginButton": "Sakrij tipku za prijavu s javnih stranica", "avoidChanges": "(ostavite prazno kako biste izbjegli promjene)", "branding": "Brendiranje", "brandingDirectoryPath": "Put brendiranja", diff --git a/lede/target/linux/qualcommax/files/arch/arm64/boot/dts/qcom/ipq5018-gl-b3000.dts b/lede/target/linux/qualcommax/files/arch/arm64/boot/dts/qcom/ipq5018-gl-b3000.dts index 9bb1fabe82..a6bd7a3232 100644 --- a/lede/target/linux/qualcommax/files/arch/arm64/boot/dts/qcom/ipq5018-gl-b3000.dts +++ b/lede/target/linux/qualcommax/files/arch/arm64/boot/dts/qcom/ipq5018-gl-b3000.dts @@ -90,7 +90,7 @@ // MAC1 ---SGMII---> QCA8337 SerDes &dp2 { status = "okay"; - nvmem-cells = <&macaddr_dp2>; + nvmem-cells = <&macaddr_dp2 0>; nvmem-cell-names = "mac-address"; fixed-link { @@ -230,11 +230,8 @@ compatible = "qcom,smem-part"; partition-0-art { - compatible = "fixed-partitions"; - label = "0:ART"; + label = "0:art"; read-only; - #address-cells = <1>; - #size-cells = <1>; nvmem-layout { compatible = "fixed-layout"; @@ -244,7 +241,7 @@ macaddr_dp2: macaddr@0 { compatible = "mac-base"; #nvmem-cell-cells = <1>; - reg = <0x0 0x6>; + reg = <0x6 0x6>; }; }; }; diff --git a/mieru/pkg/protocol/mux.go b/mieru/pkg/protocol/mux.go index c78b759559..31e87b92b7 100644 --- a/mieru/pkg/protocol/mux.go +++ b/mieru/pkg/protocol/mux.go @@ -683,7 +683,7 @@ func (m *Mux) maybePickExistingUnderlay() Underlay { // cleanUnderlay removes closed underlays. // This method MUST be called only when holding the mu lock. -func (m *Mux) cleanUnderlay(alsoDisableIdleUnderlay bool) { +func (m *Mux) cleanUnderlay(alsoDisableIdleOrOverloadUnderlay bool) { remaining := make([]Underlay, 0) disable := 0 close := 0 @@ -691,11 +691,24 @@ func (m *Mux) cleanUnderlay(alsoDisableIdleUnderlay bool) { select { case <-underlay.Done(): default: - if alsoDisableIdleUnderlay && underlay.SessionCount() == 0 { - if underlay.Scheduler().TryDisable() { + if alsoDisableIdleOrOverloadUnderlay { + // Disable idle underlay. + if underlay.SessionCount() == 0 { + if underlay.Scheduler().TryDisableIdle() { + disable++ + } + } + + // Disable overloaded underlay. + // If multiplexFactor is 1, the limit is 1 GiB. + var trafficVolumeLimit int64 = 512 * 1024 * 1024 << m.multiplexFactor + if underlay.Scheduler().DisableTime().IsZero() && (underlay.InBytes() > trafficVolumeLimit || underlay.OutBytes() > trafficVolumeLimit) { + underlay.Scheduler().SetRemainingTime(0) disable++ } } + + // Close idle underlay. if underlay.SessionCount() == 0 && underlay.Scheduler().Idle() { underlay.Close() close++ diff --git a/mieru/pkg/protocol/scheduler.go b/mieru/pkg/protocol/scheduler.go index 5e845d1826..8b9f00c11a 100644 --- a/mieru/pkg/protocol/scheduler.go +++ b/mieru/pkg/protocol/scheduler.go @@ -57,6 +57,13 @@ func (c *ScheduleController) DecPending() { c.lastScheduleTime = time.Now() } +// DisableTime returns the underlay disable time. +func (c *ScheduleController) DisableTime() time.Time { + c.mu.Lock() + defer c.mu.Unlock() + return c.disableTime +} + // IsDisabled returns true if scheduling new sessions to the underlay is disabled. func (c *ScheduleController) IsDisabled() bool { c.mu.Lock() @@ -71,8 +78,8 @@ func (c *ScheduleController) Idle() bool { return !c.disableTime.IsZero() && time.Since(c.lastScheduleTime) > scheduleIdleTime && time.Since(c.disableTime) > scheduleIdleTime } -// TryDisable tries to disable scheduling new sessions. -func (c *ScheduleController) TryDisable() (successful bool) { +// TryDisableIdle tries to disable scheduling new sessions on idle underlay. +func (c *ScheduleController) TryDisableIdle() (ok bool) { c.mu.Lock() defer c.mu.Unlock() if !c.disableTime.IsZero() { @@ -88,12 +95,12 @@ func (c *ScheduleController) TryDisable() (successful bool) { return true } -// SetRemainingTime disables the scheduler after the given duration. +// SetRemainingTime unconditionally disables the scheduler after the given duration. // Do nothing if the scheduler has already been disabled. func (c *ScheduleController) SetRemainingTime(d time.Duration) { c.mu.Lock() defer c.mu.Unlock() - if d <= 0 || !c.disableTime.IsZero() { + if d < 0 || !c.disableTime.IsZero() { return } c.disableTime = time.Now().Add(d) diff --git a/mieru/pkg/protocol/underlay.go b/mieru/pkg/protocol/underlay.go index c04402c971..b7b09dbbe6 100644 --- a/mieru/pkg/protocol/underlay.go +++ b/mieru/pkg/protocol/underlay.go @@ -72,6 +72,12 @@ type Underlay interface { // Returns detailed information of all the sessions. SessionInfos() []*appctlpb.SessionInfo + // Number of bytes received from the network. + InBytes() int64 + + // Number of bytes sent to the network. + OutBytes() int64 + // Run event loop. // The underlay needs to be closed when this returns. RunEventLoop(context.Context) error diff --git a/mieru/pkg/protocol/underlay_base.go b/mieru/pkg/protocol/underlay_base.go index 02b03840f2..5d13ff5856 100644 --- a/mieru/pkg/protocol/underlay_base.go +++ b/mieru/pkg/protocol/underlay_base.go @@ -21,6 +21,7 @@ import ( "io" "net" "sync" + "sync/atomic" "time" "github.com/enfein/mieru/v3/pkg/appctl/appctlpb" @@ -52,6 +53,9 @@ type baseUnderlay struct { sendMutex sync.Mutex // protect writing data to the connection closeMutex sync.Mutex // protect closing the connection + inBytes atomic.Int64 + outBytes atomic.Int64 + // ---- client fields ---- scheduler *ScheduleController } @@ -193,6 +197,14 @@ func (b *baseUnderlay) SessionInfos() []*appctlpb.SessionInfo { return res } +func (b *baseUnderlay) InBytes() int64 { + return b.inBytes.Load() +} + +func (b *baseUnderlay) OutBytes() int64 { + return b.outBytes.Load() +} + func (b *baseUnderlay) RunEventLoop(ctx context.Context) error { return stderror.ErrUnsupported } diff --git a/mieru/pkg/protocol/underlay_packet.go b/mieru/pkg/protocol/underlay_packet.go index cdd98159eb..2ec83425c6 100644 --- a/mieru/pkg/protocol/underlay_packet.go +++ b/mieru/pkg/protocol/underlay_packet.go @@ -356,6 +356,7 @@ func (u *PacketUnderlay) readOneSegment() error { continue } b = b[:n] + u.inBytes.Add(int64(n)) if u.isClient { metrics.DownloadBytes.Add(int64(n)) } else { @@ -692,6 +693,7 @@ func (u *PacketUnderlay) writeOneSegment(seg *segment, addr net.Addr) error { if _, err := u.conn.WriteTo(dataToSend, addr); err != nil { return fmt.Errorf("WriteTo() failed: %w", err) } + u.outBytes.Add(int64(len(dataToSend))) if u.isClient { metrics.UploadBytes.Add(int64(len(dataToSend))) } else { @@ -731,6 +733,7 @@ func (u *PacketUnderlay) writeOneSegment(seg *segment, addr net.Addr) error { if _, err := u.conn.WriteTo(dataToSend, addr); err != nil { return fmt.Errorf("WriteTo() failed: %w", err) } + u.outBytes.Add(int64(len(dataToSend))) if u.isClient { metrics.UploadBytes.Add(int64(len(dataToSend))) } else { diff --git a/mieru/pkg/protocol/underlay_stream.go b/mieru/pkg/protocol/underlay_stream.go index 9c499a5af4..b763697954 100644 --- a/mieru/pkg/protocol/underlay_stream.go +++ b/mieru/pkg/protocol/underlay_stream.go @@ -305,6 +305,7 @@ func (t *StreamUnderlay) readOneSegment() (*segment, error) { err = fmt.Errorf("metadata: read %d bytes from StreamUnderlay failed: %w", readLen, err) return nil, stderror.WrapErrorWithType(err, stderror.NETWORK_ERROR) } + t.inBytes.Add(int64(len(encryptedMeta))) if t.isClient { metrics.DownloadBytes.Add(int64(len(encryptedMeta))) } else { @@ -398,6 +399,7 @@ func (t *StreamUnderlay) readSessionSegment(ss *sessionStruct) (*segment, error) err = fmt.Errorf("payload: read %d bytes from StreamUnderlay failed: %w", ss.payloadLen+cipher.DefaultOverhead, err) return nil, stderror.WrapErrorWithType(err, stderror.NETWORK_ERROR) } + t.inBytes.Add(int64(len(encryptedPayload))) if t.isClient { metrics.DownloadBytes.Add(int64(len(encryptedPayload))) } else { @@ -428,6 +430,7 @@ func (t *StreamUnderlay) readSessionSegment(ss *sessionStruct) (*segment, error) err = fmt.Errorf("padding: read %d bytes from StreamUnderlay failed: %w", ss.suffixLen, err) return nil, stderror.WrapErrorWithType(err, stderror.NETWORK_ERROR) } + t.inBytes.Add(int64(len(padding))) if t.isClient { metrics.DownloadBytes.Add(int64(len(padding))) } else { @@ -453,6 +456,7 @@ func (t *StreamUnderlay) readDataAckSegment(das *dataAckStruct) (*segment, error err = fmt.Errorf("padding: read %d bytes from StreamUnderlay failed: %w", das.prefixLen, err) return nil, stderror.WrapErrorWithType(err, stderror.NETWORK_ERROR) } + t.inBytes.Add(int64(len(padding1))) if t.isClient { metrics.DownloadBytes.Add(int64(len(padding1))) } else { @@ -465,6 +469,7 @@ func (t *StreamUnderlay) readDataAckSegment(das *dataAckStruct) (*segment, error err = fmt.Errorf("payload: read %d bytes from StreamUnderlay failed: %w", das.payloadLen+cipher.DefaultOverhead, err) return nil, stderror.WrapErrorWithType(err, stderror.NETWORK_ERROR) } + t.inBytes.Add(int64(len(encryptedPayload))) if t.isClient { metrics.DownloadBytes.Add(int64(len(encryptedPayload))) } else { @@ -495,6 +500,7 @@ func (t *StreamUnderlay) readDataAckSegment(das *dataAckStruct) (*segment, error err = fmt.Errorf("padding: read %d bytes from StreamUnderlay failed: %w", das.suffixLen, err) return nil, stderror.WrapErrorWithType(err, stderror.NETWORK_ERROR) } + t.inBytes.Add(int64(len(padding2))) if t.isClient { metrics.DownloadBytes.Add(int64(len(padding2))) } else { @@ -549,6 +555,7 @@ func (t *StreamUnderlay) writeOneSegment(seg *segment) error { if _, err := t.conn.Write(dataToSend); err != nil { return fmt.Errorf("Write() failed: %w", err) } + t.outBytes.Add(int64(len(dataToSend))) if t.isClient { metrics.UploadBytes.Add(int64(len(dataToSend))) } else { @@ -590,6 +597,7 @@ func (t *StreamUnderlay) writeOneSegment(seg *segment) error { if _, err := t.conn.Write(dataToSend); err != nil { return fmt.Errorf("Write() failed: %w", err) } + t.outBytes.Add(int64(len(dataToSend))) if t.isClient { metrics.UploadBytes.Add(int64(len(dataToSend))) } else { diff --git a/mihomo/common/structure/structure.go b/mihomo/common/structure/structure.go index bf79f7dd27..840e4f6cad 100644 --- a/mihomo/common/structure/structure.go +++ b/mihomo/common/structure/structure.go @@ -289,7 +289,7 @@ func (d *Decoder) decodeBool(name string, data any, val reflect.Value) (err erro case isInt(kind) && d.option.WeaklyTypedInput: val.SetBool(dataVal.Int() != 0) case isUint(kind) && d.option.WeaklyTypedInput: - val.SetString(strconv.FormatUint(dataVal.Uint(), 10)) + val.SetBool(dataVal.Uint() != 0) default: err = fmt.Errorf( "'%s' expected type '%s', got unconvertible type '%s'", diff --git a/openwrt-packages/ddns-go/Makefile b/openwrt-packages/ddns-go/Makefile index 1201df30ad..7c9e8195dd 100644 --- a/openwrt-packages/ddns-go/Makefile +++ b/openwrt-packages/ddns-go/Makefile @@ -8,12 +8,12 @@ include $(TOPDIR)/rules.mk PKG_NAME:=ddns-go -PKG_VERSION:=6.13.2 +PKG_VERSION:=6.13.3 PKG_RELEASE:=1 PKG_SOURCE:=$(PKG_NAME)-$(PKG_VERSION).tar.gz PKG_SOURCE_URL:=https://codeload.github.com/jeessy2/ddns-go/tar.gz/v$(PKG_VERSION)? -PKG_HASH:=a729096b6d0d769223a21dfd82040b264d6f672d6018d08157f400de321d381e +PKG_HASH:=b2b6e48988abec12bba37ac9fb2f9a6777d28125c0ab2ac3be1d8659b8b7b9a5 PKG_LICENSE:=MIT PKG_LICENSE_FILES:=LICENSE diff --git a/openwrt-passwall/luci-app-passwall/htdocs/luci-static/resources/view/passwall/Sortable.min.js b/openwrt-passwall/luci-app-passwall/htdocs/luci-static/resources/view/passwall/Sortable.min.js new file mode 100644 index 0000000000..95423a6491 --- /dev/null +++ b/openwrt-passwall/luci-app-passwall/htdocs/luci-static/resources/view/passwall/Sortable.min.js @@ -0,0 +1,2 @@ +/*! Sortable 1.15.6 - MIT | git://github.com/SortableJS/Sortable.git */ +!function(t,e){"object"==typeof exports&&"undefined"!=typeof module?module.exports=e():"function"==typeof define&&define.amd?define(e):(t=t||self).Sortable=e()}(this,function(){"use strict";function e(e,t){var n,o=Object.keys(e);return Object.getOwnPropertySymbols&&(n=Object.getOwnPropertySymbols(e),t&&(n=n.filter(function(t){return Object.getOwnPropertyDescriptor(e,t).enumerable})),o.push.apply(o,n)),o}function I(o){for(var t=1;tt.length)&&(e=t.length);for(var n=0,o=new Array(e);n"===e[0]&&(e=e.substring(1)),t))try{if(t.matches)return t.matches(e);if(t.msMatchesSelector)return t.msMatchesSelector(e);if(t.webkitMatchesSelector)return t.webkitMatchesSelector(e)}catch(t){return}}function g(t){return t.host&&t!==document&&t.host.nodeType?t.host:t.parentNode}function P(t,e,n,o){if(t){n=n||document;do{if(null!=e&&(">"!==e[0]||t.parentNode===n)&&f(t,e)||o&&t===n)return t}while(t!==n&&(t=g(t)))}return null}var m,v=/\s+/g;function k(t,e,n){var o;t&&e&&(t.classList?t.classList[n?"add":"remove"](e):(o=(" "+t.className+" ").replace(v," ").replace(" "+e+" "," "),t.className=(o+(n?" "+e:"")).replace(v," ")))}function R(t,e,n){var o=t&&t.style;if(o){if(void 0===n)return document.defaultView&&document.defaultView.getComputedStyle?n=document.defaultView.getComputedStyle(t,""):t.currentStyle&&(n=t.currentStyle),void 0===e?n:n[e];o[e=!(e in o||-1!==e.indexOf("webkit"))?"-webkit-"+e:e]=n+("string"==typeof n?"":"px")}}function b(t,e){var n="";if("string"==typeof t)n=t;else do{var o=R(t,"transform")}while(o&&"none"!==o&&(n=o+" "+n),!e&&(t=t.parentNode));var i=window.DOMMatrix||window.WebKitCSSMatrix||window.CSSMatrix||window.MSCSSMatrix;return i&&new i(n)}function D(t,e,n){if(t){var o=t.getElementsByTagName(e),i=0,r=o.length;if(n)for(;i=n.left-e&&i<=n.right+e,e=r>=n.top-e&&r<=n.bottom+e;return o&&e?a=t:void 0}}),a);if(e){var n,o={};for(n in t)t.hasOwnProperty(n)&&(o[n]=t[n]);o.target=o.rootEl=e,o.preventDefault=void 0,o.stopPropagation=void 0,e[K]._onDragOver(o)}}var i,r,a}function Ft(t){Z&&Z.parentNode[K]._isOutsideThisEl(t.target)}function jt(t,e){if(!t||!t.nodeType||1!==t.nodeType)throw"Sortable: `el` must be an HTMLElement, not ".concat({}.toString.call(t));this.el=t,this.options=e=a({},e),t[K]=this;var n,o,i={group:null,sort:!0,disabled:!1,store:null,handle:null,draggable:/^[uo]l$/i.test(t.nodeName)?">li":">*",swapThreshold:1,invertSwap:!1,invertedSwapThreshold:null,removeCloneOnHide:!0,direction:function(){return kt(t,this.options)},ghostClass:"sortable-ghost",chosenClass:"sortable-chosen",dragClass:"sortable-drag",ignore:"a, img",filter:null,preventOnFilter:!0,animation:0,easing:null,setData:function(t,e){t.setData("Text",e.textContent)},dropBubble:!1,dragoverBubble:!1,dataIdAttr:"data-id",delay:0,delayOnTouchOnly:!1,touchStartThreshold:(Number.parseInt?Number:window).parseInt(window.devicePixelRatio,10)||1,forceFallback:!1,fallbackClass:"sortable-fallback",fallbackOnBody:!1,fallbackTolerance:0,fallbackOffset:{x:0,y:0},supportPointer:!1!==jt.supportPointer&&"PointerEvent"in window&&(!u||c),emptyInsertThreshold:5};for(n in z.initializePlugins(this,t,i),i)n in e||(e[n]=i[n]);for(o in Rt(e),this)"_"===o.charAt(0)&&"function"==typeof this[o]&&(this[o]=this[o].bind(this));this.nativeDraggable=!e.forceFallback&&It,this.nativeDraggable&&(this.options.touchStartThreshold=1),e.supportPointer?h(t,"pointerdown",this._onTapStart):(h(t,"mousedown",this._onTapStart),h(t,"touchstart",this._onTapStart)),this.nativeDraggable&&(h(t,"dragover",this),h(t,"dragenter",this)),St.push(this.el),e.store&&e.store.get&&this.sort(e.store.get(this)||[]),a(this,A())}function Ht(t,e,n,o,i,r,a,l){var s,c,u=t[K],d=u.options.onMove;return!window.CustomEvent||y||w?(s=document.createEvent("Event")).initEvent("move",!0,!0):s=new CustomEvent("move",{bubbles:!0,cancelable:!0}),s.to=e,s.from=t,s.dragged=n,s.draggedRect=o,s.related=i||e,s.relatedRect=r||X(e),s.willInsertAfter=l,s.originalEvent=a,t.dispatchEvent(s),c=d?d.call(u,s,a):c}function Lt(t){t.draggable=!1}function Kt(){xt=!1}function Wt(t){return setTimeout(t,0)}function zt(t){return clearTimeout(t)}jt.prototype={constructor:jt,_isOutsideThisEl:function(t){this.el.contains(t)||t===this.el||(vt=null)},_getDirection:function(t,e){return"function"==typeof this.options.direction?this.options.direction.call(this,t,e,Z):this.options.direction},_onTapStart:function(e){if(e.cancelable){var n=this,o=this.el,t=this.options,i=t.preventOnFilter,r=e.type,a=e.touches&&e.touches[0]||e.pointerType&&"touch"===e.pointerType&&e,l=(a||e).target,s=e.target.shadowRoot&&(e.path&&e.path[0]||e.composedPath&&e.composedPath()[0])||l,c=t.filter;if(!function(t){Ot.length=0;var e=t.getElementsByTagName("input"),n=e.length;for(;n--;){var o=e[n];o.checked&&Ot.push(o)}}(o),!Z&&!(/mousedown|pointerdown/.test(r)&&0!==e.button||t.disabled)&&!s.isContentEditable&&(this.nativeDraggable||!u||!l||"SELECT"!==l.tagName.toUpperCase())&&!((l=P(l,t.draggable,o,!1))&&l.animated||et===l)){if(it=j(l),at=j(l,t.draggable),"function"==typeof c){if(c.call(this,e,l,this))return V({sortable:n,rootEl:s,name:"filter",targetEl:l,toEl:o,fromEl:o}),U("filter",n,{evt:e}),void(i&&e.preventDefault())}else if(c=c&&c.split(",").some(function(t){if(t=P(s,t.trim(),o,!1))return V({sortable:n,rootEl:t,name:"filter",targetEl:l,fromEl:o,toEl:o}),U("filter",n,{evt:e}),!0}))return void(i&&e.preventDefault());t.handle&&!P(s,t.handle,o,!1)||this._prepareDragStart(e,a,l)}}},_prepareDragStart:function(t,e,n){var o,i=this,r=i.el,a=i.options,l=r.ownerDocument;n&&!Z&&n.parentNode===r&&(o=X(n),J=r,$=(Z=n).parentNode,tt=Z.nextSibling,et=n,st=a.group,ut={target:jt.dragged=Z,clientX:(e||t).clientX,clientY:(e||t).clientY},ft=ut.clientX-o.left,gt=ut.clientY-o.top,this._lastX=(e||t).clientX,this._lastY=(e||t).clientY,Z.style["will-change"]="all",o=function(){U("delayEnded",i,{evt:t}),jt.eventCanceled?i._onDrop():(i._disableDelayedDragEvents(),!s&&i.nativeDraggable&&(Z.draggable=!0),i._triggerDragStart(t,e),V({sortable:i,name:"choose",originalEvent:t}),k(Z,a.chosenClass,!0))},a.ignore.split(",").forEach(function(t){D(Z,t.trim(),Lt)}),h(l,"dragover",Bt),h(l,"mousemove",Bt),h(l,"touchmove",Bt),a.supportPointer?(h(l,"pointerup",i._onDrop),this.nativeDraggable||h(l,"pointercancel",i._onDrop)):(h(l,"mouseup",i._onDrop),h(l,"touchend",i._onDrop),h(l,"touchcancel",i._onDrop)),s&&this.nativeDraggable&&(this.options.touchStartThreshold=4,Z.draggable=!0),U("delayStart",this,{evt:t}),!a.delay||a.delayOnTouchOnly&&!e||this.nativeDraggable&&(w||y)?o():jt.eventCanceled?this._onDrop():(a.supportPointer?(h(l,"pointerup",i._disableDelayedDrag),h(l,"pointercancel",i._disableDelayedDrag)):(h(l,"mouseup",i._disableDelayedDrag),h(l,"touchend",i._disableDelayedDrag),h(l,"touchcancel",i._disableDelayedDrag)),h(l,"mousemove",i._delayedDragTouchMoveHandler),h(l,"touchmove",i._delayedDragTouchMoveHandler),a.supportPointer&&h(l,"pointermove",i._delayedDragTouchMoveHandler),i._dragStartTimer=setTimeout(o,a.delay)))},_delayedDragTouchMoveHandler:function(t){t=t.touches?t.touches[0]:t;Math.max(Math.abs(t.clientX-this._lastX),Math.abs(t.clientY-this._lastY))>=Math.floor(this.options.touchStartThreshold/(this.nativeDraggable&&window.devicePixelRatio||1))&&this._disableDelayedDrag()},_disableDelayedDrag:function(){Z&&Lt(Z),clearTimeout(this._dragStartTimer),this._disableDelayedDragEvents()},_disableDelayedDragEvents:function(){var t=this.el.ownerDocument;p(t,"mouseup",this._disableDelayedDrag),p(t,"touchend",this._disableDelayedDrag),p(t,"touchcancel",this._disableDelayedDrag),p(t,"pointerup",this._disableDelayedDrag),p(t,"pointercancel",this._disableDelayedDrag),p(t,"mousemove",this._delayedDragTouchMoveHandler),p(t,"touchmove",this._delayedDragTouchMoveHandler),p(t,"pointermove",this._delayedDragTouchMoveHandler)},_triggerDragStart:function(t,e){e=e||"touch"==t.pointerType&&t,!this.nativeDraggable||e?this.options.supportPointer?h(document,"pointermove",this._onTouchMove):h(document,e?"touchmove":"mousemove",this._onTouchMove):(h(Z,"dragend",this),h(J,"dragstart",this._onDragStart));try{document.selection?Wt(function(){document.selection.empty()}):window.getSelection().removeAllRanges()}catch(t){}},_dragStarted:function(t,e){var n;Dt=!1,J&&Z?(U("dragStarted",this,{evt:e}),this.nativeDraggable&&h(document,"dragover",Ft),n=this.options,t||k(Z,n.dragClass,!1),k(Z,n.ghostClass,!0),jt.active=this,t&&this._appendGhost(),V({sortable:this,name:"start",originalEvent:e})):this._nulling()},_emulateDragOver:function(){if(dt){this._lastX=dt.clientX,this._lastY=dt.clientY,Xt();for(var t=document.elementFromPoint(dt.clientX,dt.clientY),e=t;t&&t.shadowRoot&&(t=t.shadowRoot.elementFromPoint(dt.clientX,dt.clientY))!==e;)e=t;if(Z.parentNode[K]._isOutsideThisEl(t),e)do{if(e[K])if(e[K]._onDragOver({clientX:dt.clientX,clientY:dt.clientY,target:t,rootEl:e})&&!this.options.dragoverBubble)break}while(e=g(t=e));Yt()}},_onTouchMove:function(t){if(ut){var e=this.options,n=e.fallbackTolerance,o=e.fallbackOffset,i=t.touches?t.touches[0]:t,r=Q&&b(Q,!0),a=Q&&r&&r.a,l=Q&&r&&r.d,e=At&&wt&&E(wt),a=(i.clientX-ut.clientX+o.x)/(a||1)+(e?e[0]-Tt[0]:0)/(a||1),l=(i.clientY-ut.clientY+o.y)/(l||1)+(e?e[1]-Tt[1]:0)/(l||1);if(!jt.active&&!Dt){if(n&&Math.max(Math.abs(i.clientX-this._lastX),Math.abs(i.clientY-this._lastY))E.right+10||S.clientY>x.bottom&&S.clientX>x.left:S.clientY>E.bottom+10||S.clientX>x.right&&S.clientY>x.top)||m.animated)){if(m&&(t=n,e=r,C=X(B((_=this).el,0,_.options,!0)),_=L(_.el,_.options,Q),e?t.clientX<_.left-10||t.clientY" .. str or "" local num = 0 m.uci:foreach(appname, "nodes", function(s) - if s["group"] ~= "" and s["group"] == remark then + if s["group"] and s["group"]:lower() == remark:lower() then num = num + 1 end end) diff --git a/openwrt-passwall/luci-app-passwall/luasrc/view/passwall/node_list/node_list.htm b/openwrt-passwall/luci-app-passwall/luasrc/view/passwall/node_list/node_list.htm index f8f16e732e..5724adeab0 100644 --- a/openwrt-passwall/luci-app-passwall/luasrc/view/passwall/node_list/node_list.htm +++ b/openwrt-passwall/luci-app-passwall/luasrc/view/passwall/node_list/node_list.htm @@ -1,6 +1,7 @@ <% local api = require "luci.passwall.api" -%> + <% if api.is_js_luci() then -%> @@ -210,21 +238,6 @@ table td, .table .td { document.getElementById("set_node_name").innerHTML = ""; } - function row_swap(btn, up) { - const row = btn.closest("tr"); - if (!row) return; - const parent = row.parentNode; - if (up) { - const prev = row.previousElementSibling; - if (prev && !prev.classList.contains("cbi-section-table-titles")) { - parent.insertBefore(row, prev); - } - } else { - const next = row.nextElementSibling; - if (next) parent.insertBefore(next, row); - } - } - function row_top(btn) { const row = btn.closest("tr"); if (!row) return; @@ -548,6 +561,60 @@ table td, .table .td { } } } + + //列表拖动重排 + function initSortableForTable(table) { + if (!table) return null; + var root = table.querySelector('tbody') || table; + if (root._sortable_initialized) return root._sortable_instance; + root._sortable_initialized = true; + var opts = { + handle: ".drag-handle", + draggable: "tr.cbi-section-table-row", + animation: 150, + ghostClass: "dragging-row", + fallbackOnBody: true, + forceFallback: false, + swapThreshold: 0.65, + onEnd: function (evt) { + //var group = evt.to.id.replace("cbi-passwall-nodes-", "").replace("-table", ""); + //save_current_page_order(group); // 自动提交保存 + } + }; + try { + var instance = Sortable.create(root, opts); + root._sortable_instance = instance; + return instance; + } catch (err) { + root._sortable_initialized = false; + console.error("Sortable init failed:", err); + return null; + } + } + + function initAllSortable(group_nodes) { + if (typeof Sortable === 'undefined') { + var retries = 0; + var maxRetries = 25; + var t = setInterval(function () { + retries++; + if (typeof Sortable !== 'undefined') { + clearInterval(t); + for (var group in group_nodes) { + var table = document.getElementById("cbi-passwall-nodes-" + group + "-table"); + initSortableForTable(table); + } + } else if (retries >= maxRetries) { + clearInterval(t); + } + }, 200); + } else { + for (var group in group_nodes) { + var table = document.getElementById("cbi-passwall-nodes-" + group + "-table"); + initSortableForTable(table); + } + } + } @@ -537,11 +580,12 @@ table td, .table .td { {{url_test}}
- - + + + /{{id}}'" alt="<%:Edit%>" title="<%:Edit%>">
diff --git a/small/luci-app-passwall/po/zh-cn/passwall.po b/small/luci-app-passwall/po/zh-cn/passwall.po index 8e9fefa8c8..f8d85e434e 100644 --- a/small/luci-app-passwall/po/zh-cn/passwall.po +++ b/small/luci-app-passwall/po/zh-cn/passwall.po @@ -421,6 +421,12 @@ msgstr "节点备注" msgid "Add Mode" msgstr "添加方式" +msgid "Save Order" +msgstr "保存当前顺序" + +msgid "Saved current page order successfully." +msgstr "保存当前页面顺序成功。" + msgid "Type" msgstr "类型" diff --git a/small/luci-app-ssr-plus/root/usr/share/shadowsocksr/subscribe.lua b/small/luci-app-ssr-plus/root/usr/share/shadowsocksr/subscribe.lua index cf7c84d8af..d6e9c10b67 100755 --- a/small/luci-app-ssr-plus/root/usr/share/shadowsocksr/subscribe.lua +++ b/small/luci-app-ssr-plus/root/usr/share/shadowsocksr/subscribe.lua @@ -760,13 +760,16 @@ local function processData(szType, content) -- 未指定peer(sni)默认使用remote addr result.tls_host = params.peer or params.sni end - if params.allowInsecure then + params.allowinsecure = params.allowinsecure or params.insecure + if params.allowinsecure then -- 处理 insecure 参数 if params.allowinsecure == "1" or params.allowinsecure == "0" then - result.insecure = params.allowInsecure + result.insecure = params.allowinsecure else result.insecure = string.lower(params.allowinsecure) == "true" and "1" or "0" end + else + result.insecure = "0" end if params.tfo then -- 处理 fast open 参数 diff --git a/small/v2ray-geodata/Makefile b/small/v2ray-geodata/Makefile index f5834e3a8a..5f0274ae54 100644 --- a/small/v2ray-geodata/Makefile +++ b/small/v2ray-geodata/Makefile @@ -21,13 +21,13 @@ define Download/geoip HASH:=2445b44d9ae3ab9a867c9d1e0e244646c4c378622e14b9afaf3658ecf46a40b9 endef -GEOSITE_VER:=20251125142217 +GEOSITE_VER:=20251126114359 GEOSITE_FILE:=dlc.dat.$(GEOSITE_VER) define Download/geosite URL:=https://github.com/v2fly/domain-list-community/releases/download/$(GEOSITE_VER)/ URL_FILE:=dlc.dat FILE:=$(GEOSITE_FILE) - HASH:=ae6033c884713da8e98f2c1d8167141fbb47aadd297b3ba81450d87582827d5c + HASH:=74559fa06bfb073ac5eaa8be34213ff66e6bcbab96512e94c6e6693ee083ac66 endef GEOSITE_IRAN_VER:=202511240043 diff --git a/v2rayn/.github/workflows/build-linux.yml b/v2rayn/.github/workflows/build-linux.yml index 1cf32d891e..a90ecddea6 100644 --- a/v2rayn/.github/workflows/build-linux.yml +++ b/v2rayn/.github/workflows/build-linux.yml @@ -37,7 +37,7 @@ jobs: fetch-depth: '0' - name: Setup .NET - uses: actions/setup-dotnet@v5.0.0 + uses: actions/setup-dotnet@v5.0.1 with: dotnet-version: '8.0.x' diff --git a/v2rayn/.github/workflows/build-osx.yml b/v2rayn/.github/workflows/build-osx.yml index 61f974c42e..bace6d3ce9 100644 --- a/v2rayn/.github/workflows/build-osx.yml +++ b/v2rayn/.github/workflows/build-osx.yml @@ -32,7 +32,7 @@ jobs: fetch-depth: '0' - name: Setup - uses: actions/setup-dotnet@v5.0.0 + uses: actions/setup-dotnet@v5.0.1 with: dotnet-version: '8.0.x' diff --git a/v2rayn/.github/workflows/build-windows-desktop.yml b/v2rayn/.github/workflows/build-windows-desktop.yml index aa7d0c116c..cc0a644bfc 100644 --- a/v2rayn/.github/workflows/build-windows-desktop.yml +++ b/v2rayn/.github/workflows/build-windows-desktop.yml @@ -32,7 +32,7 @@ jobs: fetch-depth: '0' - name: Setup - uses: actions/setup-dotnet@v5.0.0 + uses: actions/setup-dotnet@v5.0.1 with: dotnet-version: '8.0.x' diff --git a/v2rayn/.github/workflows/build-windows.yml b/v2rayn/.github/workflows/build-windows.yml index e779e12cdb..22f8c8b3a5 100644 --- a/v2rayn/.github/workflows/build-windows.yml +++ b/v2rayn/.github/workflows/build-windows.yml @@ -30,7 +30,7 @@ jobs: uses: actions/checkout@v6.0.0 - name: Setup - uses: actions/setup-dotnet@v5.0.0 + uses: actions/setup-dotnet@v5.0.1 with: dotnet-version: '8.0.x' diff --git a/v2rayn/v2rayN/ServiceLib/Handler/Fmt/BaseFmt.cs b/v2rayn/v2rayN/ServiceLib/Handler/Fmt/BaseFmt.cs index ffcd15c5ac..3665afdf3d 100644 --- a/v2rayn/v2rayN/ServiceLib/Handler/Fmt/BaseFmt.cs +++ b/v2rayn/v2rayN/ServiceLib/Handler/Fmt/BaseFmt.cs @@ -118,22 +118,15 @@ public class BaseFmt } if (item.Extra.IsNotEmpty()) { - var extra = item.Extra; - try - { - var node = JsonNode.Parse(item.Extra); - if (node != null) + var node = JsonUtils.ParseJson(item.Extra); + var extra = node != null + ? JsonUtils.Serialize(node, new JsonSerializerOptions { - extra = node.ToJsonString(new JsonSerializerOptions - { - WriteIndented = false, - Encoder = JavaScriptEncoder.UnsafeRelaxedJsonEscaping - }); - } - } - catch - { - } + WriteIndented = false, + DefaultIgnoreCondition = JsonIgnoreCondition.Never, + Encoder = JavaScriptEncoder.UnsafeRelaxedJsonEscaping + }) + : item.Extra; dicQuery.Add("extra", Utils.UrlEncode(extra)); } break; @@ -253,7 +246,21 @@ public class BaseFmt item.RequestHost = GetQueryDecoded(query, "host"); item.Path = GetQueryDecoded(query, "path", "/"); item.HeaderType = GetQueryDecoded(query, "mode"); - item.Extra = GetQueryDecoded(query, "extra"); + var extraDecoded = GetQueryDecoded(query, "extra"); + if (extraDecoded.IsNotEmpty()) + { + var node = JsonUtils.ParseJson(extraDecoded); + if (node != null) + { + extraDecoded = JsonUtils.Serialize(node, new JsonSerializerOptions + { + WriteIndented = true, + DefaultIgnoreCondition = JsonIgnoreCondition.Never, + Encoder = JavaScriptEncoder.UnsafeRelaxedJsonEscaping + }); + } + } + item.Extra = extraDecoded; break; case nameof(ETransport.http): diff --git a/v2rayn/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs b/v2rayn/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs index 80461288fa..0bbdb208fd 100644 --- a/v2rayn/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs +++ b/v2rayn/v2rayN/ServiceLib/ViewModels/ProfilesViewModel.cs @@ -77,6 +77,7 @@ public class ProfilesViewModel : MyReactiveObject public ReactiveCommand AddSubCmd { get; } public ReactiveCommand EditSubCmd { get; } + public ReactiveCommand DeleteSubCmd { get; } #endregion Menu @@ -235,6 +236,10 @@ public class ProfilesViewModel : MyReactiveObject { await EditSubAsync(false); }); + DeleteSubCmd = ReactiveCommand.CreateFromTask(async () => + { + await DeleteSubAsync(); + }); #endregion WhenAnyValue && ReactiveCommand @@ -884,5 +889,23 @@ public class ProfilesViewModel : MyReactiveObject } } + private async Task DeleteSubAsync() + { + var item = await AppManager.Instance.GetSubItem(_config.SubIndexId); + if (item is null) + { + return; + } + + if (await _updateView?.Invoke(EViewAction.ShowYesNo, null) == false) + { + return; + } + await ConfigHandler.DeleteSubItem(_config, item.Id); + + await RefreshSubscriptions(); + await SubSelectedChangedAsync(true); + } + #endregion Subscription } diff --git a/v2rayn/v2rayN/v2rayN.Desktop/Views/ProfilesView.axaml b/v2rayn/v2rayN/v2rayN.Desktop/Views/ProfilesView.axaml index c84a71510f..dc5f2e86ba 100644 --- a/v2rayn/v2rayN/v2rayN.Desktop/Views/ProfilesView.axaml +++ b/v2rayn/v2rayN/v2rayN.Desktop/Views/ProfilesView.axaml @@ -28,6 +28,14 @@ + + + + + + + +