Skip to content

Commit

Permalink
Address nccgroup#929
Browse files Browse the repository at this point in the history
  • Loading branch information
x4v13r64 committed Nov 16, 2020
1 parent 74d693d commit 4589e9c
Showing 1 changed file with 1 addition and 2 deletions.
3 changes: 1 addition & 2 deletions ScoutSuite/providers/aws/resources/ec2/instances.py
Original file line number Diff line number Diff line change
Expand Up @@ -44,8 +44,7 @@ async def _parse_instance(self, raw_instance):
get_keys(eni, nic, ['Association', 'Groups', 'PrivateIpAddresses', 'SubnetId', 'Ipv6Addresses'])
instance['network_interfaces'][eni['NetworkInterfaceId']] = nic

instance['metadata_options'] = raw_instance['MetadataOptions']

instance['metadata_options'] = raw_instance.get('MetadataOptions', {})

if 'IamInstanceProfile' in raw_instance:
instance['iam_role'] = raw_instance['IamInstanceProfile']['Arn'].split('/')[-1]
Expand Down

0 comments on commit 4589e9c

Please sign in to comment.