Skip Menu |

Preferred bug tracker

Please visit the preferred bug tracker to report your issue.

This queue is for tickets about the Net-ISC-DHCPd CPAN distribution.

Report information
The Basics
Id: 67742
Status: resolved
Priority: 0/
Queue: Net-ISC-DHCPd

People
Owner: JHTHORSEN [...] cpan.org
Requestors: johnson.raj [...] wipro.com
Cc:
AdminCc:

Bug Information
Severity: Important
Broken in: 0.1001
Fixed in: (no value)



Subject: Not able to parse the class object content from the dhcpd.conf file
Current code is not able to parse 'class' object, My dhcpd.conf has the following piece of codes class "pxeclients" { match if substring(option vendor-class-identifier,0,9) ="PXEClient"; next-server 10.201.214.90; } class "virtual-machines" { match if ((substring (hardware, 1, 3) = 00:0c:29) or (substring (hardware, 1, 3) = 00:50:56) or (substring (option dhcp-client-identifier, 0, 3) = "HPC")); } But when I use the following code, my $config = Net::ISC::DHCPd::Config->new( file => '/etc/dhcpd.conf', ); # parse the config $config->parse; pring $config->generate; Output related class objects or (substring (option dhcp-client-identifier, 0, 3) = "HPC")); or (substring (hardware, 1, 3) = e1:6c:d6) ); Regards, Johnson
I just closed https://rt.cpan.org/Ticket/Display.html?id=71372 - where I added ::Config::Block. Is that good enough for you? Check out github for changes: https://github.com/jhthorsen/net-isc- dhcpd/commit/523ba508d598ba2702a5279d7d8bb02ddd24bead
On Mon Oct 03 15:41:45 2011, JHTHORSEN wrote: Show quoted text
> I just closed https://rt.cpan.org/Ticket/Display.html?id=71372 - where I > added ::Config::Block. Is that good enough for you? > > Check out github for changes: > https://github.com/jhthorsen/net-isc- > dhcpd/commit/523ba508d598ba2702a5279d7d8bb02ddd24bead
Closing this since it's been open 3 years without comments. I've made large improvements to class support in github master and I think it should cover everything in this bug report. If there are configs that it won't parse or if we generate the wrong output please reopen this ticket or make a new one.