You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: README.md
+10-3Lines changed: 10 additions & 3 deletions
Original file line number
Diff line number
Diff line change
@@ -292,11 +292,12 @@ Prowler has two parameters related to regions: `-r` that is used query AWS servi
292
292
293
293
>Note about output formats to use with `-M`: "text" is the default one with colors, "mono" is like default one but monochrome, "csv" is comma separated values, "json" plain basic json (without comma between lines) and "json-asff" is also json with Amazon Security Finding Format that you can ship to Security Hub using `-S`.
294
294
295
-
or save your report in an S3 bucket (this only works for text or mono. For csv, json or json-asff it has to be copied afterwards):
295
+
To save your report in an S3 bucket, use `-B` to define a custom output bucket along with `-M` to define the output format that is going to be uploaded to S3:
>In the case you do not want to use the assumed role credentials but the initial credentials to put the reports into the S3 bucket, use `-D` instead of `-B`. Make sure that the used credentials have s3:PutObject permissions in the S3 path where the reports are going to be uploaded.
300
301
301
302
When generating multiple formats and running using Docker, to retrieve the reports, bind a local directory to the container, e.g.:
302
303
@@ -399,7 +400,10 @@ Prowler runs in GovCloud regions as well. To make sure it points to the right AP
399
400
400
401
### Custom folder for custom checks
401
402
402
-
Flag `-x /my/own/checks` will include any check in that particular directory. To see how to write checks see [Add Custom Checks](#add-custom-checks) section.
403
+
Flag `-x /my/own/checks` will include any check in that particular directory (files must start by check). To see how to write checks see [Add Custom Checks](#add-custom-checks) section.
404
+
405
+
S3 URIs are also supported as custom folders for custom checks, e.g. `s3://bucket/prefix/checks`. Prowler will download the folder locally and run the checks as they are called with default execution,`-c` or `-g`.
406
+
>Make sure that the used credentials have s3:GetObject permissions in the S3 path where the custom checks are located.
403
407
404
408
### Show or log only FAILs
405
409
@@ -488,6 +492,9 @@ Sometimes you may find resources that are intentionally configured in a certain
488
492
./prowler -w whitelist_sample.txt
489
493
```
490
494
495
+
S3 URIs are also supported as allowlist file, e.g. `s3://bucket/prefix/allowlist_sample.txt`
496
+
>Make sure that the used credentials have s3:GetObject permissions in the S3 path where the whitelist file is located.
497
+
491
498
Whitelist option works along with other options and adds a `WARNING` instead of `INFO`, `PASS` or `FAIL` to any output format except for `json-asff`.
echo"$BAD FAIL! Access Denied trying to download allowlist from the S3 URI, please make sure it is correct and/or you have permissions to get the S3 object.$NORMAL"
22
+
EXITCODE=1
23
+
exit$EXITCODE
24
+
fi
25
+
echo -e "$OK Success! Allowlist was downloaded, starting Prowler...$NORMAL"
echo -e "$OK Check $(basename "$checks") was included!$NORMAL"
27
+
done
28
+
echo -e "$OK Success! Custom checks were downloaded and included, starting Prowler...$NORMAL"
29
+
# remove temporary dir
30
+
rm -rf "${S3_CHECKS_TEMP_FOLDER}"
31
+
else
32
+
echo"$BAD FAIL! Access Denied trying to download custom checks or $EXTERNAL_CHECKS_PATH does not contain any checks, please make sure it is correct and/or you have permissions to get the S3 objects.$NORMAL"
33
+
EXITCODE=1
34
+
# remove temporary dir
35
+
rm -rf "${S3_CHECKS_TEMP_FOLDER}"
36
+
exit$EXITCODE
37
+
fi
38
+
else
39
+
# verify if input directory exists with checks
40
+
if ls "${EXTERNAL_CHECKS_PATH}"/check*> /dev/null 2>&1;then
41
+
forchecksin"${EXTERNAL_CHECKS_PATH}"/check*;do
42
+
."$checks"
43
+
echo -e "$OK Check $(basename "$checks") was included!$NORMAL"
44
+
done
45
+
echo -e "$OK Success! Custom checks were included, starting Prowler...$NORMAL"
46
+
else
47
+
echo"$BAD FAIL! $EXTERNAL_CHECKS_PATH does not exist or not contain checks, please input a valid custom checks path.$NORMAL"
0 commit comments