#!/bin/sh # ========================================================================================= # Author : Julien Charpentier # Email : julienchpt@gmail.com # File : check_setting_sshd.sh # Object : This check control the security of your SSH service (SSHD_Config - The setting of sshd_config file) # 4 values are checking: PermitRootLogin, Protocol, Port and PermitEmptyPasswords # For more detail ./check_setting_sshd.sh -h # ========================================================================================= # Release | Date | Authors | Description # --------+------------+----------------------+------------------------------------------ # 1.0 | 29/02/2012 | Julien CHARPENTIER | Creation # ========================================================================================= ################### # -- START - VARIABLES APPNAME=$(basename $0) CHECK_PRL="PermitRootLogin" CHECK_P="Protocol" CHECK_PEP="PermitEmptyPasswords" CHECK_PT="Port" # ------------------ # DEFAULT VALUE RESULT_CHECK_PRL="no" RESULT_CHECK_P="2" RESULT_CHECK_PEP="no" RESULT_CHECK_PT="22" PATH_SSHD="/etc/ssh/sshd_config" # -- END - VARIABLES ################### ################### # -- START - FONCTION usage () { cat<