mirror of
https://github.com/superseriousbusiness/gotosocial.git
synced 2025-10-30 03:32:25 -05:00
[feature] enable + document explicit IP dialer allowing/denying (#1950)
* [feature] enable + document explicit IP dialer allowing/denying * lord have mercy * allee jonge * shortcut check ipv6 prefixes * comment * separate httpclient_test, export Sanitizer
This commit is contained in:
parent
ac564c1862
commit
2a99df0588
17 changed files with 554 additions and 200 deletions
|
|
@ -130,9 +130,9 @@ func New(cfg Config) *Client {
|
|||
}
|
||||
|
||||
// Protect dialer with IP range sanitizer.
|
||||
d.Control = (&sanitizer{
|
||||
allow: cfg.AllowRanges,
|
||||
block: cfg.BlockRanges,
|
||||
d.Control = (&Sanitizer{
|
||||
Allow: cfg.AllowRanges,
|
||||
Block: cfg.BlockRanges,
|
||||
}).Sanitize
|
||||
|
||||
// Prepare client fields.
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue