0

I have a client in my network, who ask me to prevent him from getting ip address via dhcp.

He has a strange software, and can't switch off dhcp-client, but this dhcp client do something bad after it get ip.

In same vlan I have clients who needs dhcp to work.

I tryed that for isc-dhcp41-server-4.1.e,2:

host client_disable {                                                                                                                                                             
  hardware ethernet aa:bb:cc:dd:rr:ff;                                                                                                                                     
  fixed-address 0.0.0.0;                                                                                                                                                   
} 

Its seems like doesn't works.

I am trying to google that, but looks like its pretty strange scenarios, and I can't find anything appropriate.

Please, point me to right solution.

Korjavin Ivan
  • 2,230
  • 2
  • 25
  • 39

1 Answers1

0

I compiled solution from other answers:

  1. Detect format of client mac.

    log(info, concat("Ignored Client ",binary-to-ascii(16, 8, ":", substring(hardware, 0, 12))));

That has output like "1:bc:ee:dd:gg:zz:pp"

Strange "1:" at beginning.

  1. Add class for that

    class "ignored" {
    match if (binary-to-ascii(16, 8, ":", substring(hardware, 0, 12))) = "1:bc:ee:dd:gg:zz:pp";

    }

  2. Insert pool and deny into subnet:

    subnet 10.10.10.0 netmask 255.255.255.0 {                                                                                                                                   
        pool{                                                                                                                                                                  
        deny members of "ignored";       
    
Korjavin Ivan
  • 2,230
  • 2
  • 25
  • 39