Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
Red Hat Satellite engineering is moving the tracking of its product development work on Satellite to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "Satellite project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs will be migrated starting at the end of May. If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "Satellite project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/SAT-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
Created attachment 1843598[details]
Tailoring profile file: ssg-rhel7-ds-xccdf-tailoring.xml
Description of problem:
When you 'Edit' the Policy and select the 'XCCDF Profile in Tailoring File' it allows saving. But if you 'Edit' again it selects the first id, not the selected id.
Version-Release number of selected component (if applicable):
How reproducible:
1. Create a Tailoring Files
2. Create a new Policy
3. Edit the Policy and select a different tailoring profile
4. Check the selected tailoring profile again
Steps to Reproduce:
1. Create a Tailoring Files
-> Satellite WebUI
-> Hosts
-> Compliance
-> Tailoring Files
-> Upload New Tailoring file
-> Upload the file attached 'ssg-rhel7-ds-xccdf-tailoring.xml'
2. Create a new Policy
-> Satellite WebUI
-> Hosts
-> Compliance
-> Policies
-> New Compliance Policy
-> Deployment Options - Select: Ansible
-> Policy Attributes - Name: policy_test
-> SCAP Content:
SCAP Content: Red Hat rhel7 default content
XCCDF Profile: Default XCCDF profile
Tailoring File: ssg-rhel7-ds-xccdf-tailoring
XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - Minimal [CUSTOMIZED]
-> Schedule (any period):
Period: Weekly
Weekday: Sunday
-> Submit
* In 'Effective Profile', we can see: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - Minimal [CUSTOMIZED]
3. Edit the policy 'policy_test'
-> SCAP Content:
SCAP Content: Red Hat rhel7 default content
XCCDF Profile: Default XCCDF profile
Tailoring File: ssg-rhel7-ds-xccdf-tailoring
XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - WebServer [CUSTOMIZED] <-- Changed to WebServer (before Minimal)
* After the change, we can see in 'Effective Profile': CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - WebServer [CUSTOMIZED]
4. Edit the policy 'policy_test'
-> SCAP Content:
SCAP Content: Red Hat rhel7 default content
XCCDF Profile: Default XCCDF profile
Tailoring File: ssg-rhel7-ds-xccdf-tailoring
XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - Minimal [CUSTOMIZED] <-- Showing Minimal and should select WebServer
Actual results:
By default, it selects the first tailoring profile id, not the selected profile.
Expected results:
See the selected tailoring profile
Additional info:
Possible patch attached 'tailoring_profile_selected.patch'.
To apply it:
# patch -p0 /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_openscap-4.3.3/app/helpers/policies_helper.rb < tailoring_profile_selected.patch
FailedQA.
Version Tested: Satellite 7.0.0 Snap 7.0
Steps followed:
1. Create Tailoring Files
2. Create a new Policy
3. Edit the Policy and select a different tailoring profile
4. Check the selected tailoring profile again
Observation: Not able to see the selected tailoring file.
Tested with below:
XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - Minimal [CUSTOMIZED]
XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - WebServer [CUSTOMIZED]
Verified.
Tested on: Satellite-7.0.0 Snap 10.0
Steps followed:
1. Create Tailoring Files
2. Create a new Policy
3. Edit the Policy and select a different tailoring profile
4. Check the selected tailoring profile again
Observation: Able to see the correct selected tailoring file.
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.
For information on the advisory (Moderate: Satellite 6.11 Release), and where to find the updated
files, follow the link below.
If the solution does not work for you, open a new bug report.
https://access.redhat.com/errata/RHSA-2022:5498
Created attachment 1843598 [details] Tailoring profile file: ssg-rhel7-ds-xccdf-tailoring.xml Description of problem: When you 'Edit' the Policy and select the 'XCCDF Profile in Tailoring File' it allows saving. But if you 'Edit' again it selects the first id, not the selected id. Version-Release number of selected component (if applicable): How reproducible: 1. Create a Tailoring Files 2. Create a new Policy 3. Edit the Policy and select a different tailoring profile 4. Check the selected tailoring profile again Steps to Reproduce: 1. Create a Tailoring Files -> Satellite WebUI -> Hosts -> Compliance -> Tailoring Files -> Upload New Tailoring file -> Upload the file attached 'ssg-rhel7-ds-xccdf-tailoring.xml' 2. Create a new Policy -> Satellite WebUI -> Hosts -> Compliance -> Policies -> New Compliance Policy -> Deployment Options - Select: Ansible -> Policy Attributes - Name: policy_test -> SCAP Content: SCAP Content: Red Hat rhel7 default content XCCDF Profile: Default XCCDF profile Tailoring File: ssg-rhel7-ds-xccdf-tailoring XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - Minimal [CUSTOMIZED] -> Schedule (any period): Period: Weekly Weekday: Sunday -> Submit * In 'Effective Profile', we can see: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - Minimal [CUSTOMIZED] 3. Edit the policy 'policy_test' -> SCAP Content: SCAP Content: Red Hat rhel7 default content XCCDF Profile: Default XCCDF profile Tailoring File: ssg-rhel7-ds-xccdf-tailoring XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - WebServer [CUSTOMIZED] <-- Changed to WebServer (before Minimal) * After the change, we can see in 'Effective Profile': CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - WebServer [CUSTOMIZED] 4. Edit the policy 'policy_test' -> SCAP Content: SCAP Content: Red Hat rhel7 default content XCCDF Profile: Default XCCDF profile Tailoring File: ssg-rhel7-ds-xccdf-tailoring XCCDF Profile in Tailoring File: CIS Red Hat Enterprise Linux 7 Benchmark for Level 1 - Minimal [CUSTOMIZED] <-- Showing Minimal and should select WebServer Actual results: By default, it selects the first tailoring profile id, not the selected profile. Expected results: See the selected tailoring profile Additional info: Possible patch attached 'tailoring_profile_selected.patch'. To apply it: # patch -p0 /opt/theforeman/tfm/root/usr/share/gems/gems/foreman_openscap-4.3.3/app/helpers/policies_helper.rb < tailoring_profile_selected.patch