MAC Address masking/NAT

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hello,

Apparently, I'm just not getting some of the tables and chains
concepts enough to make the following scenario work. Any help would be
greatly appreciated.

I have a bridge setup between two computer systems. To be more
detailed, the bridge (br0) is setup on a Linksys WRT54GL across two of
the switch ports that have been VLAN tagged (eth0.1 and eth0.2). In
this setup, Host A and Host B communicate as expected.

What I'd like to do is use iptables or ebtables to.... change the MAC
address of Host B as packets traverse the bridge. Host A will only see
the "changed" MAC address, not the actual one of Host B.

Here's a lame ascii art diagram:

              ____________________
             |                    |
             |        br0         |
             |                    |
             | eth0.1      eth0.2 |
             |__/______________\__|
               /                \
              /                  \ <--- Translate MAC to
             /                    \     11:11:11:22:22:22
            /                      \
           /                        \
       ___|___                    ___|___
      |       |                  |       |
      |   A   |                  |   B   |
      |_______|                  |_______|
MAC: 00:11:22:33:44:55      MAC:55:44:33:22:11:00

Can this be done? Also, if I don't know the MAC address of either
host, can a rule be written as a "catch-all" to change any MAC that's
plugged in?

Many Thanks.

-tim
--
To unsubscribe from this list: send the line "unsubscribe netfilter" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Netfilter Development]     [Linux Kernel Networking Development]     [Netem]     [Berkeley Packet Filter]     [Linux Kernel Development]     [Advanced Routing & Traffice Control]     [Bugtraq]

  Powered by Linux