aws-samples / amazon-guardduty-multiaccount-scripts

This script automates the process of running the GuardDuty multi-account workflow across a group of accounts that are in your control
Apache License 2.0
130 stars 71 forks source link

Fix type of master_account variable #34

Open asantos-fuze opened 4 years ago

asantos-fuze commented 4 years ago

master_account variable was defined as int. By defining the var as int, would cause issues when the account id started with '0'. For example an account id with 0nnnnnnnnnnn, would become nnnnnnnnnnn. This whould fail on the regex '[0-9]{12}', because the account id would be striped of the leading 0, and only have 11 digits. Changing the master_account to str solves the issue.

Issue #, if available:

Description of changes:

By submitting this pull request, I confirm that my contribution is made under the terms of the Apache 2.0 license.