mirror of
https://github.com/therealaleph/MasterHttpRelayVPN-RUST.git
synced 2026-05-18 05:36:56 +03:00
v1.2.1: IP-literal fast-fail + more SNIs + x.com GraphQL fix + Android SNI paste
Rollup of the three upstream-Python ports plus an Android UX polish: - plain_tcp_passthrough: 4s connect timeout for IP literals (10s for hostnames). Halves Telegram DC-rotation latency when the current DC is DPI-dropped. - DEFAULT_GOOGLE_SNI_POOL / DEFAULT_SNI_POOL: +maps, chat, translate, play, lens.google.com. More fingerprint spread, and maps/play pass DPI on some carriers where shorter *.google.com names don't. - handle_mitm_request: x.com GraphQL URL truncation — strip everything after the first & when the path matches /i/api/graphql/.../?variables=. x.com's variables+features+fieldToggles blob overflows Apps Script's URL cap; `variables=` alone renders the timeline. - Android SNI editor: paste-and-add now accepts a full list separated by whitespace / commas / newlines, dedupes, and merges with existing selection. Closes the "add them all at once" ask from #47. - rlimit.rs: fence the example error log in a `text` code block so rustdoc stops trying to compile it.
This commit is contained in:
Generated
+1
-1
@@ -2186,7 +2186,7 @@ dependencies = [
|
||||
|
||||
[[package]]
|
||||
name = "mhrv-rs"
|
||||
version = "1.2.0"
|
||||
version = "1.2.1"
|
||||
dependencies = [
|
||||
"base64 0.22.1",
|
||||
"bytes",
|
||||
|
||||
+1
-1
@@ -1,6 +1,6 @@
|
||||
[package]
|
||||
name = "mhrv-rs"
|
||||
version = "1.2.0"
|
||||
version = "1.2.1"
|
||||
edition = "2021"
|
||||
description = "Rust port of MasterHttpRelayVPN -- DPI bypass via Google Apps Script relay with domain fronting"
|
||||
license = "MIT"
|
||||
|
||||
@@ -14,8 +14,8 @@ android {
|
||||
applicationId = "com.therealaleph.mhrv"
|
||||
minSdk = 24 // Android 7.0 — covers 99%+ of live devices.
|
||||
targetSdk = 34
|
||||
versionCode = 120
|
||||
versionName = "1.2.0"
|
||||
versionCode = 121
|
||||
versionName = "1.2.1"
|
||||
|
||||
// Ship all four mainstream Android ABIs:
|
||||
// - arm64-v8a — 95%+ of real-world Android phones since 2019
|
||||
|
||||
@@ -851,16 +851,30 @@ private fun SniPoolEditor(
|
||||
value = custom,
|
||||
onValueChange = { custom = it },
|
||||
label = { Text(stringResource(R.string.field_add_custom_sni)) },
|
||||
singleLine = true,
|
||||
// Accept a pasted list — users (issue #47) want to dump a
|
||||
// whole list of subdomains in one go. We split on newlines,
|
||||
// commas, semicolons, and whitespace so formats like
|
||||
// www.google.com\nmail.google.com\ndrive.google.com
|
||||
// www.google.com, mail.google.com
|
||||
// www.google.com mail.google.com
|
||||
// all do the right thing on Add.
|
||||
singleLine = false,
|
||||
maxLines = 6,
|
||||
keyboardOptions = KeyboardOptions(keyboardType = KeyboardType.Uri),
|
||||
modifier = Modifier.weight(1f),
|
||||
)
|
||||
TextButton(
|
||||
onClick = {
|
||||
val s = custom.trim()
|
||||
if (s.isNotEmpty()) {
|
||||
val next = (cfg.sniHosts.takeIf { it.isNotEmpty() } ?: enabledSet.toList()) + s
|
||||
onChange(cfg.copy(sniHosts = next.distinct()))
|
||||
// Tokenise on any whitespace, comma, or semicolon so one
|
||||
// Add click absorbs a pasted list. Deduplicate within
|
||||
// the paste before merging into the existing list.
|
||||
val tokens = custom.split(Regex("[\\s,;]+"))
|
||||
.map { it.trim() }
|
||||
.filter { it.isNotEmpty() }
|
||||
if (tokens.isNotEmpty()) {
|
||||
val base = cfg.sniHosts.takeIf { it.isNotEmpty() } ?: enabledSet.toList()
|
||||
val next = (base + tokens).distinct()
|
||||
onChange(cfg.copy(sniHosts = next))
|
||||
custom = ""
|
||||
}
|
||||
},
|
||||
|
||||
@@ -0,0 +1,12 @@
|
||||
<!-- see docs/changelog/v1.1.0.md for the file format: Persian, then `---`, then English. -->
|
||||
• تایماوت تند برای IP literalها (مثلاً DC تلگرام) — ۴ ثانیه بهجای ۱۰ ثانیه. وقتی DC مسدود است، تلگرام دو برابر سریعتر به DC بعدی میچرخد (پورت از upstream پایتون)
|
||||
• افزودن maps / chat / translate / play / lens و scholar.google.com به مجموعهٔ چرخشی SNI — spread بیشتر، و چند مورد از اینها روی اپراتورهایی که *.google.com کوتاه را میبندند DPI را رد میکنند (issue #47)
|
||||
• اصلاح بارگذاری x.com: کوتاه کردن URLهای طولانی GraphQL که از سقف طول URL در Apps Script رد میشدند و باعث relay error میشد (پورت از upstream پایتون)
|
||||
• ویرایشگر SNI اندروید: میتوانید یک لیست کامل از subdomainها را Paste کنید و با یک بار Add همه اضافه میشوند (issue #47)
|
||||
• اصلاح متن FAQ فارسی README: سهمیهٔ روزانهٔ UrlFetchApp ۲۰٬۰۰۰ درخواست است (نه ۲ میلیون) — ارجاع به مستند رسمی گوگل (issue #63)
|
||||
---
|
||||
• Fast-fail connect timeout for IP literals (e.g. Telegram DCs) — 4s instead of 10s. When a DC is blocked, clients like Telegram rotate to the next DC roughly twice as fast (ported from upstream Python)
|
||||
• Add maps / chat / translate / play / lens and scholar.google.com to the SNI rotation pool — more DPI-fingerprint spread, and a few of these reliably pass DPI on carriers where shorter *.google.com names don't (issue #47)
|
||||
• x.com loading fix: truncate long GraphQL URLs that were overflowing Apps Script's URL length cap and bouncing with a generic relay error (ported from upstream Python)
|
||||
• Android SNI editor: paste a whole list of subdomains once and Add picks them all up — whitespace, comma, and newline separated all work (issue #47)
|
||||
• Persian FAQ in README: UrlFetchApp quota corrected to 20,000/day (not 2 million), with reference to Google's official docs (issue #63)
|
||||
+3
-1
@@ -7,7 +7,9 @@
|
||||
//! SOCKS5 flood from a client like v2ray, fills the limit within seconds.
|
||||
//! Once the limit is hit `accept(2)` returns `EMFILE` and the user sees:
|
||||
//!
|
||||
//! ERROR accept (socks): No file descriptors available (os error 24)
|
||||
//! ```text
|
||||
//! ERROR accept (socks): No file descriptors available (os error 24)
|
||||
//! ```
|
||||
//!
|
||||
//! Approach:
|
||||
//! - Try to raise the SOFT limit to a generous target.
|
||||
|
||||
Reference in New Issue
Block a user