mirror of
https://github.com/MHSanaei/3x-ui.git
synced 2026-11-14 00:55:01 +03:00
feat(sub): add Incy app-management parameters (#6650)
* feat(sub): add Incy app-management parameters The panel already pushes a set of Happ headers, but INCY documents its own lowercase header names and its own value domains, so a Happ-shaped payload gets ignored by the client (per-app mode is bypass|proxy, not on|bypass, and per-app-proxy-enable has no Happ counterpart at all). Add a sibling Incy path that emits exactly the documented headers. Covered, per https://docs.incy.cc/en/app-management/: - profile-description, sort-order, support-email, announce-url, premium-url - banner text/button/URL and the two hex colours - hide-url, hide-check, no-limit-enabled - per-app split tunnelling (enable/mode/list) - TCP fragmentation (enable/length/interval/packets) - UDP noise packets (enable/type/packet/delay) - DoH pre-resolution (enable/domain/IP) Each string setting is tri-state: an empty value omits the header, so an untouched panel never overrides the subscriber's own choice in the app. Values are validated against the documented domains and dropped when they do not match, and non-ASCII text is base64-wrapped the way the docs require for Cyrillic. INCY identifies itself as INCY/<version>/<platform>, which gates the headers behind the same auto-detect switch the Happ path uses. Headers the panel already emits for every client (Profile-Title, Support-Url, Profile-Web-Page-Url, Announce, Profile-Update-Interval, Subscription-Userinfo) and Incy's routing line are left as they are. The Premium API (theme, defaultPingProtocol, fallbackHosts, ...) is a separate encrypted endpoint and stays out of scope here. * fix(sub): keep Incy per-app list entries separate on the wire The Incy settings textarea takes one package per line, as Incy documents for per-app-proxy-list, but the header path ran the value through sanitizeHeaderValue, which deletes CR/LF. "com.google.chrome\norg.telegram.messenger" reached the client as the single bogus package "com.google.chromeorg.telegram.messenger", so per-app split tunnelling silently matched no app. Join comma- or line-separated entries as CSV instead. Also drop three tests that could not fail: TestIncyExcludesHappOnlyHeaders (ApplyIncyHeaders has no path that emits Happ headers, and the non-Happ UA gate is already pinned by TestApplyHappHeaders_Gating) and two UI tests that only asserted updateSetting received the key the JSX passes it. --------- Co-authored-by: DIMFLIX <dimflix@users.noreply.github.com> Co-authored-by: MHSanaei <ho3ein.sanaei@gmail.com>
This commit is contained in:
@@ -1670,7 +1670,76 @@
|
||||
"discordNotifyTimeDesc": "هر چند وقت یکبار ربات دیسکورد گزارش دورهای بفرستد. یک بازهٔ آماده انتخاب کنید یا گزینهٔ سفارشی را بزنید تا عبارت crontab وارد کنید.",
|
||||
"discordNotifyBackup": "پشتیبانگیری از دیتابیس",
|
||||
"discordNotifyBackupDesc": "فایل پشتیباندیتابیس را بههمراه گزارش ارسال میکند",
|
||||
"discordEventBusNotifyDesc": "انتخاب کنید کدام رویدادها اعلان دیسکورد را فعال میکنند"
|
||||
"discordEventBusNotifyDesc": "انتخاب کنید کدام رویدادها اعلان دیسکورد را فعال میکنند",
|
||||
"subIncyAppAutoDetect": "تشخیص خودکار هدرهای Incy",
|
||||
"subIncyAppAutoDetectDesc": "ارسال هدرهای Incy وقتی User-Agent کلاینت INCY باشد.",
|
||||
"subIncyNotSet": "تنظیم نشده",
|
||||
"subIncyOn": "روشن",
|
||||
"subIncyOff": "خاموش",
|
||||
"subIncyGroupApp": "برنامه",
|
||||
"subIncyProfileDescription": "توضیح پروفایل",
|
||||
"subIncyProfileDescriptionDesc": "توضیح جداگانه اشتراک. متن غیر-ASCII بهصورت base64 ارسال میشود.",
|
||||
"subIncySortOrder": "ترتیب سرورها",
|
||||
"subIncySortOrderDesc": "برای همین اشتراک در iOS/Android و بهصورت کلی در دسکتاپ.",
|
||||
"subIncySortNone": "بر اساس ترتیب اشتراک",
|
||||
"subIncySortPing": "بر اساس پینگ",
|
||||
"subIncySortName": "بر اساس نام",
|
||||
"subIncySupportEmail": "ایمیل پشتیبانی",
|
||||
"subIncySupportEmailDesc": "دکمه Email را به کارت اشتراک اضافه میکند.",
|
||||
"subIncyAnnounceUrl": "لینک اعلان",
|
||||
"subIncyAnnounceUrlDesc": "مقصد لینک اعلان در صفحه اصلی.",
|
||||
"subIncyPremiumUrl": "لینک Premium",
|
||||
"subIncyPremiumUrlDesc": "دکمه Premium در کارت؛ برای دکمه بنر هم اولویت دارد.",
|
||||
"subIncyGroupBanners": "بنرها",
|
||||
"subIncyBannerText": "متن بنر",
|
||||
"subIncyBannerTextDesc": "متن بنر را بازنویسی میکند. فقط برای ارائهدهندگان premium.",
|
||||
"subIncyBannerButtonText": "متن دکمه بنر",
|
||||
"subIncyBannerButtonTextDesc": "برچسب دکمه بنر. خالی بودن یعنی دکمه نمایش داده نشود.",
|
||||
"subIncyBannerButtonUrl": "لینک دکمه بنر",
|
||||
"subIncyBannerButtonUrlDesc": "آدرس دکمه بنر.",
|
||||
"subIncyBannerBgColor": "پسزمینه بنر",
|
||||
"subIncyBannerBgColorDesc": "رنگ hex، مثلاً #E53E3E.",
|
||||
"subIncyBannerButtonColor": "رنگ دکمه بنر",
|
||||
"subIncyBannerButtonColorDesc": "رنگ hex، مثلاً #38A169.",
|
||||
"subIncyGroupPrivacy": "حریم خصوصی",
|
||||
"subIncyHideUrl": "پنهان کردن آدرس اشتراک",
|
||||
"subIncyHideUrlDesc": "آدرس را از اشتراکگذاری، کپی، QR و پشتیبانگیری پنهان میکند.",
|
||||
"subIncyHideCheck": "پنهان کردن دکمه بررسی",
|
||||
"subIncyHideCheckDesc": "دکمه بررسی اتصال را از صفحه اصلی حذف میکند.",
|
||||
"subIncyNoLimit": "حالت No-Limit (iOS)",
|
||||
"subIncyNoLimitDesc": "حالت کممصرف تا تونل زیر سقف ۵۰ مگابایتی iOS بماند.",
|
||||
"subIncyPerAppEnable": "حالت per-app (اندروید)",
|
||||
"subIncyPerAppEnableDesc": "تونل تفکیکی بر اساس برنامه را فعال میکند. خاموش، انتخاب کاربر را بازنویسی میکند.",
|
||||
"subIncyPerAppMode": "نوع حالت per-app",
|
||||
"subIncyPerAppModeDesc": "proxy یعنی فقط برنامههای فهرستشده از VPN بروند، bypass برعکس.",
|
||||
"subIncyPerAppModeProxy": "فقط برنامههای فهرستشده",
|
||||
"subIncyPerAppModeBypass": "برنامههای فهرستشده دور میزنند",
|
||||
"subIncyPerAppList": "فهرست برنامهها",
|
||||
"subIncyPerAppListDesc": "نام بستهها با کاما یا خط جدید، یا آدرس یک فایل متنی.",
|
||||
"subIncyGroupNetwork": "شبکه",
|
||||
"subIncyFragmentationEnable": "تکهتکهسازی",
|
||||
"subIncyFragmentationEnableDesc": "تکهتکهسازی TCP را فعال میکند و تنظیم کلی را بازنویسی میکند.",
|
||||
"subIncyFragmentLength": "طول قطعه",
|
||||
"subIncyFragmentLengthDesc": "بازه به بایت، مثلاً 10-30.",
|
||||
"subIncyFragmentInterval": "فاصله قطعهها",
|
||||
"subIncyFragmentIntervalDesc": "بازه به میلیثانیه، مثلاً 20-40.",
|
||||
"subIncyFragmentPackets": "بستههای قطعه",
|
||||
"subIncyFragmentPacketsDesc": "کدام بستههای TCP تکه شوند: tlshello، 1-3، 1 یا all.",
|
||||
"subIncyNoisesEnable": "بستههای نویز",
|
||||
"subIncyNoisesEnableDesc": "پیش از هندشیک VPN نویز تصادفی UDP میفرستد.",
|
||||
"subIncyNoisesType": "نوع نویز",
|
||||
"subIncyNoisesTypeDesc": "rand، str یا hex.",
|
||||
"subIncyNoisesPacket": "محتوای بسته نویز",
|
||||
"subIncyNoisesPacketDesc": "محتوا؛ در حالت rand یک بازه طول، مثلاً 10-20.",
|
||||
"subIncyNoisesDelay": "تأخیر نویز",
|
||||
"subIncyNoisesDelayDesc": "بازه تأخیر به میلیثانیه، مثلاً 10-50.",
|
||||
"subIncyResolveEnable": "حل آدرس سرور (DoH)",
|
||||
"subIncyResolveEnableDesc": "آدرس سرور را پیش از اتصال با DoH حل میکند.",
|
||||
"subIncyResolveDnsDomain": "نقطه پایانی DoH",
|
||||
"subIncyResolveDnsDomainDesc": "آدرس سرور DoH، معمولاً به /dns-query ختم میشود.",
|
||||
"subIncyResolveDnsIp": "آیپی سرور DoH",
|
||||
"subIncyResolveDnsIpDesc": "آیپی سرور DoH برای بوتاسترپ.",
|
||||
"subIncyGroupRouting": "مسیریابی"
|
||||
},
|
||||
"xray": {
|
||||
"save": "ذخیره",
|
||||
|
||||
Reference in New Issue
Block a user