Giter Club home page Giter Club logo

ansible-role-rhel6stig's Introduction

RHEL 6 DISA STIG

Galaxy

Configure RHEL 6 to be DISA STIG compliant. CAT I findings will be corrected by default. CAT II and CAT III findings can be corrected by setting the appropriate variable to enable those tasks.

Not all findings can be remediated automatically, or they require more complex automation specific to your environment in order to be remediated appropriately. See tasks/not_automated.yml for these findings.

This role will make changes to the system that could break things. This is not an auditing tool but rather a remediation tool to be used after an audit has been conducted, though auditing functionality is in the works.

IMPORTANT INSTALL STEP

To install this role with ansible-galaxy use the following command:

ansible-galaxy install -p roles nousdefions.STIG-RHEL6,devel

Based on Red Hat Enterprise Linux 6 STIG Version 1 Release 6 - 2015-01-23.

This repo originated from work done by Sam Doran

Requirements

You should have a general understanding of the nature of the changes this role will make to the system. See the DISA IASE site for details[1].

Role Variables

There are many role variables defined in defaults/main.yml. Here are the most important ones. Feel free to look through defaults/main.yml to see what other configuration options are available.

Name Default Value Description
rhel6stig_cat1 yes Correct CAT I findings
rhel6stig_cat2 no Correct CAT II findings
rhel6stig_cat3 no Correct CAT III findings
rhel6stig_use_dhcp yes Whether the system should use DHCP or Static IPs.
rhel6stig_system_is_router no Whether on not the target system is acting as a router. Disables settings that would break the system if it is a acting as a router
rhel6stig_root_email_address [email protected] Address where system email is sent.
rhel6stig_xwindows_required no Whether or not X Windows is is use on taregt systems. Disables some changes if X Windows is not in use.
rhel6stig_ipv6_in_use no Whether or not ipv6 is in use of the target system. This is set automatically to 'yes' if ipv6 is found to be in use. (Default: false)
rhel6stig_tftp_required no Whether or not TFTP is required. If set to yes, this will prevent the removal of tftp and tftp-server packages. It will also reconfigure the tftp-server to run securely.
rhel6stig_rhnsatellite_required no Whether or not Red Hat Satellite is required in the environment. If not required, rhnsd will be stopped and disabled.
rhel6stig_bootloader_password [Randomly generated and encrypted string] The new grub password to use if rhel6stig_change_grub_password is True
rhel6stig_update_all_packages yes Whether to install all system updates.

Dependencies

None.

Example Playbooks

Correct CAT I and CAT II findings but don't apply all updates.

- hosts: all
  become: yes

  vars:
    rhel6stig_update_all_packages: no

  roles:
    - { role: nousdefions.STIG-RHEL6,
        rhel6stig_cat1: yes,
        rhel6stig_cat2: yes,
        rhel6stig_cat3: no
      }

Prompt for the GRUB password.

- hosts: servers
  become: yes

  vars:
    rhel6stig_update_all_packages: no

  vars:
    rhel6stig_cat1: yes
    rhel6stig_cat2: yes
    rhel6stig_cat3: no

  vars_prompt:
    name: "rhel6stig_bootloader_password"
    prompt: "Enter the bootloader password: "
    private: yes
    confirm: yes

  roles:
     - role: nousdefions.STIG-RHEL6

Tags

Each task is tagged with its category, severity, whether or not it is a patch or audit task, and the finding ID, e.g., V-38462. In addition to these four basic tags that all tasks have, there are human-friendly tags such as "ssh" or "dod_logon_banner".

A number of prilimary tasks that do things such as enumerate services on the system and check for the existence of various file will always run unless explicitly skipped by using --skip tags prelim_tasks.

Some examples of using tags:

# Only remediate ssh
ansible-playbook site.yml --tags ssh

# Don't change SNMP or postfix
ansible-playbook site.yml --skip-tags postfix,mail,snmp

License

MIT

1: A web based STIG viewer is available here. They are not associated in any way with DISA but have provided a useful tool for viewing the STIGs.

ansible-role-rhel6stig's People

Contributors

bbaassssiiee avatar clasohm avatar jtyr avatar nydr avatar samdoran avatar shepdelacreme avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.