PowerShell / WmiNamespaceSecurityDsc

This module contains DSC resources to manage WMI Namespace Security.
MIT License
21 stars 14 forks source link

Unable to generate MOF #1

Closed electricJP closed 7 years ago

electricJP commented 8 years ago

Hello,

Trying to use this resource in a configuration file:

WMINamespaceSecurity srv_acc_tst { Path = "root/cimv2" Principal = "contoso\srv_acc_tst" AppliesTo = "Self" AccessType = "Allow" Permission = "Enable","MethodExecute" Ensure = "Present" }

I get this error:

Write-NodeMOFFile : Invalid MOF definition for node 'server.conto.org': Exception calling "ValidateInstanceText" with "1" argument(s): "Convert property 'Permission' value from type 'STRING[]' to type 'STRING' failed At line:46, char:2 Buffer: e = "My_Config"; };^ insta " At C:\Windows\system32\WindowsPowerShell\v1.0\Modules\PSDesiredStateConfiguration\PSDesiredStateConfiguration.psm1:2275 char:21

Removing the above section allows the MOF generation.

Any idea? I would really need to use this resource to ease my work. Thank you.

JP

SteveL-MSFT commented 7 years ago

@electricJP sorry for not monitoring this repo, but I've pushed a fix for this. Apparently a change in DSC broke this resourece as an enum array isn't supported, so I changed it to a string array.

SandeshT19 commented 3 years ago

Hi I Am still facing same issue ,but did not get the fix ..