xDhcpServer icon indicating copy to clipboard operation
xDhcpServer copied to clipboard

Add support for Add-DhcpServerSecurityGroup

Open jaywryan opened this issue 9 years ago • 8 comments

Support for Add-DhcpServerSecurityGroup would be nice to have, so as to create the DHCP Administrators and the DHCP Users groups. This is easily worked around with a script resource, but it would be nice to be included in this Resource Module.

jaywryan avatar Apr 12 '16 04:04 jaywryan

I've recently stumbled upon this problem while working with DSC. @kwirkykat I'm happy to do the work. Do you think this should be in it's own resource with a single "Ensure" variable, or could this go into xDhcpServerAuthorization (I already have the code written in there but I can split it out).

lfshr avatar Dec 01 '16 10:12 lfshr

I agree, this is a necessary addition to make the resource really "no touch"

kenvb avatar Jan 14 '17 15:01 kenvb

@LiamFisher92 Is there any instance outside xDhcpServerAuthorization where it would be useful to be able to create the DHCP Administrators and the DHCP Users groups? My first guess is 'probably'. If yes or maybe, it should be its own resource. If no, it can just be a part of xDhcpServerAuthorization via a parameter

kwirkykat avatar Jan 20 '17 00:01 kwirkykat

@kwirkykat I can't think of a reason you would need the security groups without authorizing the DHCP server. Would splitting them out not lead to potential fully set-up unauthorized DHCP servers floating around? I'd be happy to shift them around if somebody else can think of one? I'm conscious of the fact I might lose the code I've already done so I'll submit a PR for now.

lfshr avatar Jan 20 '17 09:01 lfshr

@LiamFisher92 Ok. If there is no reason to split it out, then the security group creation should stay in xDhcpServerAuthorization

kwirkykat avatar Jan 20 '17 22:01 kwirkykat

@kwirkykat I'm not really a DHCP expert (I'm a games development graduate in disguise) so I can't really give you a definitive answer. Do you know anyone who could?

lfshr avatar Jan 20 '17 22:01 lfshr

@LiamFisher92 I'll ask around

kwirkykat avatar Jan 20 '17 23:01 kwirkykat

I think this should be a separate resource - having the DHCP server authorized (Ensure -eq 'Present') or not authorized (Ensure -eq 'Absent'), is not the same as having local security groups present or absent (not sure it's easy to remove them iether once created?).

I suggest a new resource DhcpLocalSecurityGroups is created. The existing PR #33 could might be changed for this.

johlju avatar May 12 '18 11:05 johlju