From 43918cfcfefa1f313a37549ff641c1f78e61e5f5 Mon Sep 17 00:00:00 2001 From: Hemed Gur-Ary Date: Mon, 21 Aug 2017 23:44:34 +0300 Subject: [PATCH 1/3] removed printCurrentDate() and added current date to banner --- prowler | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/prowler b/prowler index 0fde9081..cb04a8d9 100755 --- a/prowler +++ b/prowler @@ -335,6 +335,7 @@ prowlerBanner() { echo -e " | |_) | | | (_) \ V V /| | __/ |" echo -e " | .__/|_| \___/ \_/\_/ |_|\___|_|" echo -e " |_|$NORMAL$BLUE CIS based AWS Account Hardening Tool$NORMAL\n" + echo -e "$YELLOW Date: $(date)" } # Get whoami in AWS, who is the user running this shell script @@ -381,10 +382,6 @@ getWhoami(){ fi } -printCurrentDate(){ - textNotice "Date: $(date)" -} - printColorsCode(){ if [[ $MONOCHROME -eq 0 ]]; then echo -e "\nColors Code for results: $NOTICE INFORMATIVE$NORMAL,$OK OK (RECOMMENDED VALUE)$NORMAL, $BAD WARNING (FIX REQUIRED)$NORMAL \n" @@ -1580,8 +1577,7 @@ callCheck(){ ### All functions defined above ... run the workflow if [[ $MODE != "csv" ]]; then - prowlerBanner - printCurrentDate + prowlerBanner printColorsCode fi getWhoami From afb914f9d7f7772b9ea06c4c4b4b9075e87b5f46 Mon Sep 17 00:00:00 2001 From: Hemed Gur-Ary Date: Tue, 22 Aug 2017 00:19:49 +0300 Subject: [PATCH 2/3] Updated infoReferenceLong() text and moved the function call --- prowler | 15 ++++++++------- 1 file changed, 8 insertions(+), 7 deletions(-) diff --git a/prowler b/prowler index 0fde9081..392fa994 100755 --- a/prowler +++ b/prowler @@ -428,10 +428,13 @@ REGIONS=$($AWSCLI ec2 describe-regions --query 'Regions[].RegionName' \ infoReferenceLong(){ # Report review note: - textNotice "For more information:" - textNotice "https://benchmarks.cisecurity.org/tools2/amazon/CIS_Amazon_Web_Services_Foundations_Benchmark_v1.1.0.pdf" - textNotice "For bugs or feedback:" - textNotice "https://github.com/Alfresco/aws-cis-security-benchmark/issues" + echo -e "" + echo -e "For more information on the Prowler, feedback and issue reporting:" + echo -e "https://github.com/Alfresco/prowler" + echo -e "" + echo -e "For more information on the CIS benchmark:" + echo -e "https://benchmarks.cisecurity.org/tools2/amazon/CIS_Amazon_Web_Services_Foundations_Benchmark_v1.1.0.pdf" + } @@ -1582,6 +1585,7 @@ callCheck(){ if [[ $MODE != "csv" ]]; then prowlerBanner printCurrentDate + infoReferenceLong printColorsCode fi getWhoami @@ -1662,7 +1666,4 @@ extra71 extra72 extra73 -if [[ $MODE != "csv" ]]; then - infoReferenceLong -fi cleanTemp From 866200d0188df02faf9fd6e780155fd3feec8b1f Mon Sep 17 00:00:00 2001 From: Hemed Gur-Ary Date: Tue, 22 Aug 2017 00:34:17 +0300 Subject: [PATCH 3/3] Fix issue #96 - remove bit.ly reference --- prowler | 12 +----------- 1 file changed, 1 insertion(+), 11 deletions(-) diff --git a/prowler b/prowler index 0fde9081..d771f966 100755 --- a/prowler +++ b/prowler @@ -434,12 +434,6 @@ infoReferenceLong(){ textNotice "https://github.com/Alfresco/aws-cis-security-benchmark/issues" } - -infoReferenceShort(){ - # Report review note: - textNotice "http://bit.ly/2g3PEf7" -} - check11(){ ID11="1.1" TITLE11="Avoid the use of the root account (Scored)." @@ -715,7 +709,6 @@ check117(){ textTitle "$ID117" "$TITLE117" "SCORED" "LEVEL1" textNotice "No command available for check 1.17 " textNotice "See section 1.17 on the CIS Benchmark guide for details " - infoReferenceShort } check118(){ @@ -751,7 +744,6 @@ check119(){ textTitle "$ID119" "$TITLE119" "SCORED" "LEVEL1" textNotice "No command available for check 1.19 " textNotice "See section 1.19 on the CIS Benchmark guide for details " - infoReferenceShort } check120(){ @@ -761,7 +753,6 @@ check120(){ textTitle "$ID120" "$TITLE120" "SCORED" "LEVEL1" textNotice "No command available for check 1.20 " textNotice "See section 1.20 on the CIS Benchmark guide for details " - infoReferenceShort } check121(){ @@ -769,8 +760,7 @@ check121(){ TITLE121="Ensure IAM instance roles are used for AWS resource access from instances (Not Scored)" textTitle "$ID121" "$TITLE121" "NOT_SCORED" "LEVEL2" textNotice "No command available for check 1.21 " - textNotice "See section 1.21 on the CIS Benchmark guide for details " - infoReferenceShort + textNotice "See section 1.21 on the CIS Benchmark guide for details " } check122(){