{"id":27063657,"url":"https://github.com/dev-sec/ansible-os-hardening","last_synced_at":"2025-04-05T16:01:55.977Z","repository":{"id":31487678,"uuid":"35051828","full_name":"dev-sec/ansible-collection-hardening","owner":"dev-sec","description":"This Ansible collection provides battle tested hardening for Linux, SSH, nginx, MySQL","archived":false,"fork":false,"pushed_at":"2024-10-24T16:43:44.000Z","size":2292,"stargazers_count":4006,"open_issues_count":50,"forks_count":728,"subscribers_count":116,"default_branch":"master","last_synced_at":"2024-10-29T14:55:53.090Z","etag":null,"topics":["ansible","ansible-collection","collection","devsec","hacktoberfest","hardening","linux","mysql-hardening","nginx","nginx-hardening","os-hardening","playbook","protection","role","ssh-hardening","sysctl"],"latest_commit_sha":null,"homepage":"http://dev-sec.io/","language":"Jinja","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"apache-2.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/dev-sec.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2015-05-04T18:26:56.000Z","updated_at":"2024-10-29T11:02:39.000Z","dependencies_parsed_at":"2024-01-15T15:40:45.197Z","dependency_job_id":"9b25899c-0ba9-443f-86cc-de2468c3881e","html_url":"https://github.com/dev-sec/ansible-collection-hardening","commit_stats":null,"previous_names":["dev-sec/ansible-os-hardening"],"tags_count":57,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-sec%2Fansible-collection-hardening","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-sec%2Fansible-collection-hardening/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-sec%2Fansible-collection-hardening/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/dev-sec%2Fansible-collection-hardening/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/dev-sec","download_url":"https://codeload.github.com/dev-sec/ansible-collection-hardening/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":247361593,"owners_count":20926641,"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-collection","collection","devsec","hacktoberfest","hardening","linux","mysql-hardening","nginx","nginx-hardening","os-hardening","playbook","protection","role","ssh-hardening","sysctl"],"created_at":"2025-04-05T16:01:54.948Z","updated_at":"2025-04-05T16:01:55.921Z","avatar_url":"https://github.com/dev-sec.png","language":"Jinja","funding_links":[],"categories":["DevOps","HTML","Roles","role"],"sub_categories":["Development"],"readme":"# Ansible Collection - devsec.hardening\n\n[![devsec.os_hardening](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/os_hardening.yml/badge.svg)](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/os_hardening.yml)\n[![devsec.os_hardening VM](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/os_hardening_vm.yml/badge.svg)](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/os_hardening_vm.yml)\n[![devsec.ssh_hardening](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/ssh_hardening.yml/badge.svg)](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/ssh_hardening.yml)\n[![devsec.ssh_hardening BSD](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/ssh_hardening_bsd.yml/badge.svg)](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/ssh_hardening_bsd.yml)\n[![devsec.ssh_hardening with custom tests](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/ssh_hardening_custom_tests.yml/badge.svg)](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/ssh_hardening_custom_tests.yml)\n[![devsec.nginx_hardening](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/nginx_hardening.yml/badge.svg)](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/nginx_hardening.yml)\n[![devsec.mysql_hardening](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/mysql_hardening.yml/badge.svg)](https://github.com/dev-sec/ansible-collection-hardening/actions/workflows/mysql_hardening.yml)\n\n## Description\n\nThis collection provides battle tested hardening for:\n\n- Linux operating systems:\n  - CentOS 9\n  - Rocky Linux 8/9\n  - Debian 11/12\n  - Ubuntu 20.04/22.04/24.04\n  - Amazon Linux (some roles supported)\n  - Arch Linux (some roles supported)\n  - Fedora 39/40 (some roles supported)\n  - Suse Tumbleweed (some roles supported)\n- MySQL\n  - MariaDB \u003e= 5.5.65, \u003e= 10.1.45, \u003e= 10.3.17\n  - MySQL \u003e= 5.7.31, \u003e= 8.0.3\n- Nginx 1.0.16 or later\n- OpenSSH 5.3 and later\n\nThe hardening is intended to be compliant with the Inspec DevSec Baselines:\n\n- \u003chttps://github.com/dev-sec/linux-baseline\u003e\n- \u003chttps://github.com/dev-sec/mysql-baseline\u003e\n- \u003chttps://github.com/dev-sec/nginx-baseline\u003e\n- \u003chttps://github.com/dev-sec/ssh-baseline\u003e\n\n## Looking for the old roles?\n\nThe roles are now part of the hardening-collection.\nWe have kept the old releases of the `os-hardening` role in this repository, so you can find the them by exploring older tags.\nThe last release of the standalone role was [6.2.0](https://github.com/dev-sec/ansible-collection-hardening/tree/6.2.0).\n\nThe other roles are in separate archives repositories:\n\n- [apache_hardening](https://github.com/dev-sec/ansible-apache-hardening)\n- [mysql_hardening](https://github.com/dev-sec/ansible-mysql-hardening)\n- [nginx_hardening](https://github.com/dev-sec/ansible-nginx-hardening)\n- [ssh_hardening](https://github.com/dev-sec/ansible-ssh-hardening)\n- [windows_hardening](https://github.com/dev-sec/ansible-windows-hardening)\n\n## Minimum required Ansible-version\n\n- Ansible \u003e= 2.9.10\n\n## Included content\n\n- [os_hardening](roles/os_hardening/)\n- [mysql_hardening](roles/mysql_hardening/)\n- [nginx_hardening](roles/nginx_hardening/)\n- [ssh_hardening](roles/ssh_hardening/)\n\nIn progress, not working:\n\n- [apache_hardening](roles/apache_hardening/)\n- [windows_hardening](roles/windows_hardening/)\n\n## Installation\n\nInstall the collection via ansible-galaxy:\n\n`ansible-galaxy collection install devsec.hardening`\n\n## Using this collection\n\nPlease refer to the examples in the readmes of the role.\n\nSee [Ansible Using collections](https://docs.ansible.com/ansible/latest/user_guide/collections_using.html) for more details.\n\n## Contributing to this collection\n\nSee the [contributor guideline](CONTRIBUTING.md).\n\n## Release notes\n\nSee the [changelog](https://github.com/dev-sec/ansible-os-hardening/tree/master/CHANGELOG.md).\n\n## Roadmap\n\nTodos:\n\n- Work on [apache_hardening](roles/apache_hardening/) and [windows_hardening](roles/windows_hardening/)\n- Add support for more operating systems\n\n## More information\n\nGeneral information:\n\n- [Ansible Collection overview](https://github.com/ansible-collections/overview)\n- [Ansible User guide](https://docs.ansible.com/ansible/latest/user_guide/index.html)\n- [Ansible Developer guide](https://docs.ansible.com/ansible/latest/dev_guide/index.html)\n- [Ansible Collections Checklist](https://github.com/ansible-collections/overview/blob/master/collection_requirements.rst)\n- [Ansible Community code of conduct](https://docs.ansible.com/ansible/latest/community/code_of_conduct.html)\n- [The Bullhorn (the Ansible Contributor newsletter)](https://us19.campaign-archive.com/home/?u=56d874e027110e35dea0e03c1\u0026id=d6635f5420)\n- [Changes impacting Contributors](https://github.com/ansible-collections/overview/issues/45)\n\n## Licensing\n\nLicensed under the Apache License, Version 2.0 (the \"License\"); you may not use this file except in compliance with the License. You may obtain a copy of the License at\n\n\u003chttp://www.apache.org/licenses/LICENSE-2.0\u003e\n\nUnless required by applicable law or agreed to in writing, software distributed under the License is distributed on an \"AS IS\" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions and limitations under the License.\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-sec%2Fansible-os-hardening","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fdev-sec%2Fansible-os-hardening","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fdev-sec%2Fansible-os-hardening/lists"}