ALT Linux Community general discussions
 help / color / mirror / Atom feed
From: Andrey Rybak <ra@iop.kiev.ua>
To: ALT Linux Community <community@lists.altlinux.org>
Subject: Re: [Comm] iptables rules?
Date: Fri, 31 Mar 2006 13:31:21 +0300
Message-ID: <442D04F9.10106@iop.kiev.ua> (raw)
In-Reply-To: <bf3ff7bc0603302332g6b6824f2j83cb58f80c6a3152@mail.gmail.com>

Kaydannik Axel пишет:
> Вывод.
> Сделать что бы именно с этой машины порты ни на какой сквид не форвардились
>
> На будущее: мог бы и представить правила настроек файрвола, сквида и
> примерную топологию, а то - ей богу...
>
>   
Предоставлял, но почему-то не дошло. Наверное рисунок схемы в аттачменте 
размером больше допустимого. Попробую псевдографикой.
Правда, вижу, я в ней не силен. Посмотрю, как в рассылке будет. Надеюсь 
переделывать не надо будет.

Схема в атачменте

На шлюзе (1.1.1.1)
в фаерволле
iptables -t nat -A PREROUTING -p TCP -d 3.3.3.3 --dport 80 -j DNAT 
--to-destination 10.10.10.10:80
iptables -A FORWARD -p TCP -d 10.10.10.10/32 --dport 80 -j ACCEPT
iptables -A FORWARD -p TCP -s 10.10.10.1/32 --sport 80 -j ACCEPT

На сервере (серые адреса не за натом), через который проброс делается и 
на котором прозрачный сквид (2.2.2.2)
в фаерволле
iptables -t nat -p TCP -A PREROUTING -s 0/0 -d 10.10.10.10/32 --dport 80 
-j ACCEPT
iptables -p TCP -A INPUT -d 10.10.10.10/32 --dport 80 -j ACCEPT
iptables -p TCP -A OUTPUT -d 10.10.10.10/32 --dport 80 -j ACCEPT

в конфигурации сквида
acl myacl dst 10.10.10.10/32
http_access  allow myacl




мир
|
---------------------------------------
шлюз
iptables
1.1.1.1
-----------------------------------------
|                                          |
|                                          |
------------------------                       ------------------------
3.3.3.3                                               2.2.2.2
то, что переносим                      Здесь у меня iptables&squid
----------------------------------                       
-------------------------------
                                                  |
                                                  |
                                                              
------------------------------
                                                                      
Серый адрес, куда надо перенести
                                                                10.10.10.10
                                                                 
-----------------------------



  reply	other threads:[~2006-03-31 10:31 UTC|newest]

Thread overview: 13+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2006-03-30 14:22 Andrey Rybak
2006-03-30 14:30 ` Dmitriy L. Kruglikov
2006-03-31  6:46 ` Rinat
2006-03-31  7:32   ` Kaydannik Axel
2006-03-31 10:31     ` Andrey Rybak [this message]
2006-03-31 10:44       ` Andrey Rybak
2006-03-31 12:08     ` Andrey Rybak
2006-04-05  7:25       ` Шенцев Алексей Владимирович
2006-04-05 12:18         ` Andrey Rybak
2006-04-04 10:38     ` Andrey Rybak
2006-04-04 15:24       ` [Comm] iptables rules?[JT] Мерзляков Евгений Анатольевич
2006-04-04 16:09         ` Andrey Rybak
2006-04-05 17:42           ` Michael Shigorin

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=442D04F9.10106@iop.kiev.ua \
    --to=ra@iop.kiev.ua \
    --cc=community@lists.altlinux.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link

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