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

Fix profile titles in generated ansible roles #1112

Closed
matusmarhefka opened this issue Jul 11, 2018 · 2 comments · Fixed by #1295
Closed

Fix profile titles in generated ansible roles #1112

matusmarhefka opened this issue Jul 11, 2018 · 2 comments · Fixed by #1295
Labels
Milestone

Comments

@matusmarhefka
Copy link
Member

matusmarhefka commented Jul 11, 2018

Description of Problem:

When there are newlines in profile title there are no commentary marks for these newlines in the generated ansible role headers. This results in an invalid generated ansible roles.

Steps to Reproduce:

To reproduce you need to build older version of SSG (tested with 0.1.36) which has one such a profile title. The role with the issue is ssg-rhel6-role-nist-cl-il-al.yml.

This issue is also reported in RHBZ#1548499 and can be fixed in a simillar way as the profile description was fixed in the PR #838.

@jan-cerny jan-cerny added this to the 1.2.18 milestone Jul 11, 2018
@matusmarhefka matusmarhefka modified the milestones: 1.2.18, 1.3.1 Nov 13, 2018
@redhatrises
Copy link
Member

This appears to have been fixed. Closing.

@jan-cerny
Copy link
Member

@redhatrises Unfortunately, it hasn't been fixed.

If you modify the content eg. the following way:

<title xml:lang="en-US" override="true">
OSPP
Protection
Profile
for
General
Purpose
Operating
Systems
</title>

and then your run

oscap xccdf generate fix --profile ospp --fix-type ansible ssg-fedora-ds.xml > fix.yml

Then you get this:

---
###############################################################################
#
# Ansible Playbook for 
OSPP
Protection
Profile
for
General
Purpose
Operating
Systems

#
# Profile Description:
# This profile reflects mandatory configuration controls identified in the
# NIAP Configuration Annex to the Protection Profile for General Purpose
# Operating Systems (Protection Profile Version 4.2).

Notice the missing #s at the beginning of lines. That makes the playbook invalid.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

3 participants