{"id":28405952,"url":"https://github.com/ansible-lockdown/rhel8-stig-audit","last_synced_at":"2025-06-29T07:32:24.900Z","repository":{"id":39993150,"uuid":"385935840","full_name":"ansible-lockdown/RHEL8-STIG-Audit","owner":"ansible-lockdown","description":"Automated STIG Benchmark Compliance Audit for RHEL 8 with Ansible \u0026 GOSS","archived":false,"fork":false,"pushed_at":"2025-05-23T16:07:23.000Z","size":866,"stargazers_count":12,"open_issues_count":0,"forks_count":5,"subscribers_count":4,"default_branch":"devel","last_synced_at":"2025-06-02T07:13:22.885Z","etag":null,"topics":["ansible","ansible-playbook","ansible-role","automation","configuration-management","cybersecurity","enterprise-hardening","it-compliance","linux-hardening","rhel-8-hardening","rhel-security","rhel8","secure-baseline","secure-configuration","stig","stig-benchmark","stig-compliance","stig-hardening","stig-security","system-hardening"],"latest_commit_sha":null,"homepage":"https://www.lockdownenterprise.com","language":"YAML","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"mit","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/ansible-lockdown.png","metadata":{"files":{"readme":"README.md","changelog":"Changelog.MD","contributing":"CONTRIBUTING.rst","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":"docs/Security_remediation_and_auditing.md","support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null}},"created_at":"2021-07-14T12:40:46.000Z","updated_at":"2025-04-22T14:33:22.000Z","dependencies_parsed_at":"2024-04-30T11:11:36.454Z","dependency_job_id":"550df2c7-aaba-447b-aabd-b0cf362d3abb","html_url":"https://github.com/ansible-lockdown/RHEL8-STIG-Audit","commit_stats":null,"previous_names":[],"tags_count":5,"template":false,"template_full_name":null,"purl":"pkg:github/ansible-lockdown/RHEL8-STIG-Audit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ansible-lockdown%2FRHEL8-STIG-Audit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ansible-lockdown%2FRHEL8-STIG-Audit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ansible-lockdown%2FRHEL8-STIG-Audit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ansible-lockdown%2FRHEL8-STIG-Audit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/ansible-lockdown","download_url":"https://codeload.github.com/ansible-lockdown/RHEL8-STIG-Audit/tar.gz/refs/heads/devel","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/ansible-lockdown%2FRHEL8-STIG-Audit/sbom","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":262556828,"owners_count":23328177,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["ansible","ansible-playbook","ansible-role","automation","configuration-management","cybersecurity","enterprise-hardening","it-compliance","linux-hardening","rhel-8-hardening","rhel-security","rhel8","secure-baseline","secure-configuration","stig","stig-benchmark","stig-compliance","stig-hardening","stig-security","system-hardening"],"created_at":"2025-06-01T22:09:38.320Z","updated_at":"2025-06-29T07:32:24.894Z","avatar_url":"https://github.com/ansible-lockdown.png","language":"YAML","funding_links":[],"categories":[],"sub_categories":[],"readme":"# RHEL/CentOS 8 Goss config\n\n## Overview\n\nbased on STIG v1r13 24th Jan 2024\n\nAbility to audit a system using a lightweight binary to check the current state.\n\nThis is:\n\n- very small 11MB\n- lightweight\n- self contained\n\nIt works using a set of configuration files and directories to audit STIG of RHEL/CentOS 7 servers. These files/directories correlate to the STIG Level and STIG_ID\n\nTested on\n\n- RHEL8\n- CentOS8\n- Rocky8\n- Alma-Linux 8\n\nfeedback on any differences between OSs please raise an issue\n\n## Join us\n\nOn our [Discord Server](https://discord.io/ansible-lockdown) to ask questions, discuss features, or just chat with other Ansible-Lockdown users\n\n## Requirements\n\nYou must have [goss](https://github.com/goss-org/goss/) available to your host you would like to test.\n\nYou must have sudo/root access to the system as some commands require privilege information.\n\nAssuming you have already clone this repository you can run goss from where you wish.\n\nPlease refer to the audit documentation for usage.\n\n- [Audit Documents](https://ansible-lockdown.readthedocs.io/en/latest/audit/getting-started-audit.html)\n\nThis also works alongside the [Ansible Lockdown RHEL8-STIG role](https://github.com/ansible-lockdown/RHEL8-STIG)\n\nWhich will:\n\n- install\n- audit\n- remediate\n- audit\n\n## variables\n\nThese are found in vars/STIG.yml\nPlease refer to the file for all options and their meanings\n\nSTIG listed variable for every control/benchmark can be turned on/off or section\n\n### The variable files\n\nIn this case installed or skipped using the standard name for a package to be installed or _skip to skip a test.\n\n### Extra settings\n\nSome sections can have several options in that case the skip flag maybe passed to the test or exact details relating to your requirements\ne.g.\n\n- rhel7stig_use_gui\n- rhel7stig_is_router\n- rhel7_stig_nameservers:\n  - 8.8.8.8\n  - 9.9.9.9\n\n## Examples\n\n- full check\n\n```sh\n\n# {{path to your goss binary}} --vars {{ path to the vars file }} -g {{path to your clone of this repo }}/goss.yml v\n\n```\n\n- example:\n\n```sh\n# /usr/local/bin/goss --vars ../vars/stig.yml -g /home/bolly/rh7_cis_goss/goss.yml validate\n......FF....FF................FF...F..FF.............F........................FSSSS.............FS.F.F.F.F.........FFFFF....\n\nFailures/Skipped:\n\nTitle: CAT_2 | RHEL-07-040641 | Must ignore Internet Protocol version 4 (IPv4) Internet Control Message Protocol (ICMP) redirect messages from being accepted.\nKernelParam: net.ipv4.conf.all.accept_redirects: value:\nExpected\n    \u003cstring\u003e: 1\nto equal\n    \u003cstring\u003e: 0\n\nTitle: CAT_2 | RHEL-07-021000 | Must prevent files with the setuid and setgid bit set from being executed on file systems that are used with removable media.\nMount: /mnt: exists:\nExpected\n    \u003cbool\u003e: false\nto equal\n    \u003cbool\u003e: true\n\n\u003c ---------cut ------- \u003e\n\nTitle: CAT_2 | RHEL-07-010280 | Must be configured so that passwords are a minimum of 15 characters in length.\nFile: /etc/security/pwquality.conf: contents: patterns not found: [/^minlen = 15/]\n\nTitle: CAT_2 | RHEL-07-040500 | Must for networked systems, synchronize clocks with a server that is synchronized to one of the redundant United States Naval Observatory (USNO) time servers, a time server designated for the appropriate DoD network (NIPRNet/SIPRNet), and/or the Global Positioning System (GPS).\nFile: /etc/chrony.conf: contents: patterns not found: [/^server.*maxpoll 10/]\n\nTitle: CAT_2 | RHEL-07-010310 | Must disable account identifiers (individuals, groups, roles, and devices) if the password expires.\nFile: /etc/default/useradd: contents: patterns not found: [/^INACTIVE=0/]\n\nTotal Duration: 31.127s\nCount: 308, Failed: 162, Skipped: 21\n```\n\n- running a particular section of tests\n\n```sh\n# /usr/local/bin/goss -g /home/bolly/rh7_cis_goss/section_1/cis_1.1/cis_1.1.22.yml  validate\n............\n\nTotal Duration: 0.033s\nCount: 12, Failed: 0, Skipped: 0\n```\n\n- changing the output\n\n```sh\n# /usr/local/bin/goss -g /home/bolly/rh7_stig_goss/Cat_2/RHEL-07-010030.yml  validate -f documentation\ngoss -g Cat_2/RHEL-07-020240.yml  --vars vars/stig.yml v -f documentation\nTitle: CAT_2 | RHEL-07-020240 | Must define default permissions for all authenticated users in such a way that the user can only read and modify their own files.\nFile: /etc/login.defs: exists: matches expectation: [true]\nFile: /etc/login.defs: mode: matches expectation: [\"0644\"]\nFile: /etc/login.defs: contents: patterns not found: [/^UMASK 077]\n\n\nFailures/Skipped:\n\nTitle: CAT_2 | RHEL-07-020240 | Must define default permissions for all authenticated users in such a way that the user can only read and modify their own files.\nFile: /etc/login.defs: contents: patterns not found: [/^UMASK 077]\n\nTotal Duration: 0.000s\nCount: 3, Failed: 1, Skipped: 0\n```\n\n## further information\n\n- [goss documentation](https://github.com/aelsabbahy/goss/blob/master/docs/manual.md#patterns)\n- [STIG standards](https://public.cyber.mil/stigs/)\n\n## Feedback required\n\n- If using nftables or iptables rather than firewalld\n- RHEL-08-010020 FIPS crypto with ec2 has seen to fail with cert issues.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fansible-lockdown%2Frhel8-stig-audit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fansible-lockdown%2Frhel8-stig-audit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fansible-lockdown%2Frhel8-stig-audit/lists"}