<commit_before>#!/bin/sh
# This script was written by <NAME>, Red Hat Consulting
# Last update was 11 March 2015
# This script is NOT SUPPORTED by Red Hat Global Support Services.
# Please contact <NAME> for more information.
#
# Script: rhevm-postinstall.sh
# Description: Losens Hardening settings temporarily to allow registration with RHEVM 3.x
# License: GPL (see COPYING)
# Copyright: Red Hat Consulting, March 2015

# Check for root user
if [[ $EUID -ne 0 ]]; then
	tput setaf 1;echo -e "\033[1mPlease re-run this script as root!\033[0m";tput sgr0
	exit 1
fi

echo -e "\033[3m\033[1mRHEV Post-Install Script\033[0m\033[0m"

# Disallow Root Login
gpasswd -d root sshusers
sed -i "/^PermitRootLogin/ c\PermitRootLogin no" /etc/ssh/sshd_config

# Restart SSHD Service
service sshd restart

# Remount /tmp Partition
mount -o remount,defaults /tmp<commit_msg>Update rhevm-postinstall.sh<commit_after>#!/bin/sh
# This script was written by <NAME>, Red Hat Consulting
# Last update was 11 March 2015
# This script is NOT SUPPORTED by Red Hat Global Support Services.
# Please contact <NAME> for more information.
#
# Script: rhevm-postinstall.sh
# Description: Losens Hardening settings temporarily to allow registration with RHEVM 3.x
# License: GPL (see COPYING)
# Copyright: Red Hat Consulting, March 2015

# Check for root user
if [[ $EUID -ne 0 ]]; then
	tput setaf 1;echo -e "\033[1mPlease re-run this script as root!\033[0m";tput sgr0
	exit 1
fi

echo -e "\033[3m\033[1mRHEV Post-Install Script\033[0m\033[0m"

# Disallow Root Login
gpasswd -d root sshusers
sed -i "/^PermitRootLogin/ c\PermitRootLogin no" /etc/ssh/sshd_config
sed -e "/pam_succeed_if.so uid/s/^#//g" -i /etc/pam.d/password-auth

# Restart SSHD Service
service sshd restart

# Remount /tmp Partition
mount -o remount,defaults /tmp
{'fraction_non_alphanumeric': 0.10144124168514412, 'fraction_numerical': 0.043237250554323724, 'mean_word_length': 4.262390670553936, 'pattern_counts': {'":': 0, '<': 7, '<?xml version=': 0, '>': 7, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '958610', 'n_tokens_mistral': 686, 'n_tokens_neox': 613, 'n_words': 226}