RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 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 "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". 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 "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-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.
Bug 1502831 - [RFE] Separating the OVAL into runtime and persistent checks
Summary: [RFE] Separating the OVAL into runtime and persistent checks
Keywords:
Status: CLOSED DUPLICATE of bug 1494606
Alias: None
Product: Red Hat Enterprise Linux 7
Classification: Red Hat
Component: scap-security-guide
Version: 7.4
Hardware: x86_64
OS: Linux
low
low
Target Milestone: rc
: ---
Assignee: Watson Yuuma Sato
QA Contact: BaseOS QE Security Team
URL:
Whiteboard:
Depends On:
Blocks: 1477664
TreeView+ depends on / blocked
 
Reported: 2017-10-16 19:54 UTC by Chinmay Paradkar
Modified: 2023-12-15 15:59 UTC (History)
3 users (show)

Fixed In Version:
Doc Type: Enhancement
Doc Text:
Clone Of:
Environment:
Last Closed: 2018-03-26 18:25:27 UTC
Target Upstream Version:
Embargoed:


Attachments (Terms of Use)

Description Chinmay Paradkar 2017-10-16 19:54:00 UTC
Description of problem:

The OVAL evaluates runtime and persistent configurations together. The
OVAL content currently does not evaluate for default values in the
sysctl config files -- it probably should.

Version-Release number of selected component (if applicable):
openscap-1.2.14-2.el7.x86_64

Additional info:

When doing a openscap validation of Title "Enable Randomized Layout of Virtual Address Space" we are getting a fail but it should be a pass result.  

Using the C2S openscap profile for RedHat 7 Linux, we are expected a PASS, but instead are getting a FAIL result code from the OpenScap scan. 

Title:  Enable Randomized Layout of Virtual Address Space
ID: content_rule_sysctl_kernel_randomize_va_space
TYPE:  xccdf:Rule

Looking at the actual system:

[root host ~]# sysctl -a | grep -i -e randomize
kernel.randomize_va_space = 2
sysctl: reading key "net.ipv6.conf.all.stable_secret"
sysctl: reading key "net.ipv6.conf.default.stable_secret"
sysctl: reading key "net.ipv6.conf.ens192.stable_secret"
sysctl: reading key "net.ipv6.conf.lo.stable_secret"
[root host ~]#

There is no entry in sysctl.conf that would override:
[root host ~]# grep -i -e randomize /etc/sysctl.conf
[root host ~]#

We would therefore expect a PASS.

Comment 3 Jan Černý 2017-10-17 07:47:16 UTC
The rule "Enable Randomized Layout of Virtual Address Space" checks both runtime state and configuration. The rule requires both checks to pass.

The runtime check reads 'kernel.randomize_va_space' paramater from sysctl and requires it to have value of 2.

The configuration check requires that kernel.randomize_va_space is set to 2 in at least one of configuration files in these paths /etc/sysctl.conf, /etc/sysctl.d/*.conf, /run/sysctl.d/*.conf, /usr/lib/sysctl.d/*.conf

One problem that I see is that value 2 is default, so people don't have to specify this parameter in their config files. I think we shouldn't check if it is set to 2 in configuration file, but we should check if somebody haven't explicitely changed the value to 0 or 1. See https://access.redhat.com/solutions/44460.

As you correctly pointed out, in this rule we mix runtime check with configuration checks. The problem that I see is that some other rules check only persistent configuration. I find this very confusing. We should define what the rules are supposed to check and be consistent across all rules in benchmarks.

Comment 4 Watson Yuuma Sato 2018-03-26 18:25:27 UTC
The reported problem is a duplicate of referenced bugzilla.

*** This bug has been marked as a duplicate of bug 1494606 ***


Note You need to log in before you can comment on or make changes to this bug.