Blame SOURCES/scap-security-guide-0.1.51-add_hipaa_kickstarts_PR_5783.patch

475544
From b23fc7fe3244128940f7b1f79ad4cde13d7b62eb Mon Sep 17 00:00:00 2001
475544
From: Vojtech Polasek <vpolasek@redhat.com>
475544
Date: Mon, 25 May 2020 12:17:48 +0200
475544
Subject: [PATCH] add hipaa kickstarts for rhel7 and rhel8
475544
475544
---
475544
 rhel7/kickstart/ssg-rhel7-hipaa-ks.cfg | 125 +++++++++++++++++++++++++
475544
 rhel8/kickstart/ssg-rhel8-hipaa-ks.cfg | 125 +++++++++++++++++++++++++
475544
 2 files changed, 250 insertions(+)
475544
 create mode 100644 rhel7/kickstart/ssg-rhel7-hipaa-ks.cfg
475544
 create mode 100644 rhel8/kickstart/ssg-rhel8-hipaa-ks.cfg
475544
475544
diff --git a/rhel7/kickstart/ssg-rhel7-hipaa-ks.cfg b/rhel7/kickstart/ssg-rhel7-hipaa-ks.cfg
475544
new file mode 100644
475544
index 0000000000..14c82c4231
475544
--- /dev/null
475544
+++ b/rhel7/kickstart/ssg-rhel7-hipaa-ks.cfg
475544
@@ -0,0 +1,125 @@
475544
+# SCAP Security Guide HIPAA profile kickstart for Red Hat Enterprise Linux 7 Server
475544
+# Version: 0.0.1
475544
+# Date: 2020-05-25
475544
+#
475544
+# Based on:
475544
+# http://fedoraproject.org/wiki/Anaconda/Kickstart
475544
+# https://access.redhat.com/documentation/en-US/Red_Hat_Enterprise_Linux/7/html/Installation_Guide/sect-kickstart-syntax.html
475544
+
475544
+# Install a fresh new system (optional)
475544
+install
475544
+
475544
+# Specify installation method to use for installation
475544
+# To use a different one comment out the 'url' one below, update
475544
+# the selected choice with proper options & un-comment it
475544
+#
475544
+# Install from an installation tree on a remote server via FTP or HTTP:
475544
+# --url		the URL to install from
475544
+#
475544
+# Example:
475544
+#
475544
+# url --url=http://192.168.122.1/image
475544
+#
475544
+# Modify concrete URL in the above example appropriately to reflect the actual
475544
+# environment machine is to be installed in
475544
+#
475544
+# Other possible / supported installation methods:
475544
+# * install from the first CD-ROM/DVD drive on the system:
475544
+#
475544
+# cdrom
475544
+#
475544
+# * install from a directory of ISO images on a local drive:
475544
+#
475544
+# harddrive --partition=hdb2 --dir=/tmp/install-tree
475544
+#
475544
+# * install from provided NFS server:
475544
+#
475544
+# nfs --server=<hostname> --dir=<directory> [--opts=<nfs options>]
475544
+#
475544
+
475544
+# Set language to use during installation and the default language to use on the installed system (required)
475544
+lang en_US.UTF-8
475544
+
475544
+# Set system keyboard type / layout (required)
475544
+keyboard us
475544
+
475544
+# Configure network information for target system and activate network devices in the installer environment (optional)
475544
+# --onboot	enable device at a boot time
475544
+# --device	device to be activated and / or configured with the network command
475544
+# --bootproto	method to obtain networking configuration for device (default dhcp)
475544
+# --noipv6	disable IPv6 on this device
475544
+#
475544
+# NOTE: Usage of DHCP will fail CCE-27021-5 (DISA FSO RHEL-06-000292). To use static IP configuration,
475544
+#       "--bootproto=static" must be used. For example:
475544
+# network --bootproto=static --ip=10.0.2.15 --netmask=255.255.255.0 --gateway=10.0.2.254 --nameserver 192.168.2.1,192.168.3.1
475544
+#
475544
+network --onboot yes --device eth0 --bootproto dhcp --noipv6
475544
+
475544
+# Set the system's root password (required)
475544
+# Plaintext password is: server
475544
+# Refer to e.g. http://fedoraproject.org/wiki/Anaconda/Kickstart#rootpw to see how to create
475544
+# encrypted password form for different plaintext password
475544
+rootpw --iscrypted $6$rhel6usgcb$aS6oPGXcPKp3OtFArSrhRwu6sN8q2.yEGY7AIwDOQd23YCtiz9c5mXbid1BzX9bmXTEZi.hCzTEXFosVBI5ng0
475544
+
475544
+# The selected profile will restrict root login
475544
+# Add a user that can login and escalate privileges
475544
+# Plaintext password is: admin123
475544
+user --name=admin --groups=wheel --password=$6$Ga6ZnIlytrWpuCzO$q0LqT1USHpahzUafQM9jyHCY9BiE5/ahXLNWUMiVQnFGblu0WWGZ1e6icTaCGO4GNgZNtspp1Let/qpM7FMVB0 --iscrypted
475544
+
475544
+# Configure firewall settings for the system (optional)
475544
+# --enabled	reject incoming connections that are not in response to outbound requests
475544
+# --ssh		allow sshd service through the firewall
475544
+firewall --enabled --ssh
475544
+
475544
+# Set up the authentication options for the system (required)
475544
+# --enableshadow	enable shadowed passwords by default
475544
+# --passalgo		hash / crypt algorithm for new passwords
475544
+# See the manual page for authconfig for a complete list of possible options.
475544
+authconfig --enableshadow --passalgo=sha512
475544
+
475544
+# State of SELinux on the installed system (optional)
475544
+# Defaults to enforcing
475544
+selinux --enforcing
475544
+
475544
+# Set the system time zone (required)
475544
+timezone --utc America/New_York
475544
+
475544
+# Specify how the bootloader should be installed (required)
475544
+# Plaintext password is: password
475544
+# Refer to e.g. http://fedoraproject.org/wiki/Anaconda/Kickstart#rootpw to see how to create
475544
+# encrypted password form for different plaintext password
475544
+bootloader --location=mbr --append="crashkernel=auto rhgb quiet" --password=$6$rhel6usgcb$kOzIfC4zLbuo3ECp1er99NRYikN419wxYMmons8Vm/37Qtg0T8aB9dKxHwqapz8wWAFuVkuI/UJqQBU92bA5C0
475544
+
475544
+# Initialize (format) all disks (optional)
475544
+zerombr
475544
+
475544
+# The following partition layout scheme assumes disk of size 20GB or larger
475544
+# Modify size of partitions appropriately to reflect actual machine's hardware
475544
+#
475544
+# Remove Linux partitions from the system prior to creating new ones (optional)
475544
+# --linux	erase all Linux partitions
475544
+# --initlabel	initialize the disk label to the default based on the underlying architecture
475544
+clearpart --linux --initlabel
475544
+
475544
+# Create primary system partitions (required for installs)
475544
+autopart
475544
+
475544
+# Harden installation with HIPAA profile
475544
+# For more details and configuration options see command %addon org_fedora_oscap in
475544
+# https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/7/html/installation_guide/sect-kickstart-syntax#sect-kickstart-commands
475544
+%addon org_fedora_oscap
475544
+        content-type = scap-security-guide
475544
+        profile = xccdf_org.ssgproject.content_profile_hipaa
475544
+%end
475544
+
475544
+# Packages selection (%packages section is required)
475544
+%packages
475544
+
475544
+# Require @Base
475544
+@Base
475544
+
475544
+%end # End of %packages section
475544
+
475544
+# Reboot after the installation is complete (optional)
475544
+# --eject	attempt to eject CD or DVD media before rebooting
475544
+reboot --eject
475544
diff --git a/rhel8/kickstart/ssg-rhel8-hipaa-ks.cfg b/rhel8/kickstart/ssg-rhel8-hipaa-ks.cfg
475544
new file mode 100644
475544
index 0000000000..861db36f18
475544
--- /dev/null
475544
+++ b/rhel8/kickstart/ssg-rhel8-hipaa-ks.cfg
475544
@@ -0,0 +1,125 @@
475544
+# SCAP Security Guide HIPAA profile kickstart for Red Hat Enterprise Linux 8 Server
475544
+# Version: 0.0.1
475544
+# Date: 2020-05-25
475544
+#
475544
+# Based on:
475544
+# http://fedoraproject.org/wiki/Anaconda/Kickstart
475544
+# https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/performing_an_advanced_rhel_installation/index#performing_an_automated_installation_using_kickstart
475544
+
475544
+# Install a fresh new system (optional)
475544
+install
475544
+
475544
+# Specify installation method to use for installation
475544
+# To use a different one comment out the 'url' one below, update
475544
+# the selected choice with proper options & un-comment it
475544
+#
475544
+# Install from an installation tree on a remote server via FTP or HTTP:
475544
+# --url		the URL to install from
475544
+#
475544
+# Example:
475544
+#
475544
+# url --url=http://192.168.122.1/image
475544
+#
475544
+# Modify concrete URL in the above example appropriately to reflect the actual
475544
+# environment machine is to be installed in
475544
+#
475544
+# Other possible / supported installation methods:
475544
+# * install from the first CD-ROM/DVD drive on the system:
475544
+#
475544
+# cdrom
475544
+#
475544
+# * install from a directory of ISO images on a local drive:
475544
+#
475544
+# harddrive --partition=hdb2 --dir=/tmp/install-tree
475544
+#
475544
+# * install from provided NFS server:
475544
+#
475544
+# nfs --server=<hostname> --dir=<directory> [--opts=<nfs options>]
475544
+#
475544
+
475544
+# Set language to use during installation and the default language to use on the installed system (required)
475544
+lang en_US.UTF-8
475544
+
475544
+# Set system keyboard type / layout (required)
475544
+keyboard us
475544
+
475544
+# Configure network information for target system and activate network devices in the installer environment (optional)
475544
+# --onboot	enable device at a boot time
475544
+# --device	device to be activated and / or configured with the network command
475544
+# --bootproto	method to obtain networking configuration for device (default dhcp)
475544
+# --noipv6	disable IPv6 on this device
475544
+#
475544
+# NOTE: Usage of DHCP will fail CCE-27021-5 (DISA FSO RHEL-06-000292). To use static IP configuration,
475544
+#       "--bootproto=static" must be used. For example:
475544
+# network --bootproto=static --ip=10.0.2.15 --netmask=255.255.255.0 --gateway=10.0.2.254 --nameserver 192.168.2.1,192.168.3.1
475544
+#
475544
+network --onboot yes --device eth0 --bootproto dhcp --noipv6
475544
+
475544
+# Set the system's root password (required)
475544
+# Plaintext password is: server
475544
+# Refer to e.g. http://fedoraproject.org/wiki/Anaconda/Kickstart#rootpw to see how to create
475544
+# encrypted password form for different plaintext password
475544
+rootpw --iscrypted $6$rhel6usgcb$aS6oPGXcPKp3OtFArSrhRwu6sN8q2.yEGY7AIwDOQd23YCtiz9c5mXbid1BzX9bmXTEZi.hCzTEXFosVBI5ng0
475544
+
475544
+# The selected profile will restrict root login
475544
+# Add a user that can login and escalate privileges
475544
+# Plaintext password is: admin123
475544
+user --name=admin --groups=wheel --password=$6$Ga6ZnIlytrWpuCzO$q0LqT1USHpahzUafQM9jyHCY9BiE5/ahXLNWUMiVQnFGblu0WWGZ1e6icTaCGO4GNgZNtspp1Let/qpM7FMVB0 --iscrypted
475544
+
475544
+# Configure firewall settings for the system (optional)
475544
+# --enabled	reject incoming connections that are not in response to outbound requests
475544
+# --ssh		allow sshd service through the firewall
475544
+firewall --enabled --ssh
475544
+
475544
+# Set up the authentication options for the system (required)
475544
+# sssd profile sets sha512 to hash passwords
475544
+# passwords are shadowed by default
475544
+# See the manual page for authselect-profile for a complete list of possible options.
475544
+authselect select sssd
475544
+
475544
+# State of SELinux on the installed system (optional)
475544
+# Defaults to enforcing
475544
+selinux --enforcing
475544
+
475544
+# Set the system time zone (required)
475544
+timezone --utc America/New_York
475544
+
475544
+# Specify how the bootloader should be installed (required)
475544
+# Plaintext password is: password
475544
+# Refer to e.g. http://fedoraproject.org/wiki/Anaconda/Kickstart#rootpw to see how to create
475544
+# encrypted password form for different plaintext password
475544
+bootloader --location=mbr --append="crashkernel=auto rhgb quiet" --password=$6$rhel6usgcb$kOzIfC4zLbuo3ECp1er99NRYikN419wxYMmons8Vm/37Qtg0T8aB9dKxHwqapz8wWAFuVkuI/UJqQBU92bA5C0
475544
+
475544
+# Initialize (format) all disks (optional)
475544
+zerombr
475544
+
475544
+# The following partition layout scheme assumes disk of size 20GB or larger
475544
+# Modify size of partitions appropriately to reflect actual machine's hardware
475544
+# 
475544
+# Remove Linux partitions from the system prior to creating new ones (optional)
475544
+# --linux	erase all Linux partitions
475544
+# --initlabel	initialize the disk label to the default based on the underlying architecture
475544
+clearpart --linux --initlabel
475544
+
475544
+# Create primary system partitions (required for installs)
475544
+autopart
475544
+
475544
+# Harden installation with HIPAA profile
475544
+# For more details and configuration options see
475544
+# https://access.redhat.com/documentation/en-us/red_hat_enterprise_linux/8/html-single/performing_an_advanced_rhel_installation/index#addon-org_fedora_oscap_kickstart-commands-for-addons-supplied-with-the-rhel-installation-program
475544
+%addon org_fedora_oscap
475544
+        content-type = scap-security-guide
475544
+        profile = xccdf_org.ssgproject.content_profile_hipaa
475544
+%end
475544
+
475544
+# Packages selection (%packages section is required)
475544
+%packages
475544
+
475544
+# Require @Base
475544
+@Base
475544
+
475544
+%end # End of %packages section
475544
+
475544
+# Reboot after the installation is complete (optional)
475544
+# --eject	attempt to eject CD or DVD media before rebooting
475544
+reboot --eject