Problem
In source/Modules/DhcpServerDsc.OptionValueHelper/Public/Get-TargetResourceHelper.ps1 around lines 119-145, the Get-DhcpServerv4OptionValue calls for both scope-level and server-level policy lookups omit the UserClass parameter.
Impact
This can cause reading the wrong option value when multiple option values exist with different user classes, as the function cannot disambiguate between class-scoped values.
Expected Fix
Both policy lookup branches (with and without ScopeId) should include UserClass parameter in their parameters hashtables when calling Get-DhcpServerv4OptionValue.
Affected Code Location
- File: source/Modules/DhcpServerDsc.OptionValueHelper/Public/Get-TargetResourceHelper.ps1
- Lines: 119-145 (Policy switch case)
- Both if-ScopeId and else branches missing UserClass parameter
References
Problem
In source/Modules/DhcpServerDsc.OptionValueHelper/Public/Get-TargetResourceHelper.ps1 around lines 119-145, the Get-DhcpServerv4OptionValue calls for both scope-level and server-level policy lookups omit the UserClass parameter.
Impact
This can cause reading the wrong option value when multiple option values exist with different user classes, as the function cannot disambiguate between class-scoped values.
Expected Fix
Both policy lookup branches (with and without ScopeId) should include UserClass parameter in their parameters hashtables when calling Get-DhcpServerv4OptionValue.
Affected Code Location
References