Send dhcp-users mailing list submissions to
        dhcp-users@lists.isc.org

To subscribe or unsubscribe via the World Wide Web, visit
        https://lists.isc.org/mailman/listinfo/dhcp-users
or, via email, send a message with subject or body 'help' to
        dhcp-users-requ...@lists.isc.org

You can reach the person managing the list at
        dhcp-users-ow...@lists.isc.org

When replying, please edit your Subject line so it is more specific
than "Re: Contents of dhcp-users digest..."


Today's Topics:

   1. Merging classes (Andrew Bell)


----------------------------------------------------------------------

Message: 1
Date: Tue, 6 Sep 2022 16:38:37 -0400
From: Andrew Bell <and...@poscomp.ca>
To: Users of ISC DHCP <dhcp-users@lists.isc.org>
Subject: Merging classes
Message-ID:
        <CAMcY7=in74CthMFSfZPgsyTEQSbkYr=1qoxezyjk2rbdomk...@mail.gmail.com>
Content-Type: text/plain; charset="utf-8"

Hello all,

I currently have a home grown IPAM that generates a class of allowed mac
addresses for use in various privileged address pools.  Something like this:

class "coolkids" {match hardware;}
subclass "coolkids" 1:22:33:44:55:66:77;
subclass "coolkids" 1:88:99:AA:BB:CC:DD;
...

What I want to do is allow a specific group of devices in addition to
these, but using the vendor id instead of entering their mac addresses into
the IPAM.

class "coolkids" {
  match if substring (option vendor-class-identifier, 0, 7) = "abcedfg";
}

I know I can do this by using 2 separate classes and adding a second "allow
from" statement to each pool, but the pools are dynamically generated by
the IPAM and there be dragons in that code. I know, I wrote it a decade
ago...

Does anyone know of a clever way to build up a class with two different
match conditions?

Andrew
-------------- next part --------------
An HTML attachment was scrubbed...
URL: 
<https://lists.isc.org/pipermail/dhcp-users/attachments/20220906/3e08e589/attachment-0001.htm>

------------------------------

Subject: Digest Footer

_______________________________________________
ISC funds the development of this software with paid support subscriptions. 
Contact us at https://www.isc.org/contact/ for more information.

dhcp-users mailing list
dhcp-users@lists.isc.org
https://lists.isc.org/mailman/listinfo/dhcp-users


------------------------------

End of dhcp-users Digest, Vol 167, Issue 1
******************************************

Reply via email to