Class Finding
- All Implemented Interfaces:
Serializable,SdkPojo,ToCopyableBuilder<Finding.Builder,Finding>
Represents a security finding discovered during a pentest job. A finding contains details about a vulnerability, including its risk level, confidence, and remediation status.
- See Also:
-
Nested Class Summary
Nested Classes -
Method Summary
Modifier and TypeMethodDescriptionfinal StringThe unique identifier of the agent space associated with the finding.final StringThe attack script used to reproduce the finding.static Finding.Builderbuilder()final List<CodeLocation> The file locations involved in the vulnerability, as reported by the code scanner.final CodeRemediationTaskThe code remediation task associated with the finding, if code remediation was initiated.final StringThe unique identifier of the code review associated with the finding.final StringThe unique identifier of the code review job that produced the finding.final ConfidenceLevelThe confidence level of the finding.final StringThe confidence level of the finding.final InstantThe date and time the finding was created, in UTC format.final StringA description of the finding.final booleanfinal booleanequalsBySdkFields(Object obj) Indicates whether some other object is "equal to" this one by SDK fields.final StringThe unique identifier of the finding.final <T> Optional<T> getValueForField(String fieldName, Class<T> clazz) final booleanFor responses, this returns true if the service returned a value for the CodeLocations property.final inthashCode()final StringThe identifier of the entity that last updated the finding.final Stringname()The name of the finding.final StringThe unique identifier of the pentest associated with the finding.final StringThe unique identifier of the pentest job that produced the finding.final StringThe reasoning behind the finding, explaining why it was identified as a vulnerability.final RiskLevelThe risk level of the finding.final StringThe risk level of the finding.final StringThe numerical risk score of the finding.final StringriskType()The type of security risk identified by the finding.static Class<? extends Finding.Builder> final FindingStatusstatus()The current status of the finding.final StringThe current status of the finding.final StringtaskId()The unique identifier of the task that produced the finding.Take this object and create a builder that contains all of the current property values of this object.final StringtoString()Returns a string representation of this object.final InstantThe date and time the finding was last updated, in UTC format.Methods inherited from interface software.amazon.awssdk.utils.builder.ToCopyableBuilder
copy
-
Method Details
-
findingId
The unique identifier of the finding.
- Returns:
- The unique identifier of the finding.
-
agentSpaceId
The unique identifier of the agent space associated with the finding.
- Returns:
- The unique identifier of the agent space associated with the finding.
-
pentestId
The unique identifier of the pentest associated with the finding.
- Returns:
- The unique identifier of the pentest associated with the finding.
-
pentestJobId
The unique identifier of the pentest job that produced the finding.
- Returns:
- The unique identifier of the pentest job that produced the finding.
-
codeReviewId
The unique identifier of the code review associated with the finding.
- Returns:
- The unique identifier of the code review associated with the finding.
-
codeReviewJobId
The unique identifier of the code review job that produced the finding.
- Returns:
- The unique identifier of the code review job that produced the finding.
-
taskId
The unique identifier of the task that produced the finding.
- Returns:
- The unique identifier of the task that produced the finding.
-
name
-
description
A description of the finding.
- Returns:
- A description of the finding.
-
status
The current status of the finding. Valid values include ACTIVE, RESOLVED, ACCEPTED, and FALSE_POSITIVE.
If the service returns an enum value that is not available in the current SDK version,
statuswill returnFindingStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromstatusAsString().- Returns:
- The current status of the finding. Valid values include ACTIVE, RESOLVED, ACCEPTED, and FALSE_POSITIVE.
- See Also:
-
statusAsString
The current status of the finding. Valid values include ACTIVE, RESOLVED, ACCEPTED, and FALSE_POSITIVE.
If the service returns an enum value that is not available in the current SDK version,
statuswill returnFindingStatus.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromstatusAsString().- Returns:
- The current status of the finding. Valid values include ACTIVE, RESOLVED, ACCEPTED, and FALSE_POSITIVE.
- See Also:
-
riskType
The type of security risk identified by the finding.
- Returns:
- The type of security risk identified by the finding.
-
riskLevel
The risk level of the finding. Valid values include UNKNOWN, INFORMATIONAL, LOW, MEDIUM, HIGH, and CRITICAL.
If the service returns an enum value that is not available in the current SDK version,
riskLevelwill returnRiskLevel.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromriskLevelAsString().- Returns:
- The risk level of the finding. Valid values include UNKNOWN, INFORMATIONAL, LOW, MEDIUM, HIGH, and CRITICAL.
- See Also:
-
riskLevelAsString
The risk level of the finding. Valid values include UNKNOWN, INFORMATIONAL, LOW, MEDIUM, HIGH, and CRITICAL.
If the service returns an enum value that is not available in the current SDK version,
riskLevelwill returnRiskLevel.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromriskLevelAsString().- Returns:
- The risk level of the finding. Valid values include UNKNOWN, INFORMATIONAL, LOW, MEDIUM, HIGH, and CRITICAL.
- See Also:
-
riskScore
The numerical risk score of the finding.
- Returns:
- The numerical risk score of the finding.
-
reasoning
The reasoning behind the finding, explaining why it was identified as a vulnerability.
- Returns:
- The reasoning behind the finding, explaining why it was identified as a vulnerability.
-
confidence
The confidence level of the finding. Valid values include FALSE_POSITIVE, UNCONFIRMED, LOW, MEDIUM, and HIGH.
If the service returns an enum value that is not available in the current SDK version,
confidencewill returnConfidenceLevel.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromconfidenceAsString().- Returns:
- The confidence level of the finding. Valid values include FALSE_POSITIVE, UNCONFIRMED, LOW, MEDIUM, and HIGH.
- See Also:
-
confidenceAsString
The confidence level of the finding. Valid values include FALSE_POSITIVE, UNCONFIRMED, LOW, MEDIUM, and HIGH.
If the service returns an enum value that is not available in the current SDK version,
confidencewill returnConfidenceLevel.UNKNOWN_TO_SDK_VERSION. The raw value returned by the service is available fromconfidenceAsString().- Returns:
- The confidence level of the finding. Valid values include FALSE_POSITIVE, UNCONFIRMED, LOW, MEDIUM, and HIGH.
- See Also:
-
attackScript
The attack script used to reproduce the finding.
- Returns:
- The attack script used to reproduce the finding.
-
codeRemediationTask
The code remediation task associated with the finding, if code remediation was initiated.
- Returns:
- The code remediation task associated with the finding, if code remediation was initiated.
-
lastUpdatedBy
The identifier of the entity that last updated the finding.
- Returns:
- The identifier of the entity that last updated the finding.
-
hasCodeLocations
public final boolean hasCodeLocations()For responses, this returns true if the service returned a value for the CodeLocations property. This DOES NOT check that the value is non-empty (for which, you should check theisEmpty()method on the property). This is useful because the SDK will never return a null collection or map, but you may need to differentiate between the service returning nothing (or null) and the service returning an empty collection or map. For requests, this returns true if a value for the property was specified in the request builder, and false if a value was not specified. -
codeLocations
The file locations involved in the vulnerability, as reported by the code scanner.
Attempts to modify the collection returned by this method will result in an UnsupportedOperationException.
This method will never return null. If you would like to know whether the service returned this field (so that you can differentiate between null and empty), you can use the
hasCodeLocations()method.- Returns:
- The file locations involved in the vulnerability, as reported by the code scanner.
-
createdAt
The date and time the finding was created, in UTC format.
- Returns:
- The date and time the finding was created, in UTC format.
-
updatedAt
The date and time the finding was last updated, in UTC format.
- Returns:
- The date and time the finding was last updated, in UTC format.
-
toBuilder
Description copied from interface:ToCopyableBuilderTake this object and create a builder that contains all of the current property values of this object.- Specified by:
toBuilderin interfaceToCopyableBuilder<Finding.Builder,Finding> - Returns:
- a builder for type T
-
builder
-
serializableBuilderClass
-
hashCode
-
equals
-
equalsBySdkFields
Description copied from interface:SdkPojoIndicates whether some other object is "equal to" this one by SDK fields. An SDK field is a modeled, non-inherited field in anSdkPojoclass, and is generated based on a service model.If an
SdkPojoclass does not have any inherited fields,equalsBySdkFieldsandequalsare essentially the same.- Specified by:
equalsBySdkFieldsin interfaceSdkPojo- Parameters:
obj- the object to be compared with- Returns:
- true if the other object equals to this object by sdk fields, false otherwise.
-
toString
-
getValueForField
-
sdkFields
-
sdkFieldNameToField
- Specified by:
sdkFieldNameToFieldin interfaceSdkPojo- Returns:
- The mapping between the field name and its corresponding field.
-