ALT Linux Community general discussions
 help / color / mirror / Atom feed
* [Comm] iptables ?
@ 2005-07-28 18:41 Санек Самойлов
  2005-07-29  6:03 ` Olvin
  0 siblings, 1 reply; 2+ messages in thread
From: Санек Самойлов @ 2005-07-28 18:41 UTC (permalink / raw)
  To: Community

Добрый Вечер Всем !

Вот я умею,  ssh -gL 25:192.168.100.1:25 127.0.0.1    - перебросил 25 
порт с хоста 192.168.100.1

Как такое сделать в iptables ?
Если не iptables  то где это лучше сделать ?

=======================================
С уважением Александр Самойлов
icq: 315644


^ permalink raw reply	[flat|nested] 2+ messages in thread

* Re: [Comm] iptables ?
  2005-07-28 18:41 [Comm] iptables ? Санек Самойлов
@ 2005-07-29  6:03 ` Olvin
  0 siblings, 0 replies; 2+ messages in thread
From: Olvin @ 2005-07-29  6:03 UTC (permalink / raw)
  To: community

Санек Самойлов wrote:
> Вот я умею,  ssh -gL 25:192.168.100.1:25 127.0.0.1    - перебросил 25 
> порт с хоста 192.168.100.1
> Как такое сделать в iptables ?
> Если не iptables  то где это лучше сделать ?

iptables -t nat -A PREROUTING -p tcp --dport $P1 -d $IP1 -s $IP0 -j DNAT 
--to-destination $IP2:$P2

iptables -t nat -A POSTROUTING -p tcp --dport $P2 -d $IP2 -s $IP0 -j 
SNAT --to-source $IP3

iptables -t filter -A FORWARD -p tcp -s $IP0 -d $IP2 -s $IP3 --dport $P2 
-j ACCEPT

За дальнейшей справкой - man iptables


^ permalink raw reply	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2005-07-29  6:03 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2005-07-28 18:41 [Comm] iptables ? Санек Самойлов
2005-07-29  6:03 ` Olvin

ALT Linux Community general discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror http://lore.altlinux.org/community/0 community/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 community community/ http://lore.altlinux.org/community \
		mandrake-russian@linuxteam.iplabs.ru community@lists.altlinux.org community@lists.altlinux.ru community@lists.altlinux.com
	public-inbox-index community

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://lore.altlinux.org/org.altlinux.lists.community


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git