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

Generate per profile testinfo tables from XCCDF 1.2 #9325

Merged
merged 1 commit into from
Aug 26, 2022

Conversation

jan-cerny
Copy link
Collaborator

Description:

This commit changes the table-${PRODUCT}-${STIG_PROFILE}-testinfo.html
files generator to use the ssg-${PRODUCT}-xccdf-1.2.xml instead of
ssg-${PRODUCT}-xccdf.xml as an input.

Rationale:

This reduces our dependency on XCCDF 1.1 so it will help us to remove the XCCDF 1.1 format in future.

@jan-cerny jan-cerny added the Infrastructure Our content build system label Aug 10, 2022
@jan-cerny jan-cerny added this to the 0.1.64 milestone Aug 10, 2022
@github-actions
Copy link

Start a new ephemeral environment with changes proposed in this pull request:

Fedora Environment
Open in Gitpod

Oracle Linux 8 Environment
Open in Gitpod

This commit changes the `table-${PRODUCT}-${STIG_PROFILE}-testinfo.html`
files generator to use the `ssg-${PRODUCT}-xccdf-1.2.xml` instead of
`ssg-${PRODUCT}-xccdf.xml` as an input.
@jan-cerny
Copy link
Collaborator Author

I have rebased this PR on the top of the latest upstream master branch because they have changed the required set of tests in our GitHub CI.

@codeclimate
Copy link

codeclimate bot commented Aug 24, 2022

Code Climate has analyzed commit 615ac94 and detected 0 issues on this pull request.

The test coverage on the diff in this pull request is 100.0% (50% is the threshold).

This pull request will bring the total coverage in the repository to 42.5% (0.0% change).

View more on Code Climate.

@Mab879 Mab879 self-assigned this Aug 24, 2022
Copy link
Member

@Mab879 Mab879 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The Check Text and 800-53 columns appear to be blank, is this expected?

@jan-cerny
Copy link
Collaborator Author

The Check Text and 800-53 columns appear to be blank, is this expected?

I don't know, but they aren't there in master, so it isn't caused by this PR.

@Mab879 Mab879 merged commit 6f5277c into ComplianceAsCode:master Aug 26, 2022
jan-cerny added a commit to jan-cerny/scap-security-guide that referenced this pull request Aug 26, 2022
In ComplianceAsCode#9325 we discovered that the
`table-${PRODUCT}-${STIG_PROFILE}-testinfo.html` is missing contents in
`Check Text (OCIL Check)` and `800-53 Refs` columns.

However, it isn't caused by ComplianceAsCode#9325, these data were empty even before,
the reasons are:
- the template doesn't expect OCIL as a separate file, it expects
  OCIL data embedded in XCCDF as it used to be in past
- the template used a wrong XML namespace for CCI list so the
  CCI list couldn't be parsed by the template.

This commit tries to solve these 2 problems. However, there are
offensive `<sub>` elements in the HTML output which need still to be
resolved on the level of `ocil-unlinked.xml` generator (it isn't a
problem in this template).
@jan-cerny
Copy link
Collaborator Author

jan-cerny commented Aug 26, 2022

@Mab879 see #9415

dahaic pushed a commit to dahaic/scap-security-guide that referenced this pull request Sep 12, 2022
In ComplianceAsCode#9325 we discovered that the
`table-${PRODUCT}-${STIG_PROFILE}-testinfo.html` is missing contents in
`Check Text (OCIL Check)` and `800-53 Refs` columns.

However, it isn't caused by ComplianceAsCode#9325, these data were empty even before,
the reasons are:
- the template doesn't expect OCIL as a separate file, it expects
  OCIL data embedded in XCCDF as it used to be in past
- the template used a wrong XML namespace for CCI list so the
  CCI list couldn't be parsed by the template.

This commit tries to solve these 2 problems. However, there are
offensive `<sub>` elements in the HTML output which need still to be
resolved on the level of `ocil-unlinked.xml` generator (it isn't a
problem in this template).
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Infrastructure Our content build system XCCDF12
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants