Is it possible to change the PASV IP ftp-proxy of OpenBSD sends to clients, without changing the listen address of redirection control (-b <address>)?

I have the following setup:

FTP client --> 1:1 NAT router --> OpenBSD router --> FTP server

The 1:1 NAT router has a NAT rule to forward everything to the OpenBSD router, the OpenBSD router runs the ftp-proxy -R <FTP server IP>. When the FTP client sends the PASV command, the proxy answers with the Entering Passive Mode (227) message with his own source IP on the interface to the 1:1 NAT router (obviously). Since the 1:1 NAT router is not protocol aware, it forwards this message and the client receives the message with the PASV IP of the OpenBSD router, which it does not have a route to.

Is there a way, that I can tell ftp-proxy to send the Entering Passive Mode message with a different source IP?


man ftp-proxy

-a address
    The proxy will use this as the source address for the control
    connection to a server.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.