mirror of
https://github.com/telemt/telemt.git
synced 2026-09-05 18:16:06 +03:00
fix(synlimit): raise default synlimit_burst from 1 to 24
The generic-path SYN limiter default of burst=1 admits only one new connection per source IP, then refills at 48/minute (0.8/s). Telegram clients open several connections at once on startup/reconnect, so the extra SYNs are rejected with TCP RST until a token accrues — clients intermittently fail to connect until the app is restarted. The iOS fast-path (meta length 64) does not match real-world traffic behind carrier NAT/NAT64 (SYNs arrive as 60 bytes), so the generic path governs all clients, iPhone included. Raise its default burst to 24 — the value already used by the iOS path — so a legitimate startup fan-out passes. Steady-state rate (48/minute) is unchanged, preserving the anti-TSPU posture. Updates the default constant, the default-assertion test, and the EN/RU/DE CONFIG_PARAMS docs.
This commit is contained in:
@@ -2240,7 +2240,7 @@
|
||||
| [`synlimit`](#synlimit-serverlisteners) | `false`, `"iptables"` или `"nftables"` | `false` | `✔` |
|
||||
| [`synlimit_seconds`](#synlimit_seconds-serverlisteners) | `u32` | `60` | `✔` |
|
||||
| [`synlimit_hitcount`](#synlimit_hitcount-serverlisteners) | `u32` | `48` | `✔` |
|
||||
| [`synlimit_burst`](#synlimit_burst-serverlisteners) | `u32` | `1` | `✔` |
|
||||
| [`synlimit_burst`](#synlimit_burst-serverlisteners) | `u32` | `24` | `✔` |
|
||||
| [`synlimit_ios_seconds`](#synlimit_ios_seconds-serverlisteners) | `u32` | `1` | `✔` |
|
||||
| [`synlimit_ios_hitcount`](#synlimit_ios_hitcount-serverlisteners) | `u32` | `12` | `✔` |
|
||||
| [`synlimit_ios_burst`](#synlimit_ios_burst-serverlisteners) | `u32` | `24` | `✔` |
|
||||
@@ -2323,7 +2323,7 @@
|
||||
synlimit_hitcount = 48
|
||||
```
|
||||
## synlimit_burst (server.listeners)
|
||||
- **Ограничения / валидация**: `u32`, должно быть `> 0`. Значение по умолчанию: `1`.
|
||||
- **Ограничения / валидация**: `u32`, должно быть `> 0`. Значение по умолчанию: `24`.
|
||||
- **Описание**: Generic SYN-fix token-bucket burst size. Более высокие значения разрешают short connection bursts с одного source IP перед применением steady-state rate `synlimit_hitcount / synlimit_seconds`.
|
||||
- **Пример**:
|
||||
|
||||
@@ -2332,7 +2332,7 @@
|
||||
ip = "0.0.0.0"
|
||||
port = 443
|
||||
synlimit = "iptables"
|
||||
synlimit_burst = 1
|
||||
synlimit_burst = 24
|
||||
```
|
||||
## synlimit_ios_seconds (server.listeners)
|
||||
- **Ограничения / валидация**: `u32`, должно быть `> 0`. Значение по умолчанию: `1`.
|
||||
|
||||
Reference in New Issue
Block a user