Skip to main content

AWS - AccessAnalyzer

This Integration is part of the AWS - AccessAnalyzer Pack.#

Amazon Web Services IAM Access Analyzer

For detailed instructions about setting up authentication, see: AWS Integrations - Authentication.

Configure AWS - AccessAnalyzer on Cortex XSOAR#

  1. Navigate to Settings > Integrations > Servers & Services.

  2. Search for AWS - AccessAnalyzer.

  3. Click Add instance to create and configure a new integration instance.

    ParameterDescriptionRequired
    AWS Default RegionFalse
    Role ArnFalse
    Role Session NameFalse
    Role Session DurationFalse
    Fetch incidentsFalse
    Incident typeFalse
    Access KeyFalse
    Secret KeyFalse
    Fetch Analyzer ARN (Required for fetching incidents)The ARN to fetch findings forFalse
    Trust any certificate (not secure)Trust any certificate (not secure).False
    Use system proxy settingsUse system proxy settings.False
    TimeoutThe time in seconds till a timeout exception is reached. You can specify just the read timeout (for example 60) or also the connect timeout followed after a comma (for example 60,10). If a connect timeout is not specified, a default of 10 second will be used.False
    RetriesThe maximum number of retry attempts when connection or throttling errors are encountered. Set to 0 to disable retries. The default value is 5 and the limit is 10. Note: Increasing the number of retries will increase the execution time.False
  4. Click Test to validate the URLs, token, and connection.

Fetch Incidents#

The integration fetches findings, generated by the analyzer specified in the Fetch Analyzer ARN parameter, as incidents.

Commands#

You can execute these commands from the Cortex XSOAR CLI, as part of an automation, or in a playbook. After you successfully execute a command, a DBot message appears in the War Room with the command details.

aws-access-analyzer-list-analyzers#


Retrieves a list of analyzers.

Base Command#

aws-access-analyzer-list-analyzers

Input#

Argument NameDescriptionRequired
regionThe AWS Region, if not specified the default region will be used.Optional
roleArnThe Amazon Resource Name (ARN) of the role to assume.Optional
roleSessionNameAn identifier for the assumed role session.Optional
roleSessionDurationThe duration, in seconds, of the role session. The value can range from 900 seconds (15 minutes) up to the maximum session duration setting for the role.Optional

Context Output#

PathTypeDescription
AWS.AccessAnalyzer.AnalyzersUnknownList of Analyzers and their details.
AWS.AccessAnalyzer.Analyzers.arnStringThe analyzer ARN.

Command example#

!aws-access-analyzer-list-analyzers

Context Example#

{
"AWS": {
"AccessAnalyzer": {
"Analyzers": {
"arn": "arn:aws:access-analyzer:us-east-2:123456789012:analyzer/ConsoleAnalyzer-k80aff71-2468-47l7-b24c-p8992b3f10d5",
"createdAt": "2021-09-08T17:25:37",
"lastResourceAnalyzed": "arn:aws:iam::123456789012:role/accessadvisor",
"lastResourceAnalyzedAt": "2021-09-08T17:25:37",
"name": "ConsoleAnalyzer-k80aff71-2468-47l7-b24c-p8992b3f10d5",
"status": "ACTIVE",
"tags": {},
"type": "ACCOUNT"
}
}
}
}

Human Readable Output#

AWS Access Analyzer Analyzers#

ArnCreated AtLast Resource AnalyzedLast Resource Analyzed AtNameStatusTagsType
arn:aws:access-analyzer:us-east-2:123456789012:analyzer/ConsoleAnalyzer-k80aff71-2468-47l7-b24c-p8992b3f10d52021-09-08T17:25:37arn:aws:iam::123456789012:role/XSOARCortexXDRReadOnlyRole2021-09-08T17:25:37ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898ACTIVEACCOUNT

aws-access-analyzer-list-analyzed-resource#


Retrieves a list of resources that have been analyzed.

Base Command#

aws-access-analyzer-list-analyzed-resource

Input#

Argument NameDescriptionRequired
analyzerArnThe ARN of the analyzer to retrieve a list of analyzed resources from.Required
maxResultsThe maximum number of results to return in the response.Optional
resourceTypeFilter findings by one of the resource type. Possible values are: AWS::IAM::Role, AWS::KMS::Key, AWS::Lambda::Function, AWS::Lambda::LayerVersion, AWS::S3::Bucket, AWS::SQS::Queue.Optional
regionThe AWS Region, if not specified the default region will be used.Optional
roleArnThe Amazon Resource Name (ARN) of the role to assume.Optional
roleSessionNameAn identifier for the assumed role session.Optional
roleSessionDurationThe duration, in seconds, of the role session. The value can range from 900 seconds (15 minutes) up to the maximum session duration setting for the role.Optional

Context Output#

PathTypeDescription
AWS.AccessAnalyzer.ResourceUnknownList of analyzed resources.
AWS.AccessAnalyzer.Resource.resourceArnStringThe resource ARN.
AWS.AccessAnalyzer.Resource.analyzerArnStringThe analyzer ARN.

Command example#

!aws-access-analyzer-list-analyzed-resource analyzerArn=arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898

Context Example#

{
"AWS": {
"AccessAnalyzer": {
"Resource": [
{
"analyzerArn": "arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898",
"resourceArn": "arn:aws:iam::123456789012:role/-TestRole",
"resourceOwnerAccount": "123456789012",
"resourceType": "AWS::IAM::Role"
},
{
"analyzerArn": "arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898",
"resourceArn": "arn:aws:iam::123456789012:role/BishopFoxPlatformAssumeRole",
"resourceOwnerAccount": "123456789012",
"resourceType": "AWS::IAM::Role"
}
]
}
}
}

Human Readable Output#

AWS Access Analyzer Resources#

Resource ArnResource Owner AccountResource Type
arn:aws:iam::123456789012:role/-TestRole123456789012AWS::IAM::Role
arn:aws:iam::123456789012:role/BishopFoxPlatformAssumeRole123456789012AWS::IAM::Role

aws-access-analyzer-list-findings#


Retrieves a list of findings generated by the specified analyzer.

Base Command#

aws-access-analyzer-list-findings

Input#

Argument NameDescriptionRequired
analyzerArnThe ARN of the analyzer to retrieve findings from.Required
maxResultsThe maximum number of results to return in the response.Optional
resourceTypeFilter findings by one of the resource type. Possible values are: AWS::IAM::Role, AWS::KMS::Key, AWS::Lambda::Function, AWS::Lambda::LayerVersion, AWS::S3::Bucket, AWS::SQS::Queue.Optional
statusFilter findings by status. Possible values are: ACTIVE, ARCHIVED, RESOLVED.Optional
regionThe AWS Region, if not specified the default region will be used.Optional
roleArnThe Amazon Resource Name (ARN) of the role to assume.Optional
roleSessionNameAn identifier for the assumed role session.Optional
roleSessionDurationThe duration, in seconds, of the role session. The value can range from 900 seconds (15 minutes) up to the maximum session duration setting for the role.Optional

Context Output#

PathTypeDescription
AWS.AccessAnalyzer.FindingUnknownAccess Analyzer findings.
AWS.AccessAnalyzer.Finding.idStringThe finding ID.
AWS.AccessAnalyzer.Finding.analyzerArnStringThe analyzer ARN.

Command example#

!aws-access-analyzer-list-findings analyzerArn=arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898

Context Example#

{
"AWS": {
"AccessAnalyzer": {
"Finding": [
{
"action": [
"sts:AssumeRoleWithWebIdentity"
],
"analyzedAt": "2023-02-28T07:47:01",
"analyzerArn": "arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898",
"condition": {
"accounts.google.com:aud": "1234567890123456789012"
},
"createdAt": "2023-02-13T21:28:04",
"id": "03c44171-223c-4615-be8a-bf0b626f0b13",
"isPublic": false,
"principal": {
"Federated": "accounts.google.com"
},
"resource": "arn:aws:iam::123456789012:role/billing-bot-role",
"resourceOwnerAccount": "123456789012",
"resourceType": "AWS::IAM::Role",
"status": "ARCHIVED",
"updatedAt": "2023-02-23T10:08:54"
},
{
"action": [
"sts:AssumeRole"
],
"analyzedAt": "2023-02-27T10:59:00",
"analyzerArn": "arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898",
"condition": {},
"createdAt": "2023-02-13T21:28:04",
"id": "babbbe27-835e-4c34-8cbd-f19dc877fa31",
"isPublic": false,
"principal": {
"AWS": "252015767101"
},
"resource": "arn:aws:iam::123456789012:role/c7nSecurityAuditRole",
"resourceOwnerAccount": "123456789012",
"resourceType": "AWS::IAM::Role",
"status": "ACTIVE",
"updatedAt": "2023-02-13T21:28:04"
}
]
}
}
}

Human Readable Output#

AWS Access Analyzer Findings#

IdResourcePrincipalConditionUpdated AtStatus
03c44171-223c-4615-be8a-bf0b626f0b13arn:aws:iam::123456789012:role/billing-bot-roleFederated: accounts.google.comaccounts.google.com:aud: 12345678901234567890122023-02-23T10:08:54ARCHIVED
babbbe27-835e-4c34-8cbd-f19dc877fa31arn:aws:iam::123456789012:role/c7nSecurityAuditRoleAWS: 2520157671012023-02-13T21:28:04ACTIVE

aws-access-analyzer-get-analyzed-resource#


Retrieves information about an analyzed resource.

Base Command#

aws-access-analyzer-get-analyzed-resource

Input#

Argument NameDescriptionRequired
analyzerArnThe ARN of the analyzer to retrieve information from.Required
resourceArnThe ARN of the resource to retrieve information about.Required
regionThe AWS Region, if not specified the default region will be used.Optional
roleArnThe Amazon Resource Name (ARN) of the role to assume.Optional
roleSessionNameAn identifier for the assumed role session.Optional
roleSessionDurationThe duration, in seconds, of the role session. The value can range from 900 seconds (15 minutes) up to the maximum session duration setting for the role.Optional

Context Output#

PathTypeDescription
AWS.AccessAnalyzer.ResourceUnknownAnalyzed resource detail.
AWS.AccessAnalyzer.Resource.idStringThe resource ID.
AWS.AccessAnalyzer.Resource.analyzerArnStringThe analyzer ARN.

Command example#

!aws-access-analyzer-get-analyzed-resource analyzerArn=arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898 resourceArn=arn:aws:iam::123456789012:role/-TestRole

Context Example#

{
"AWS": {
"AccessAnalyzer": {
"Resource": {
"analyzedAt": "2023-02-27T10:59:00",
"analyzerArn": "arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898",
"isPublic": false,
"resourceArn": "arn:aws:iam::123456789012:role/-TestRole",
"resourceOwnerAccount": "123456789012",
"resourceType": "AWS::IAM::Role"
}
}
}
}

Human Readable Output#

AWS Access Analyzer Resource#

Analyzed AtAnalyzer ArnIs PublicResource ArnResource Owner AccountResource Type
2023-02-27T10:59:00arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898falsearn:aws:iam::123456789012:role/-TestRole123456789012AWS::IAM::Role

aws-access-analyzer-get-finding#


Retrieves information about the specified finding.

Base Command#

aws-access-analyzer-get-finding

Input#

Argument NameDescriptionRequired
analyzerArnThe ARN of the analyzer to retrieve information from.Required
findingIdThe ID of the finding to retrieve.Required
regionThe AWS Region, if not specified the default region will be used.Optional
roleArnThe Amazon Resource Name (ARN) of the role to assume.Optional
roleSessionNameAn identifier for the assumed role session.Optional
roleSessionDurationThe duration, in seconds, of the role session. The value can range from 900 seconds (15 minutes) up to the maximum session duration setting for the role.Optional

Context Output#

PathTypeDescription
AWS.AccessAnalyzer.FindingUnknownFinding details.
AWS.AccessAnalyzer.Finding.idStringThe finding ID.
AWS.AccessAnalyzer.Finding.analyzerArnStringThe analyzer ARN.

Command example#

!aws-access-analyzer-get-finding analyzerArn=arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898 findingId=03c44171-223c-4615-be8a-bf0b626f0b13

Context Example#

{
"AWS": {
"AccessAnalyzer": {
"Finding": {
"action": [
"sts:AssumeRoleWithWebIdentity"
],
"analyzedAt": "2023-02-28T07:47:01",
"analyzerArn": "arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898",
"condition": {
"accounts.google.com:aud": "1234567890123456789012"
},
"createdAt": "2023-02-13T21:28:04",
"id": "03c44171-223c-4615-be8a-bf0b626f0b13",
"isPublic": false,
"principal": {
"Federated": "accounts.google.com"
},
"resource": "arn:aws:iam::123456789012:role/billing-bot-role",
"resourceOwnerAccount": "123456789012",
"resourceType": "AWS::IAM::Role",
"status": "ARCHIVED",
"updatedAt": "2023-02-23T10:08:54"
}
}
}
}

Human Readable Output#

AWS Access Analyzer Finding#

ActionAnalyzed AtAnalyzer ArnConditionCreated AtIdIs PublicPrincipalResourceResource Owner AccountResource TypeStatusUpdated At
sts:AssumeRoleWithWebIdentity2023-02-28T07:47:01arn:aws:access-analyzer:us-east-1:123456789012:analyzer/ConsoleAnalyzer-fc3b189d-f88a-48a5-9c2b-f42f9187c898accounts.google.com:aud: 12345678901234567890122023-02-13T21:28:0403c44171-223c-4615-be8a-bf0b626f0b13falseFederated: accounts.google.comarn:aws:iam::123456789012:role/billing-bot-role123456789012AWS::IAM::RoleARCHIVED2023-02-23T10:08:54

aws-access-analyzer-start-resource-scan#


Starts a scan of the policies applied to the specified resource.

Base Command#

aws-access-analyzer-start-resource-scan

Input#

Argument NameDescriptionRequired
analyzerArnThe ARN of the analyzer to use to scan the policies applied to the specified resource.Required
resourceArnThe ARN of the resource to scan.Required
regionThe AWS Region, if not specified the default region will be used.Optional
roleArnThe Amazon Resource Name (ARN) of the role to assume.Optional
roleSessionNameAn identifier for the assumed role session.Optional
roleSessionDurationThe duration, in seconds, of the role session. The value can range from 900 seconds (15 minutes) up to the maximum session duration setting for the role.Optional

Context Output#

There is no context output for this command.

Command Example#

!aws-access-analyzer-start-resource-scan analyzerArn=arn:aws:access-analyzer:us-east-2:123456789012:analyzer/ConsoleAnalyzer-k80aff71-2468-47l7-b24c-p8992b3f10d5 resourceArn=arn:aws:iam::123456789012:role/OrganizationAccountAccessRole

Human Readable Output#

Resource scan request sent.

aws-access-analyzer-update-findings#


Updates findings with the new values provided in the request.

Base Command#

aws-access-analyzer-update-findings

Input#

Argument NameDescriptionRequired
analyzerArnThe ARN of the analyzer that generated the findings to update.Required
findingIdsThe IDs of the findings to update (comma separated).Required
statusThe ARN of the resource to scan. Possible values are: ACTIVE, ARCHIVED.Required
regionThe AWS Region, if not specified the default region will be used.Optional
roleArnThe Amazon Resource Name (ARN) of the role to assume.Optional
roleSessionNameAn identifier for the assumed role session.Optional
roleSessionDurationThe duration, in seconds, of the role session. The value can range from 900 seconds (15 minutes) up to the maximum session duration setting for the role.Optional

Context Output#

There is no context output for this command.

Command Example#

!aws-access-analyzer-update-findings analyzerArn=arn:aws:access-analyzer:us-east-2:123456789012:analyzer/ConsoleAnalyzer-k80aff71-2468-47l7-b24c-p8992b3f10d5 findingIds=78eb6782-5387-49k0-bpe5-39am61c3baee status=ACTIVE

Human Readable Output#

Findings updated