-
Notifications
You must be signed in to change notification settings - Fork 115
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
'Variable' null/empty for SQL Server 2016 instance STIG #1331
Comments
I would assume you are missing the audit directory based on that rule. Can you try to use the whole dsc config from that example? The path needs to be "'C:\Audits' configuration Example
{
param
(
[parameter()]
[string]
$NodeName = 'localhost'
)
Import-DscResource -ModuleName PowerStig
Node localhost
{
File SqlAudit
{
Ensure = "Present"
Type = "Directory"
DestinationPath = "C:\Audits"
}
SqlServer BaseLine
{
SqlVersion = '2016'
SqlRole = 'Instance'
ServerInstance = 'SQL2019onServer'
}
}
}
Example
|
I'm not sure that's it -- I had manually created the I also deleted the directory and then ran the example config with the additional Is there anything else I might be missing? |
@erjenkin -- thanks so much for testing that out. I think I figured out what the problem is. The only other PS module I'd installed aside from PowerSTIG was SqlServer, which I needed it to run another piece of software that assesses STIG compliance. It looks like the presence of the To test:
I'm not sure why the presence of the |
I'm attempting to run the SQL Server 2016 instance STIG on a SQL Server 2019 instance (which should be OK as mentioned in #730).
Here's my script:
When executed, all the
SqlScriptQueryRule
items (except V-214029) hit an exception at the 'test' step:There aren't any organizational settings for these rules and there do not appear to be any variables used in the test script. The exception remains if I attempt to delete the empty
<Variable />
and<VariableValue />
elements fromSqlServer-2016-Instance-2.10.xml
, but the STIG will run fine if I enter dummy values:Is there something I need to add into the DSC config or the organizational settings file to prevent this exception? Or is this a bug?
The text was updated successfully, but these errors were encountered: