Stalwart, the up and coming new open source email server, fails the connection tests on internet.nl unless you take measures. This is because internet.nl makes many concurrent connections, and Stalwart will immediately block the IP. Here are some tips on making the tests pass.
In short:
- Make Stalwart see external IP addresses
- Allow IP addresses of internet.nl
- Disable rate limiting for internet.nl
Make Stalwart see external IP addresses
If Stalwart is behind some network bridge, for example a docker network bridge, it will not see the actual remote IP addresses. You can tell when the log files only contain references to IP addresses in the private IP ranges. When Stalwart is running in a container, the easiest solution is to switch network mode to "host". For example by including this network_mode line in the docker-compose file:
services:
stalwart:
image: docker.io/stalwartlabs/stalwart:$STALWART_VERSION
container_name: stalwart
network_mode: "host"
...Allow IP addresses of internet.nl
In the Stalwart admin go to Settings → Security → Allowed IPs.
Then click + Create address and enter:
IP Addresses: 62.204.66.0/26
Reason: Internet.nl tests
Create at: some date
and click Create.
Then repeat for the IPv6 address; click + Create address and enter:
IP Addresses: 2a00:d00:ff:162::/64
Reason: Internet.nl tests
Create at: some date
and click Create.
If you already tried the tests you may need to clear the list of blocked IPs.
Disable rate limiting for internet.nl
In the Stalwart admin go to Settings → MTA → Inbound Rate Limits → Sender IP throttle.
Then under Match condition click + Add Condition.
Enter the following value for IF:
is_ip_in_cidr(remote_ip, '62.204.66.0/26') ||
is_ip_in_cidr(remote_ip, '2a00:d00:ff:162::/64')and for THEN: false
and press Save.
Alternatively, you can change the rate limit (same page) from 5 to 20 per second.
Activate settings
Finally, go to Management → Actions → Server Settings, and click `Execute`.
That's it! The tests should now pass.








