DaemonForums  

Go Back   DaemonForums > OpenBSD > OpenBSD General

OpenBSD General Other questions regarding OpenBSD which do not fit in any of the categories below.

Reply
 
Thread Tools Display Modes
  #1   (View Single Post)  
Old 8th January 2016
avayax avayax is offline
New User
 
Join Date: Jan 2016
Posts: 1
Default Specific DHCP config on OpenBSD

Running OpenBSD 5.7.

I would like to set up a DHCP server on my BSD machine, that can do the following:
-Only assign IP addresses to devices with a particular manufacturer MAC prefix (MAC wildcard)
-Never assign IP addresses to devices with a different MAC
-Configure DHCP option (66 or 43) to pass provisioning server address for tftp or http provisioning

Is that possible and how would I do that?

The reason for all this is, that I want to use that DHCP server to assign IP addresses for VoIP phones.
(Other non-VoIP network devices I handle through a different DHCP server, with DHCP reservations for known MAC addresses).
Reply With Quote
  #2   (View Single Post)  
Old 8th January 2016
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 4,128
Default

Note that the OpenBSD dhcpd server is a "light" or rather minimal server. dhcpd.conf(5) does not list any MAC wildcard filtering.

The ISC dhcpd server in the OpenBSD ports collection has more bells and whistles.

A quick google for "ISC DHCP MAC wildcard" showed some suggestions in Assigning IP Range to Wildcard MAC-Adresses with ISC dhcpd
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump
Reply With Quote
  #3   (View Single Post)  
Old 8th January 2016
Oko's Avatar
Oko Oko is offline
Rc.conf Instructor
 
Join Date: May 2008
Location: Kosovo, Serbia
Posts: 1,102
Default

Quote:
Originally Posted by J65nko View Post
Note that the OpenBSD dhcpd server is a "light" or rather minimal server. dhcpd.conf(5) does not list any MAC wildcard filtering.
This is very interesting post. I didn't catch that OP wanted to use pattern matching (regular expressions) to filter MAC. The lack of the support for regular expressions has little to do with being light but it is probably due to security issues. Now similar feature was most sought feature for new httpd daemon and was resolved by adding Lua patterns which don't suffer from the same security issues like regular expressions.
http://lua-users.org/wiki/PatternsTutorial
I bet you this can be easily done for dhcpd from the base.
Reply With Quote
  #4   (View Single Post)  
Old 8th January 2016
J65nko J65nko is offline
Administrator
 
Join Date: May 2008
Location: Budel - the Netherlands
Posts: 4,128
Default

RE: tftp provisioning

You can pass the address of a tftp server with the next-server statement. From dhcpd.conf(5):
Code:
           group {
             filename "Xncd19r";
             next-server ncd-booter;

             host ncd1 { hardware ethernet 0:c0:c3:49:2b:57; }
             host ncd4 { hardware ethernet 0:c0:c3:80:fc:32; }
             host ncd8 { hardware ethernet 0:c0:c3:22:46:81; }
           }
The dhcp-options(5) page describes the option option voip-configuration-server :
Quote:
option voip-configuration-server ip-address [, ip-address ...];

The voip-configuration-server option specifies a list of (normally TFTP) servers that VoIP clients may download their configuration information and software images from. Servers should be listed in order of preference.
Re: DHCPD light

@Oko, it is a "light" version compared with the ISC dhcpd server. It misses for example the ISC dhcp-eval(5) capabilities
__________________
You don't need to be a genius to debug a pf.conf firewall ruleset, you just need the guts to run tcpdump

Last edited by J65nko; 8th January 2016 at 11:56 PM.
Reply With Quote
Reply

Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Resolving DHCP hostnames - OpenBSD router bceverly OpenBSD General 4 19th July 2015 07:19 PM
OpenBSD unable to configure DHCP on eth0 cravuhaw2C OpenBSD Installation and Upgrading 17 14th July 2014 07:43 AM
OpenBSD-5.4::PF config issue Atlantis OpenBSD Security 7 15th February 2014 01:30 PM
specific reason OpenBSD in MBR table id 3 ershiba OpenBSD Installation and Upgrading 2 2nd January 2013 02:52 PM
OpenBSD specific books I have WeakSauceIII OpenBSD General 1 25th May 2008 09:40 PM


All times are GMT. The time now is 07:32 PM.


Powered by vBulletin® Version 3.8.4
Copyright ©2000 - 2024, Jelsoft Enterprises Ltd.
Content copyright © 2007-2010, the authors
Daemon image copyright ©1988, Marshall Kirk McKusick