Skip to content

Commit

Permalink
Remove automatic ignore of incoming/outgoing traffic for ports 50000-…
Browse files Browse the repository at this point in the history
…60000
  • Loading branch information
aviramha committed Jul 14, 2024
1 parent 6d59418 commit b8885b0
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
1 change: 1 addition & 0 deletions changelog.d/2597.fixed.md
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
Remove automatic ignore of incoming/outgoing traffic for ports 50000-60000
4 changes: 1 addition & 3 deletions mirrord/layer/src/socket.rs
Original file line number Diff line number Diff line change
Expand Up @@ -433,9 +433,7 @@ impl OutgoingFilterExt for OutgoingFilter {

#[inline]
fn is_ignored_port(addr: &SocketAddr) -> bool {
let (ip, port) = (addr.ip(), addr.port());
let ignored_ip = ip == IpAddr::V4(Ipv4Addr::LOCALHOST) || ip == IpAddr::V6(Ipv6Addr::LOCALHOST);
port == 0 || ignored_ip && (port > 50000 && port < 60000)
addr.port() == 0
}

/// Fill in the sockaddr structure for the given address.
Expand Down

0 comments on commit b8885b0

Please sign in to comment.