Skip to content
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

Ckl file fails XML validation with Stig Viewer 2.8 #259

Closed
cawwot opened this issue Jan 31, 2019 · 3 comments
Closed

Ckl file fails XML validation with Stig Viewer 2.8 #259

cawwot opened this issue Jan 31, 2019 · 3 comments
Assignees
Labels
bug Something isn't working In Progress
Milestone

Comments

@cawwot
Copy link

cawwot commented Jan 31, 2019

Describe the bug
Attempting to import a CKL file that was exported using New-StigChecklist into Stig Viewer 2.8 fails with the error message "Checklist failed XML schema validation for checklist schema V2.0". CKL works in Stig Viewer version 2.7.1 and previous.

To Reproduce

  1. Create CKL using New-StigChecklist
  2. Open checklist in Stig Viewer 2.8 using the "Open Checklist from File" option
  3. Checklist fails to open and error appears

Screenshots
error

@athaynes athaynes added this to the 3.0.0.0 milestone Feb 4, 2019
@athaynes
Copy link
Contributor

athaynes commented Feb 4, 2019

Thanks @cawwot I'll add this in with #258 for the 3.0 update

@athaynes athaynes self-assigned this Feb 6, 2019
@athaynes athaynes modified the milestones: 3.0.0.0, 3.1.0 Mar 1, 2019
@athaynes athaynes modified the milestones: 3.1.0, 3.2.0 Apr 1, 2019
@stevehose
Copy link
Contributor

The issue should remain open but there is a workaround. In STIG Viewer (Version 2.8 for sure - other versions likely), before attempting to open a .ckl file, update preferences. To do so, select Options > Preferences from the menu. In the Preferences dialog, select the Checklist tab. On this tab, uncheck the Validate Checklists option. After this change has been made, the .ckl files generated by PowerStig can be opened.

stevehose pushed a commit that referenced this issue Nov 19, 2019
@stevehose stevehose added bug Something isn't working In Progress labels Nov 27, 2019
@stevehose stevehose modified the milestones: 3.2.0, 4.2.0 Nov 27, 2019
@stevehose stevehose assigned stevehose and unassigned athaynes Nov 27, 2019
@bcwilhite bcwilhite modified the milestones: 4.2.0, 4.3.0 Dec 20, 2019
bcwilhite added a commit that referenced this issue Feb 13, 2020
* Updated based on issue (#523)

* Feature request: additional support for servicerule properties #514 (#525)

* Added property based on community request

* updated issue version

* Updated win10 system drive path in convert module (#526)

* Updates for Issues #259 and #527

* added support for 2012R2 MS/DC 2.17/2.18 (#532)

* added support for 2012R2 MS/DC 2.17/2.18

* added new line on the xccdf

* removed tab from processed xml.

* updated to successfully parse Win10 V1R19 (#534)

* added support for FireFox 4.27 (#541)

* added support for IE 1.18 (#539)

* added support for .net 4.0 V1R9 (#536)

* Update PowerSTIG to parse the IIS 8.5 1.9 Site and Server STIGs (#537)

* Initial Convert and update IIS 8.5 1.9

* remove n-2 STIGs

* removed quotes

* added newline to raw xccdf

* updated based on PR feedback

* Version update

* MInor updates

* Update PowerSTIG to successfully parse Microsoft SQL Server 2016 Instance STIG - Ver 1, Rel 7 (#544)

* fixed and updated SQL Instance STIGs

* updated sqlserver composite and removed tabs

* updated sqlserver composite.

* removed tabs

* Code changes to correct issues

* Updated JRE rule V-66941.a to be a org setting (#543)

* updated JRE rule V-66941.a to be a org settings

* updated name of processed STIG

* update changelog

* added space to TS build issue.

* Updates to add functionality and address bugs

* Need a test to verify the conversionstatus="fail" does not exist in processed STIGs (#550)

* updated Win2016DC failed converts and added tests

* removed V-73517 from MS-1.9 as the rule no longer
exist.

* Update PowerSTIG to parse and apply OfficeSystem 2013 STIG V1R9 / 2016 V1R1 (#553)

* added Office-System2013 STIG support.

* reconverted xccdfs, corrected issues in some
processed stigs.

* added OfficeSystem 2016 V1R1 STIG

* updated changelog.md

* Update: duplicate rules for checklist & bug fixes

* Updates to fix DSC results bugs

* Fixed error in New-StigChecklist

* Minor update to support debugging

* Final commit prior to PR. Updated changelog.

* stevehose#443 and #528 check list bug fixes (#529)

* Update to fix checklist bugs

* Fixed bug in checklist parameter ManualCheckFile

* Updated Checklist Pester tests

* Updates based upon PR comments

* Updated changelog.md

* Add test to assert dependent module versions (#555)

* Added helper function
And test to verify module versions

* Added tests to assert dependant module versions.

* Removed commented code

* Removed whitespace

* Update PowerSTIG to parse and apply Windows Server 2019 V1R2 STIG (#557)

* added support for 2019 MS
modified hardcoded parser rule ids to support
2019 MS

* added support for 2019 DC STIG; parser update
to address failed AD permission rules
(ActiveDirectoryAuditRule) which isn't currently
implemented

* Added ProcessMitigation to WindowsServer composite

* regenerated all xccdfs, 6 were corrected/modified

* updated changelog.md

* appveyor build issue - space insert

* Updates to fix build bugs

* Updated to fix bugs in build

* Fix to missing reference

* Build error fix - missing newline

* prep for 4.2.0 release, update changelog, filehash
markdowns and module manifest

* Fix for build missing functions reference

* Relocated file to be picked up during runtime

* Minor update to remove test code

* Updated for build errors

* Updated processed SQL Server 1.3 files

* Updates for PR

* Updates for PR

* Updated for PR

* Updates for PR

* Moving changes for SQL to another branch

* Update for PR

Co-authored-by: Eric Jenkins <erjenkin@microsoft.com>
Co-authored-by: Brian Wilhite <bcwilhite@live.com>
Co-authored-by: Jason Walker <walkerjason@live.com>
@github-4me
Copy link

I came across this problem today and fixed this by using tab indention, I found this code here

function Format-XML ([xml]$xml)
{
$stringbuilder = New-Object System.Text.StringBuilder
$settings = New-Object System.Xml.XmlWriterSettings
$settings.Indent = $true
$settings.IndentChars = "tt"
$xmlWriter = [System.XML.XmlWriter]::Create($stringbuilder, $settings)
$xml.WriteContentTo($xmlWriter)
$xmlWriter.Close()
$xmlDoc = [System.Xml.XmlDocument]::new()
$xmlDoc.PreserveWhitespace = $true
$xmlDoc.LoadXml($stringbuilder.ToString())
return $xmlDoc
}

CKL file opens correctly in STIG Viewer 2.10 now.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working In Progress
Projects
None yet
Development

No branches or pull requests

5 participants