Linux Help
guides forums blogs
Home Desktops Distributions ISO Images Logos Newbies Reviews Software Support & Resources Linuxhelp Wiki

Welcome Guest ( Log In | Register )



Advanced DNS Management
New ZoneEdit. New Managment.

FREE DNS Is Back

Sign Up Now
 
Reply to this topicStart new topic
> Problem with port forwarding
Sentinel8o
post Jun 20 2006, 10:56 AM
Post #1


Whats this Lie-nix Thing?
*

Group: Members
Posts: 3
Joined: 20-June 06
Member No.: 6,585



hello,
Im running fedora core 4 box with iptables, ebtables, and squid. Im trying to create a transparent proxy/ webcaching server and cannot get the damn box to forward port 80 requests to squids default port 3128. Ive tried everything and nothing seems to work. I have created a script that i run when i want to enable forwarding so maybe you guys can find something i am missing. i can browse the web if i configure the web browser to use specfic proxy and port 3128, so i no that squid is configured correctly. Im also a little confused on if i need to use ebtables or not. I have seen on some how-tos that with linux kernel 2.6 ebtables is not needed because you can simply use iptables. I have listed the script i run to set up the box.
iptables version - iptables v1.3.5
ebtables version - ebtables v2.0.8-rc2 (March 2006)
--------------------------test.sh script-------------------------
echo "1" >/proc/sys/net/ipv4/ip_forward
echo "** Kernel Ip_Forwarding enabled **"
ifconfig eth0 0.0.0.0 promisc up
ifconfig eth1 0.0.0.0 promisc up
echo "** NICS Configured **"
brctl addbr br0
brctl addif br0 eth0
brctl addif br0 eth1

ifconfig br0 (*ip of linux box*) netmask 255.255.224.0 up
route add default gw (*gateway ip*) dev br0
echo "** Bridge Configured **"

ebtables -t broute -A BROUTING -p IPv4 --ip-protocol 6 --ip-destination-port 80 -j redirect --redirect-target ACCEPT
iptables -t nat -A PREROUTING -i br0 -p tcp --dport 80 -j REDIRECT --to-port 3128
echo " ACL's for ebtables and iptables completed. "
Go to the top of the page
 
+Quote Post

Reply to this topicStart new topic
1 User(s) are reading this topic (1 Guests and 0 Anonymous Users)
0 Members:

 



RSS Lo-Fi Version Time is now: 21st October 2017 - 03:46 AM