# Problem with redirect port 80 to 3128 in other server



## roggy (Sep 15, 2011)

Hi,

I have a problem with configuration to redirect port 80 in the firewall for other server in the network in the port 3128.

firewall (bsd): 172.16.2.1
proxy squid (debian): 172.16.2.2
workstation (windows 7): 172.16.2.10

My proxy it's works in transparent mode. When I put your address and port 3128 manually in the browser, my workstations surf in the internet.

According the post http://forums.freebsd.org/showthread.php?t=15218, I enable on the firewall the key 
	
	



```
net.inet.ip.redirect=0
```
 in the /etc/sysctl.conf and put the rule

```
pass in quick on $int_if route-to (eth0 172.16.2.2) proto tcp from ! 172.16.2.2 to any port 80
```
 but nothing comes in the access.log of the proxy.
What's the problem? Can anyone help?

Thanks!


----------



## DutchDaemon (Sep 15, 2011)

I doubt that the firewall has an eth0 interface.


----------



## roggy (Sep 16, 2011)

eth0 is the interface on the proxy.


----------



## Dies_Irae (Sep 16, 2011)

roggy said:
			
		

> eth0 is the interface on the proxy.



I think it's exactly what DutchDaemon said.

Your firewall (FreeBSD) have no idea of how your proxy (Debian) call his interface.
eth? is the Linux way to name the network interfaces, in FreeBSD the interface name reflect the driver name (e.g.: rl0 = RealTek 8129/8139 -- see rl(4)).

I suppose that you should find what is your interface on the firewall:

[cmd=]ifconfig -a[/cmd]

and correct your pf.conf accordingly.


----------

