Change outgoing MAC address with libipq

David Sancho dsancho at
Mon Nov 21 11:13:12 CET 2005


I have 3 computers: A (client), B Gateway, C Server. I want to intercept A
packets going to C in B, change destination IP to local (B) and process this
packets in B. This is easy. The problem is with the packets originating in
B. I want to change their source IP address and their MAC simulating A IP
and MAC. I want to do a transparent process. B send packets to C but C
thinks that they come from A (IP and MAC)

The IP is also easy with libipq but how can I change the source MAC to match
A's MAC?



More information about the netfilter mailing list