Skip to content
This repository has been archived by the owner on Sep 10, 2024. It is now read-only.

fix class-b RFC1918 network #2908

Merged
merged 4 commits into from
Jul 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion crates/config/src/sections/http.rs
Original file line number Diff line number Diff line change
Expand Up @@ -65,7 +65,7 @@ fn is_default_http_listener_assets_path(value: &Utf8PathBuf) -> bool {

fn default_trusted_proxies() -> Vec<IpNetwork> {
vec![
IpNetwork::new([192, 128, 0, 0].into(), 16).unwrap(),
IpNetwork::new([192, 168, 0, 0].into(), 16).unwrap(),
IpNetwork::new([172, 16, 0, 0].into(), 12).unwrap(),
IpNetwork::new([10, 0, 0, 0].into(), 10).unwrap(),
IpNetwork::new(std::net::Ipv4Addr::LOCALHOST.into(), 8).unwrap(),
Expand Down
4 changes: 2 additions & 2 deletions docs/config.schema.json
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@
}
],
"trusted_proxies": [
"192.128.0.0/16",
"192.168.0.0/16",
"172.16.0.0/12",
"10.0.0.0/10",
"127.0.0.1/8",
Expand Down Expand Up @@ -586,7 +586,7 @@
"trusted_proxies": {
"description": "List of trusted reverse proxies that can set the `X-Forwarded-For` header",
"default": [
"192.128.0.0/16",
"192.168.0.0/16",
"172.16.0.0/12",
"10.0.0.0/10",
"127.0.0.1/8",
Expand Down
Loading