LINUX.ORG.RU
ФорумAdmin

squid без изменения информации об адресе запроса.


0

1

Хочется чтобы у запросов на выходе оставлись клиентские адреса.
Например клиент послал запрос, запрос попал в squid, и пошел уже дальше но НЕ от имени squid.
вот думаю как бы так извернутся.

★★★★★

SOCKS-прокси хочешь ты

anonymous
()

squid в режим TPROXY, что-ли нужен? Я просто не понял «клинетские адреса» и «от имени squid» — адрес и имя это одно или разное?

mky ★★★★★
()

непонятная постановка вопроса. коннект в любом случае будет выглядеть, как инициированый проксё или NAT-шлюзом, от имени клиента - это называется роутинг :)

blind_oracle ★★★★★
()
Ответ на: комментарий от mky

За шлюзом сидят клиенты с локальными ip. Нужно чтобы squid на шлюзе не мешал вышестоящей проксе видеть с каких локальных ip идут запросы.

kerneliq ★★★★★
() автор топика
Ответ на: комментарий от kerneliq

Нужно чтобы squid на шлюзе не мешал вышестоящей проксе видеть с каких локальных ip идут запросы.

а почему нельзя было так в исходном посте написать?

дефолтный squid.conf
# OPTIONS FOR X-Forwarded-For
# -----------------------------------------------------------------------------

#  TAG: follow_x_forwarded_for
#	Allowing or Denying the X-Forwarded-For header to be followed to
#	find the original source of a request.
#
#	Requests may pass through a chain of several other proxies
#	before reaching us.  The X-Forwarded-For header will contain a
#	comma-separated list of the IP addresses in the chain, with the
#	rightmost address being the most recent.
#
#	If a request reaches us from a source that is allowed by this
#	configuration item, then we consult the X-Forwarded-For header
#	to see where that host received the request from.  If the
#	X-Forwarded-For header contains multiple addresses, and if
#	acl_uses_indirect_client is on, then we continue backtracking
#	until we reach an address for which we are not allowed to
#	follow the X-Forwarded-For header, or until we reach the first
#	address in the list.  (If acl_uses_indirect_client is off, then
#	it's impossible to backtrack through more than one level of
#	X-Forwarded-For addresses.)
#
#	The end result of this process is an IP address that we will
#	refer to as the indirect client address.  This address may
#	be treated as the client address for access control, delay
#	pools and logging, depending on the acl_uses_indirect_client,
#	delay_pool_uses_indirect_client and log_uses_indirect_client
#	options.
#
#	SECURITY CONSIDERATIONS:
#
#		Any host for which we follow the X-Forwarded-For header
#		can place incorrect information in the header, and Squid
#		will use the incorrect information as if it were the
#		source address of the request.  This may enable remote
#		hosts to bypass any access control restrictions that are
#		based on the client's source addresses.
#
#	For example:
#
#		acl localhost src 127.0.0.1
#		acl my_other_proxy srcdomain .proxy.example.com
#		follow_x_forwarded_for allow localhost
#		follow_x_forwarded_for allow my_other_proxy
#
#Default:
# follow_x_forwarded_for deny all

#  TAG: acl_uses_indirect_client	on|off
#	Controls whether the indirect client address
#	(see follow_x_forwarded_for) is used instead of the
#	direct client address in acl matching.
#
#Default:
# acl_uses_indirect_client on
anonymous
()
Ответ на: комментарий от kerneliq

Ну, транспарент прокси точно не подходит, т.к. вышестоящий прокси будет видеть айпи твоего сквида. А х форвардед фор как раз придуман для решения этой задачи.

blind_oracle ★★★★★
()
Вы не можете добавлять комментарии в эту тему. Тема перемещена в архив.