AWS services or capabilities described in AWS Documentation may vary by region/location. Click Getting Started with Amazon AWS to see specific differences applicable to the China (Beijing) Region.
Returns a list of findings that match the specified criteria.
If cross-Region aggregation is enabled, then when you call GetFindings
from
the home Region, the results include all of the matching findings from both the home
Region and linked Regions.
For .NET Core this operation is only available in asynchronous form. Please refer to GetFindingsAsync.
Namespace: Amazon.SecurityHub
Assembly: AWSSDK.SecurityHub.dll
Version: 3.x.y.z
public virtual GetFindingsResponse GetFindings( GetFindingsRequest request )
Container for the necessary parameters to execute the GetFindings service method.
Exception | Condition |
---|---|
InternalException | Internal server error. |
InvalidAccessException | The account doesn't have permission to perform this action. |
InvalidInputException | The request was rejected because you supplied an invalid or out-of-range value for an input parameter. |
LimitExceededException | The request was rejected because it attempted to create resources beyond the current Amazon Web Services account or throttling limits. The error code describes the limit exceeded. |
The following example returns a filtered and sorted list of Security Hub findings.
var client = new AmazonSecurityHubClient(); var response = client.GetFindings(new GetFindingsRequest { Filters = new AwsSecurityFindingFilters { AwsAccountId = new List<StringFilter> { new StringFilter { Comparison = "PREFIX", Value = "123456789012" } } }, MaxResults = 1 }); List<AwsSecurityFinding> findings = response.Findings;
.NET Framework:
Supported in: 4.5 and newer, 3.5