ssh behind a firewall

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

 



Hello all,
I have a firewall running iptables and connected to the internet with ISDN
and
it has static ip.
Behind the firewall i have a samba server which also has ssh server.
I want people from internet to connect with ssh and use the sftp-server in
order
to put/get files to that server.
So i said i will use these rules

$IPT -t nat -A PREROUTING -i $EXT_IFACE -p tcp -s ! $LAN_IP_RANGE --dport
2222 -j DNAT --to-destination $SSH_SERVER
$IPT -A internet-lan -p tcp -d $SSH_SERVER --dport 2222 -m state --state
NEW,ESTABLISHED -j ACCEPT
$IPT -A lan-internet -p tcp -s $SSH_SERVER --sport 2222 -m state --state
ESTABLISHED -j ACCEPT

I did n't try it so i would like to know
if is it possible this scenario to work?

Yours,
PAvlos


~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I love having the feeling of being in control
while i have the sensation of speed

The surfer of life
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~




[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux