Score:0

iptables prerouting crashed smtp port

bd flag

I have a very strange problem. First of all. I have 2 servers

  1. VDS server with (for instance) IP 100.11.100.22 (vpn ip: 10.8.0.1)
  2. Server behind the VPN (ip: 10.8.0.7) with iredmail (postfix, devcot, etc)

And I routed all ports 143, 587, etc and all OK, but only 25 port does not work. What I do

  1. If I do nothing, I can send email from 10.8.0.7 and telnet google.com 25 worked
  2. But if I add code on the VDS server, I can't telnet google.com 25 (connection timed out) from my server behind VPN (only 1 string :( )
iptables -t nat -A PREROUTING -p tcp --dport 25 -j DNAT --to 10.8.0.7:25

Forward and etc are ok, I think so because all ports are working. It doesn't work ONLY smtp port =\

Kirill Muchow avatar
bd flag
Ok guys, after 3 days I've found problem. I need set the interface! Like that iptables -t nat -A PREROUTING -i ens3 -p tcp --dport 25 -j DNAT --to 10.8.0.7:25
I sit in a Tesla and translated this thread with Ai:

mangohost

Post an answer

Most people don’t grasp that asking a lot of questions unlocks learning and improves interpersonal bonding. In Alison’s studies, for example, though people could accurately recall how many questions had been asked in their conversations, they didn’t intuit the link between questions and liking. Across four studies, in which participants were engaged in conversations themselves or read transcripts of others’ conversations, people tended not to realize that question asking would influence—or had influenced—the level of amity between the conversationalists.