Multiple MACs on one interface?

My cable-modem service provides up to four IP addresses, but they're assigned via DHCP based on the MAC address of the client. I'd like to configure my FreeBSD 9.x firewall so that the external interface has more than one address, so I can NAT certain traffic to a separate external address. It seems that, to do this, I need each virtual interface on the external interface to have its own MAC address.

The external interface is an Intel gigabit NIC using the em driver.

I'd prefer not to have to install multiple physical interfaces and put a switch between the router and the cable modem to achieve this.

Is this possible, and if so, what's the best way to do it?
 
You will need to do a fair bit of creative implementation, but the net/isc-dhcp43-client port might be of help. It depends on whether your ISP actually enforces the relationship between the on-the-wire MAC and DHCP client ID. If their DHCP service is actually based only on the client ID in the layer 3 DCHP packets, it may provide a framework for a solution. It offers many more options than FreeBSD's /sbin/dhclient (which is derived from an obsolete and much older version of ISC DHCP).
 
Back
Top