Skip to content

Sort CPEs before adding them to the datastream#7860

Merged
evgenyz merged 3 commits intoComplianceAsCode:masterfrom
ggbecker:sorted-cpe
Nov 11, 2021
Merged

Sort CPEs before adding them to the datastream#7860
evgenyz merged 3 commits intoComplianceAsCode:masterfrom
ggbecker:sorted-cpe

Conversation

@ggbecker
Copy link
Copy Markdown
Member

@ggbecker ggbecker commented Nov 10, 2021

Description:

  • Sort CPEs before adding them to the datastream.
  • Do not show diff for rule security_patches_up_to_date.

Rationale

  • Produce reproduceable builds and remove useless information about security_patches_up_to_date in compare_ds.py tool

@ggbecker ggbecker added this to the 0.1.59 milestone Nov 10, 2021
@pep8speaks
Copy link
Copy Markdown

pep8speaks commented Nov 10, 2021

Hello @ggbecker! Thanks for updating this PR. We checked the lines you've touched for PEP 8 issues, and found:

Line 236:100: E501 line too long (101 > 99 characters)

Comment last updated at 2021-11-10 19:52:07 UTC

@github-actions
Copy link
Copy Markdown

github-actions Bot commented Nov 10, 2021

This datastream diff is auto generated by the check Compare DS/Generate Diff

Click here to see the full diff
Rule 'xccdf_org.ssgproject.content_rule_security_patches_up_to_date' points to 'security-data-oval-com.redhat.rhsa-RHEL8.xml' which isn't a part of the old datastream
Platform has been changed for rule 'xccdf_org.ssgproject.content_rule_chronyd_or_ntpd_set_maxpoll'
--- old datastream
+++ new datastream
-['cpe:/a:chrony', 'cpe:/a:ntp']
+['cpe:/a:ntp', 'cpe:/a:chrony']

@ggbecker ggbecker force-pushed the sorted-cpe branch 3 times, most recently from d88aa1b to 77b8b85 Compare November 10, 2021 19:44
@ggbecker
Copy link
Copy Markdown
Member Author

Unfortunately changes to the workflow will only reflect when the PR gets merged as it uses pull_request_target. I have tested on my fork and they worked pretty well: ggbecker#20 (comment)

The workflow file similarly as it is proposed here: https://github.com/ggbecker/content/blob/master/.github/workflows/compare-ds.yaml

@ggbecker ggbecker requested a review from evgenyz November 10, 2021 23:41
@ggbecker
Copy link
Copy Markdown
Member Author

@evgenyz can you please check this one? thanks

@evgenyz evgenyz merged commit 202d0ad into ComplianceAsCode:master Nov 11, 2021
@JAORMX
Copy link
Copy Markdown
Contributor

JAORMX commented Nov 11, 2021

@ggbecker thanks for this fix!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants