microsoft / PowerStig

STIG Automation
https://www.powershellgallery.com/packages/PowerSTIG
Other
543 stars 115 forks source link

IIS 10.0 Site hardening using PowerSTIG v4.4.2 fails with error for rule [V-100195 V-100219 V-100257] in Windows Server 2019 #675

Closed kmsarfraz closed 4 years ago

kmsarfraz commented 4 years ago

Describe the bug IIS 10.0 Site hardening using PowerSTIG v4.4.2 fails with error for rule [V-100195 V-100219 V-100257] in Windows Server 2019

To Reproduce 1.Configure website name and AppPool name in the configuration file. 2.Generate MOF file using the configuration 3.Start the configuration using MOF file 4.Some errors can be found. One of the error is shown below that is related to the rule V-100195 V-100219 V-100257 .

VERBOSE: [WIN-E8ANUAHH860]: LCM: [ Start Test ] [[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine] PowerShell Desired State Configuration does not support execution of commands in an interactive mode. Please ensure that the underlying command is not prompting for user input, such as missing mandatory parameter, confirmation prompt etc.

VERBOSE: [WIN-E8ANUAHH860]: [[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine] Get-TargetResource has been run. VERBOSE: [WIN-E8ANUAHH860]: LCM: [ End Test ] [[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine] in 0.0630 seconds. The PowerShell DSC resource '[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine' with SourceInfo 'C:\Program Files\WindowsPowerShell\Modules\PowerStig\4.4.2\DSCResources\Resources\windows.xSslSettings.ps1::10::9::xSslSettings' threw one or more non-terminating errors while running the Test-TargetResource functionality. These errors are logged to the ETW channel called Microsoft-Windows-DSC/Operational. Refer to this channel for more details.

VERBOSE: [WIN-E8ANUAHH860]: LCM: [ End Set ] Expected behavior Execution should happen without errors.

Screenshots VERBOSE: [WIN-E8ANUAHH860]: LCM: [ Start Test ] [[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine] PowerShell Desired State Configuration does not support execution of commands in an interactive mode. Please ensure that the underlying command is not prompting for user input, such as missing mandatory parameter, confirmation prompt etc.

VERBOSE: [WIN-E8ANUAHH860]: [[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine] Get-TargetResource has been run. VERBOSE: [WIN-E8ANUAHH860]: LCM: [ End Test ] [[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine] in 0.0630 seconds. The PowerShell DSC resource '[xSSLSettings][V-100195 V-100219 V-100257]Default Web Site\ccnet::[IisSite]BaseLine' with SourceInfo 'C:\Program Files\WindowsPowerShell\Modules\PowerStig\4.4.2\DSCResources\Resources\windows.xSslSettings.ps1::10::9::xSslSettings' threw one or more non-terminating errors while running the Test-TargetResource functionality. These errors are logged to the ETW channel called Microsoft-Windows-DSC/Operational. Refer to this channel for more details.

VERBOSE: [WIN-E8ANUAHH860]: LCM: [ End Set ]

Additional context

bcwilhite commented 4 years ago

Hi @kmsarfraz could you share the configuration that you are using to generate the errors? In testing with the "Default Web Site" the configuration will run successfully, however, I noticed in your output that the site it's trying to apply to is "Default Web Site\ccnet" is this a valid site in your environment?

kmsarfraz commented 4 years ago

Thank you. Error is not occurring with "Default Web Site" alone configured in configuration file. Hence closing this ticket.