Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Removal of config disclaimer attribute #249

Merged
merged 1 commit into from Apr 10, 2019
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 0 additions & 2 deletions attributes/default.rb
Expand Up @@ -21,8 +21,6 @@

# rubocop:disable Metrics/BlockLength

default['config_disclaimer'] = '**Note:** This file was automatically created by dev-sec.io os-hardening configuration. If you use its automated setup, do not edit this file directly, but adjust the automation instead.'

default['os-hardening'].tap do |os_hardening|
# components of this cookbook
%w[packages limits login_defs minimize_access pam profile securetty].each do |cp|
Expand Down
8 changes: 4 additions & 4 deletions templates/default/filesystem_blacklisting.erb
@@ -1,8 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#
#--
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

<% @filesystems.each do |fs| %>
install <%= fs %> /bin/true
Expand Down
10 changes: 5 additions & 5 deletions templates/default/limits.conf.erb
@@ -1,8 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#
#--
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

# Prevent core dumps for all users. These are usually only needed by developers and may contain sensitive information.
* hard core 0
9 changes: 5 additions & 4 deletions templates/default/login.defs.erb
@@ -1,7 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#---
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

# Configuration control definitions for the login package.
#
Expand Down
9 changes: 5 additions & 4 deletions templates/default/modules.erb
@@ -1,7 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#---
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

# This file contains the names of kernel modules that should be loaded at boot time, one per line. Lines beginning with "#" are ignored.
#
Expand Down
9 changes: 5 additions & 4 deletions templates/default/profile.conf.erb
@@ -1,7 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#---
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

# Disable core dumps via soft limits for all users. Compliance to this setting is voluntary and can be modified by users up to a hard limit. This setting is a sane default.
ulimit -S -c 0 > /dev/null 2>&1
11 changes: 6 additions & 5 deletions templates/default/rhel_libuser.conf.erb
@@ -1,7 +1,8 @@
# See libuser.conf(5) for more information.

# Do not modify the default module list if you care about unattended calls
# to programs (i.e., scripts) working!
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

[import]
# Data from these files is used when libuser.conf does not define a value.
Expand Down Expand Up @@ -85,4 +86,4 @@ LU_GROUPNAME = %n
# in a particular domain. The default (all applications, all domains) is
# probably correct for most installations.
# appname = imap
# domain = EXAMPLE.COM
# domain = EXAMPLE.COM
8 changes: 5 additions & 3 deletions templates/default/rhel_selinuxconfig.erb
@@ -1,6 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

# This file controls the state of SELinux on the system.
# SELINUX= can take one of these three values:
Expand Down
11 changes: 6 additions & 5 deletions templates/default/rhel_sysconfig_init.erb
@@ -1,13 +1,14 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#---
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

# color => new RH6.0 bootup
# verbose => old-style bootup
# anything else => new style bootup without ANSI colors or positioning
BOOTUP=color
# column to start "[ OK ]" label in
# column to start "[ OK ]" label in
RES_COL=60
# terminal sequence to move to that column. You could change this
# to something like "tput hpa ${RES_COL}" if your terminal supports it
Expand Down
9 changes: 5 additions & 4 deletions templates/default/rhel_system_auth.erb
@@ -1,7 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#---
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

#%PAM-1.0
<% if node['os-hardening']['auth']['retries'] > 0 %>
Expand Down
9 changes: 5 additions & 4 deletions templates/default/securetty.erb
@@ -1,7 +1,8 @@
<% node['config_disclaimer'].to_s.split("\n").each do |l| %>
# <%= l %>
<% end %>
#---
#
# This file is generated by Chef for <%= node['fqdn'] %>
#
# Local changes will be overwritten
#

# A list of TTYs, from which root can log in
# see `man securetty` for reference
Expand Down