mirror of
https://github.com/ScuroNeko/mtg.git
synced 2026-08-31 11:44:02 +03:00
Add HTTP timeout
This commit is contained in:
@@ -34,6 +34,7 @@ type Config struct {
|
||||
} `json:"public-ip"`
|
||||
Timeout struct {
|
||||
TCP TypeDuration `json:"tcp"`
|
||||
HTTP TypeDuration `json:"http"`
|
||||
Idle TypeDuration `json:"idle"`
|
||||
} `json:"timeout"`
|
||||
DOHIP TypeIP `json:"doh-ip"`
|
||||
@@ -103,6 +104,7 @@ type configRaw struct {
|
||||
} `toml:"public-ip" json:"public-ip,omitempty"`
|
||||
Timeout struct {
|
||||
TCP string `toml:"tcp" json:"tcp,omitempty"`
|
||||
HTTP string `toml:"http" json:"http,omitempty"`
|
||||
Idle string `toml:"idle" json:"idle,omitempty"`
|
||||
} `toml:"timeout" json:"timeout,omitempty"`
|
||||
DOHIP string `toml:"doh-ip" json:"doh-ip,omitempty"`
|
||||
|
||||
@@ -111,6 +111,7 @@ ipv6 = ""
|
||||
# https://www.ndss-symposium.org/wp-content/uploads/2020/02/23087-paper.pdf
|
||||
[network.timeout]
|
||||
tcp = "5s"
|
||||
http = "10s"
|
||||
idle = "1m"
|
||||
|
||||
# FakeTLS can compare timestamps to prevent probes. Each message has
|
||||
|
||||
Reference in New Issue
Block a user