-
Notifications
You must be signed in to change notification settings - Fork 187
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #21 from kmcquade/fix/botocore-credentials-loading
Fix credentials loading for download command. Set required minimum Policy Sentry version
- Loading branch information
Showing
9 changed files
with
82 additions
and
169 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,40 @@ | ||
# Scanning an Account | ||
#### Scanning the Authorization Details file | ||
|
||
Scan the Account Authorization details file with the following command | ||
Now that we've downloaded the account authorization file, we can scan *all* of the AWS IAM policies with `cloudsplaining`. | ||
|
||
Run the following command: | ||
|
||
```bash | ||
cloudsplaining scan --exclusions-file exclusions.yml --input examples/files/example.json --output examples/files/ | ||
``` | ||
cloudsplaining scan --input default.json --exclusions-file my-exclusions.yml | ||
``` | ||
|
||
* It will generate three files: | ||
1. The single-file HTML report | ||
2. The triage CSV worksheet, and | ||
3. The raw JSON data file | ||
It will create an HTML report like [this](https://opensource.salesforce.com/cloudsplaining/): | ||
|
||
> ![](docs/_images/cloudsplaining-report.gif) | ||
|
||
It will also create a raw JSON data file: | ||
|
||
* `default-iam-results.json`: This contains the raw JSON output of the report. You can use this data file for operating on the scan results for various purposes. For example, you could write a Python script that parses this data and opens up automated JIRA issues or Salesforce Work Items. An example entry is shown below. The full example can be viewed at [examples/output/example-authz-details-results.json](examples/files/iam-results-example.json) | ||
|
||
```json | ||
{ | ||
"example-authz-details": [ | ||
{ | ||
"AccountID": "012345678901", | ||
"ManagedBy": "Customer", | ||
"PolicyName": "InsecureUserPolicy", | ||
"Arn": "arn:aws:iam::012345678901:user/userwithlotsofpermissions", | ||
"ActionsCount": 2, | ||
"ServicesCount": 1, | ||
"Actions": [ | ||
"s3:PutObject", | ||
"s3:PutObjectAcl" | ||
], | ||
"Services": [ | ||
"s3" | ||
] | ||
} | ||
] | ||
} | ||
``` |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,14 +1,13 @@ | ||
# Troubleshooting | ||
|
||
### Running the command (Path issues) | ||
|
||
* *I followed the installation instructions but can't execute the program via command line. What do I do?* | ||
**I followed the installation instructions but can't execute the program via command line at all. What do I do?** | ||
|
||
This is likely an issue with your PATH. Your PATH environment variable is not considering the binary packages installed by `pip3`. On a Mac, you can likely fix this by entering the command below, depending on the versions you have installed. YMMV. | ||
|
||
```bash | ||
# Python 3.7 | ||
export PATH=$HOME/Library/Python/3.7/bin/:$PATH | ||
# Python 3.8 | ||
export PATH=$HOME/Library/Python/3.8/bin/:$PATH | ||
``` | ||
|
||
**I followed the installation instructions but I am receiving a `ModuleNotFoundError` that says `No module named policy_sentry.analysis.expand`. What should I do?** | ||
|
||
Try upgrading to the latest version of Cloudsplaining. This error was fixed in version 0.0.10. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters