we talked to our admin about the firewall issues. Below is his response … hopefully it clarifies the situation:
Our firewall does not do NAT, and the policies are strictly configured to only allow traffic that we explicitly approved. Here’s what the current firewall rules allow:
Inbound
- Only to TCP or UDP destination port 4001
Outbound
- Only to TCP or UDP destination port 4001
- Only from source port 4001 (TCP or UDP)
Everything else is blocked, including any traffic from or to non-allowed ports.
Importantly
- The firewall itself is carrier-grade. Performance, session tables, etc., are not an issue.
- Logging, however, is an issue. All blocked packets (inbound and outbound) are logged.
- Our IPFS node generates a huge amount of blocked events — often millions per day, accounting for 80–90% of all logged events, making log analysis painfully slow.
This high volume of blocked packets strongly suggests that IPFS is not limiting its connections to port 4001, despite our policies.
While TCP source port binding to 4001 may be unrealistic, especially for outgoing connections, UDP is definitely behaving unexpectedly as well — we see outbound UDP traffic using random source ports, which violates our policies.
Summary
The actual issue isn’t firewall performance or DHT per se — the problem is that IPFS is not consistently using the ports it’s supposed to.
Given that, we’d be very interested in a way to force Kubo/IPFS to use only port 4001 for all incoming and outgoing traffic, both source and destination, for both TCP and UDP — or otherwise restrict its behavior to match the firewall rules.