bridge to local process.

Padam J Singh <[email protected]> Wed, 13 Jun 2007 17:47:05 +0530
Newsgroups gmane.linux.network.bridge.ebtables.user
Message-ID <[email protected]>
Hello,

I need some help regarding a setup which looks pretty simple, however
is not working for me. The setup is:

Multiple LANs ----> [Bridge] ---> [Cisco Router] ---> Internet

What I have running on the bridge is a http process on port 8080, that
intercepts packets from certain LAN IP addresses going to any web
server on the internet. The page is a static page that shows certain
content and then redirects to the requesting page.

I have tested the same by putting the same box into routing mode by
using the following command:

iptables -t nat -I PREROUTING -i $LAN_DEVICE -s $TRAP_SUBNET -p tcp
--dport 80 -j REDIRECT --to-port 8080

Once the box is put into bridging mode using the following command, the
connection fails.

ebtables -t broute -A BROUTING -p IPv4 --ip-protocol 6
--ip-destination-port 80 -j redirect --redirect-target ACCEPT

iptables
-t nat -I PREROUTING -i br0 -s $TRAP_SUBNET -p tcp --dport 80 -j
REDIRECT --to-port 8080

the commands to put the box into bridging mode are:

brctl addbr br0

brctl addif br0 eth0

brctl
addif br0 eth1

ifconfig br0 10.1.1.1 netmask 255.255.255.255 up

There is no default gateway ... the bridge itself does not need
internet connectivity.

How can I have the local process send packets back to the sender?? I am
seeing packets coming into the interface, however, nothing gets sent
back!

Thanks,

Padam

-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/

_______________________________________________
Ebtables-user mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/ebtables-user