Linux Netfilter discussions
 help / color / mirror / Atom feed
* custom redirector
@ 2004-08-12 16:58 Nicolás Velásquez O.
  2004-08-13  1:02 ` Antony Stone
  0 siblings, 1 reply; 3+ messages in thread
From: Nicolás Velásquez O. @ 2004-08-12 16:58 UTC (permalink / raw)
  To: netfilter


Hello there,

I want to do some custom redirection rules, I've searched the web with
no success.

What I want to do is to set the forward policy a redirect.

Here is what I was trying without success:
$IPTABLES -t nat -N MY_REDIRECTOR_POLICY
$IPTABLES -t nat -A PREROUTING -i $LAN_IFACE -p TCP --dport 80 -j
MY_REDIRECTOR_POLICY --to-port 81
$IPTABLES -A MY_REDIRECTOR_POLICY -j REDIRECT --to-port 81
$IPTABLES -A FORWARD -j MY_REDIRECTOR_POLICY

That snip would go at the end of the rules. so it will work like a
policy.

First of all, is it possible to do what I want to do??

Squid is not an option as no body has to be doing any configuration
changes on the machines. Transparent Proxy won't do the job, as the
objective of the project is to do direct connection. Besides the
connections can happen on non web ports.

-- 

Atentamente,
Nicolás Velásquez
Bogotá, Colombia

(^)   ASCII Ribbon Campaign
 X    NO HTML/RTF in e-mail
/ \   NO Word docs in e-mail


^ permalink raw reply	[flat|nested] 3+ messages in thread
* custom redirector
@ 2004-08-12  4:04 Nicolás Velásquez O.
  0 siblings, 0 replies; 3+ messages in thread
From: Nicolás Velásquez O. @ 2004-08-12  4:04 UTC (permalink / raw)
  To: netfilter



Hello there,

I want to do some custom redirection rules, I've searched the web with 
no success.

What I want to do is to set the forward policy a redirect.

Here is what I was trying without success:
$IPTABLES -t nat -N MY_REDIRECTOR_POLICY
$IPTABLES -t nat -A PREROUTING -i $LAN_IFACE -p TCP --dport 80 -j 
MY_REDIRECTOR_POLICY --to-port 81
$IPTABLES -A MY_REDIRECTOR_POLICY -j REDIRECT --to-port 81
$IPTABLES -A FORWARD -j MY_REDIRECTOR_POLICY

That snip would go at the end of the rules. so it will work like a 
policy.

First of all, is it possible to do what I want to do??

Squid is not an option as no body has to be doing any configuration 
changes on the machines. Transparent Proxy won't do the job, as the 
objective of the project is to do direct connection. Besides the 
connections can happen on non web ports.

-- 

Gracias por su tiempo,

Cordialmente Nicolás Velásquez.
Easy Solutions LTDA.
móvil : +57(1)(300) 5576534
teléfono : +57(1)3490294
Email: nvelasquez@easysol.net


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

end of thread, other threads:[~2004-08-13  1:02 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2004-08-12 16:58 custom redirector Nicolás Velásquez O.
2004-08-13  1:02 ` Antony Stone
  -- strict thread matches above, loose matches on Subject: below --
2004-08-12  4:04 Nicolás Velásquez O.

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox