Re: [OT] General port forwarding/ssh question

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 




On Fri, 19 Nov 2004, P Jones wrote:

> OK, this is what I do now, followed by what I would like to do; I
> forward ports 80, 25, and 119 on my local server to a remote proxy (a
> machine in another part of the country) using ssh. The setup in my
> client is to send email to localhost, where it is forwarded by ssh to
> the remote proxy. The problem is that in order for this to work I have
> to disable sendmail, which means I don't get any logwatch reports in my
> root mail. Not sure if what I'm doing makes an sense, it just happens to
> work and so it's what I do.
> 
> What I'd like is to be able to have both sendmail and my ssh port
> forwarding work. I haven't the foggiest idea how to do it. Could I get
> sendmail to route mail destined for outside the local network to port 25
> which is then forwarded to the proxy, and route local mail to the local
> address? Any ideas?

I'll indicate in postfix terms - it should be similar for sendmail.

Instead of doing ssh -L25:remote:25 - do something like -L1025:remote:25

i.e local port 1025 is now the SMTP-forward port. With this - you can
run sendmail/postfix on normal port:25

With postfix - you can say:
postconf -e relayhost=localhost:1025

i.e pine -> postfix:25 -> localhost:1025 -> remote-host (via ssh)

Logwatch mail will be delivered to /var/spool/mail/root the
localmachine (uless you modify /etc/aliases in FC3)

Satish


[Index of Archives]     [Current Fedora Users]     [Fedora Desktop]     [Fedora SELinux]     [Yosemite News]     [Yosemite Photos]     [KDE Users]     [Fedora Tools]     [Fedora Docs]

  Powered by Linux