DHCP server dummy0 and IPTABLES ...

Sébastien Cramatte scramatte at nixus.es
Sun Jan 22 18:34:09 UTC 2012


Hello,

I need to have DHCP server listening on dummy0 and relay  dhcp packets 
from eth0 or eth1 to dummy0.
I use dummy0 because dhcp server doesn't allow binding on loopback 
interface.

My goal is to be able to filter incoming dhcp packets using iptable 
"string" module  and send to dhcp-server only good packets !
If we detect a strange behavior like a client that ask for a lease 
continuously  we will able to drop  the traffic before income on the 
real dhcp-server.

So what I need is a way to redirect DHCP packets to  dummy0 interface.
I've tried with TPROXY, REDIRECT, DNAT  and including  dhcp relay on 
eth0 and eth1  but nothing works ...

Note that I've disabled rp_filter and enabled  forwarding

Anybody  have got any ideas of how I can achieve this ?



Thank you





More information about the dhcp-users mailing list