All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.amazonaws.services.inspector2.model.FindingDetail Maven / Gradle / Ivy

Go to download

The AWS Java SDK for Inspector2 module holds the client classes that are used for communicating with Inspector2 Service

There is a newer version: 1.12.772
Show newest version
/*
 * Copyright 2019-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.inspector2.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* Details of the vulnerability identified in a finding. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class FindingDetail implements Serializable, Cloneable, StructuredPojo { private CisaData cisaData; /** *

* The Common Weakness Enumerations (CWEs) associated with the vulnerability. *

*/ private java.util.List cwes; /** *

* The Exploit Prediction Scoring System (EPSS) score of the vulnerability. *

*/ private Double epssScore; /** *

* Information on the evidence of the vulnerability. *

*/ private java.util.List evidences; private ExploitObserved exploitObserved; /** *

* The finding ARN that the vulnerability details are associated with. *

*/ private String findingArn; /** *

* The reference URLs for the vulnerability data. *

*/ private java.util.List referenceUrls; /** *

* The risk score of the vulnerability. *

*/ private Integer riskScore; /** *

* The known malware tools or kits that can exploit the vulnerability. *

*/ private java.util.List tools; /** *

* The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. *

*/ private java.util.List ttps; /** * @param cisaData */ public void setCisaData(CisaData cisaData) { this.cisaData = cisaData; } /** * @return */ public CisaData getCisaData() { return this.cisaData; } /** * @param cisaData * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withCisaData(CisaData cisaData) { setCisaData(cisaData); return this; } /** *

* The Common Weakness Enumerations (CWEs) associated with the vulnerability. *

* * @return The Common Weakness Enumerations (CWEs) associated with the vulnerability. */ public java.util.List getCwes() { return cwes; } /** *

* The Common Weakness Enumerations (CWEs) associated with the vulnerability. *

* * @param cwes * The Common Weakness Enumerations (CWEs) associated with the vulnerability. */ public void setCwes(java.util.Collection cwes) { if (cwes == null) { this.cwes = null; return; } this.cwes = new java.util.ArrayList(cwes); } /** *

* The Common Weakness Enumerations (CWEs) associated with the vulnerability. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setCwes(java.util.Collection)} or {@link #withCwes(java.util.Collection)} if you want to override the * existing values. *

* * @param cwes * The Common Weakness Enumerations (CWEs) associated with the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withCwes(String... cwes) { if (this.cwes == null) { setCwes(new java.util.ArrayList(cwes.length)); } for (String ele : cwes) { this.cwes.add(ele); } return this; } /** *

* The Common Weakness Enumerations (CWEs) associated with the vulnerability. *

* * @param cwes * The Common Weakness Enumerations (CWEs) associated with the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withCwes(java.util.Collection cwes) { setCwes(cwes); return this; } /** *

* The Exploit Prediction Scoring System (EPSS) score of the vulnerability. *

* * @param epssScore * The Exploit Prediction Scoring System (EPSS) score of the vulnerability. */ public void setEpssScore(Double epssScore) { this.epssScore = epssScore; } /** *

* The Exploit Prediction Scoring System (EPSS) score of the vulnerability. *

* * @return The Exploit Prediction Scoring System (EPSS) score of the vulnerability. */ public Double getEpssScore() { return this.epssScore; } /** *

* The Exploit Prediction Scoring System (EPSS) score of the vulnerability. *

* * @param epssScore * The Exploit Prediction Scoring System (EPSS) score of the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withEpssScore(Double epssScore) { setEpssScore(epssScore); return this; } /** *

* Information on the evidence of the vulnerability. *

* * @return Information on the evidence of the vulnerability. */ public java.util.List getEvidences() { return evidences; } /** *

* Information on the evidence of the vulnerability. *

* * @param evidences * Information on the evidence of the vulnerability. */ public void setEvidences(java.util.Collection evidences) { if (evidences == null) { this.evidences = null; return; } this.evidences = new java.util.ArrayList(evidences); } /** *

* Information on the evidence of the vulnerability. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setEvidences(java.util.Collection)} or {@link #withEvidences(java.util.Collection)} if you want to * override the existing values. *

* * @param evidences * Information on the evidence of the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withEvidences(Evidence... evidences) { if (this.evidences == null) { setEvidences(new java.util.ArrayList(evidences.length)); } for (Evidence ele : evidences) { this.evidences.add(ele); } return this; } /** *

* Information on the evidence of the vulnerability. *

* * @param evidences * Information on the evidence of the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withEvidences(java.util.Collection evidences) { setEvidences(evidences); return this; } /** * @param exploitObserved */ public void setExploitObserved(ExploitObserved exploitObserved) { this.exploitObserved = exploitObserved; } /** * @return */ public ExploitObserved getExploitObserved() { return this.exploitObserved; } /** * @param exploitObserved * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withExploitObserved(ExploitObserved exploitObserved) { setExploitObserved(exploitObserved); return this; } /** *

* The finding ARN that the vulnerability details are associated with. *

* * @param findingArn * The finding ARN that the vulnerability details are associated with. */ public void setFindingArn(String findingArn) { this.findingArn = findingArn; } /** *

* The finding ARN that the vulnerability details are associated with. *

* * @return The finding ARN that the vulnerability details are associated with. */ public String getFindingArn() { return this.findingArn; } /** *

* The finding ARN that the vulnerability details are associated with. *

* * @param findingArn * The finding ARN that the vulnerability details are associated with. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withFindingArn(String findingArn) { setFindingArn(findingArn); return this; } /** *

* The reference URLs for the vulnerability data. *

* * @return The reference URLs for the vulnerability data. */ public java.util.List getReferenceUrls() { return referenceUrls; } /** *

* The reference URLs for the vulnerability data. *

* * @param referenceUrls * The reference URLs for the vulnerability data. */ public void setReferenceUrls(java.util.Collection referenceUrls) { if (referenceUrls == null) { this.referenceUrls = null; return; } this.referenceUrls = new java.util.ArrayList(referenceUrls); } /** *

* The reference URLs for the vulnerability data. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setReferenceUrls(java.util.Collection)} or {@link #withReferenceUrls(java.util.Collection)} if you want * to override the existing values. *

* * @param referenceUrls * The reference URLs for the vulnerability data. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withReferenceUrls(String... referenceUrls) { if (this.referenceUrls == null) { setReferenceUrls(new java.util.ArrayList(referenceUrls.length)); } for (String ele : referenceUrls) { this.referenceUrls.add(ele); } return this; } /** *

* The reference URLs for the vulnerability data. *

* * @param referenceUrls * The reference URLs for the vulnerability data. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withReferenceUrls(java.util.Collection referenceUrls) { setReferenceUrls(referenceUrls); return this; } /** *

* The risk score of the vulnerability. *

* * @param riskScore * The risk score of the vulnerability. */ public void setRiskScore(Integer riskScore) { this.riskScore = riskScore; } /** *

* The risk score of the vulnerability. *

* * @return The risk score of the vulnerability. */ public Integer getRiskScore() { return this.riskScore; } /** *

* The risk score of the vulnerability. *

* * @param riskScore * The risk score of the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withRiskScore(Integer riskScore) { setRiskScore(riskScore); return this; } /** *

* The known malware tools or kits that can exploit the vulnerability. *

* * @return The known malware tools or kits that can exploit the vulnerability. */ public java.util.List getTools() { return tools; } /** *

* The known malware tools or kits that can exploit the vulnerability. *

* * @param tools * The known malware tools or kits that can exploit the vulnerability. */ public void setTools(java.util.Collection tools) { if (tools == null) { this.tools = null; return; } this.tools = new java.util.ArrayList(tools); } /** *

* The known malware tools or kits that can exploit the vulnerability. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setTools(java.util.Collection)} or {@link #withTools(java.util.Collection)} if you want to override the * existing values. *

* * @param tools * The known malware tools or kits that can exploit the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withTools(String... tools) { if (this.tools == null) { setTools(new java.util.ArrayList(tools.length)); } for (String ele : tools) { this.tools.add(ele); } return this; } /** *

* The known malware tools or kits that can exploit the vulnerability. *

* * @param tools * The known malware tools or kits that can exploit the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withTools(java.util.Collection tools) { setTools(tools); return this; } /** *

* The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. *

* * @return The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. */ public java.util.List getTtps() { return ttps; } /** *

* The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. *

* * @param ttps * The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. */ public void setTtps(java.util.Collection ttps) { if (ttps == null) { this.ttps = null; return; } this.ttps = new java.util.ArrayList(ttps); } /** *

* The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setTtps(java.util.Collection)} or {@link #withTtps(java.util.Collection)} if you want to override the * existing values. *

* * @param ttps * The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withTtps(String... ttps) { if (this.ttps == null) { setTtps(new java.util.ArrayList(ttps.length)); } for (String ele : ttps) { this.ttps.add(ele); } return this; } /** *

* The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. *

* * @param ttps * The MITRE adversary tactics, techniques, or procedures (TTPs) associated with the vulnerability. * @return Returns a reference to this object so that method calls can be chained together. */ public FindingDetail withTtps(java.util.Collection ttps) { setTtps(ttps); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getCisaData() != null) sb.append("CisaData: ").append(getCisaData()).append(","); if (getCwes() != null) sb.append("Cwes: ").append(getCwes()).append(","); if (getEpssScore() != null) sb.append("EpssScore: ").append(getEpssScore()).append(","); if (getEvidences() != null) sb.append("Evidences: ").append(getEvidences()).append(","); if (getExploitObserved() != null) sb.append("ExploitObserved: ").append(getExploitObserved()).append(","); if (getFindingArn() != null) sb.append("FindingArn: ").append(getFindingArn()).append(","); if (getReferenceUrls() != null) sb.append("ReferenceUrls: ").append(getReferenceUrls()).append(","); if (getRiskScore() != null) sb.append("RiskScore: ").append(getRiskScore()).append(","); if (getTools() != null) sb.append("Tools: ").append(getTools()).append(","); if (getTtps() != null) sb.append("Ttps: ").append(getTtps()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof FindingDetail == false) return false; FindingDetail other = (FindingDetail) obj; if (other.getCisaData() == null ^ this.getCisaData() == null) return false; if (other.getCisaData() != null && other.getCisaData().equals(this.getCisaData()) == false) return false; if (other.getCwes() == null ^ this.getCwes() == null) return false; if (other.getCwes() != null && other.getCwes().equals(this.getCwes()) == false) return false; if (other.getEpssScore() == null ^ this.getEpssScore() == null) return false; if (other.getEpssScore() != null && other.getEpssScore().equals(this.getEpssScore()) == false) return false; if (other.getEvidences() == null ^ this.getEvidences() == null) return false; if (other.getEvidences() != null && other.getEvidences().equals(this.getEvidences()) == false) return false; if (other.getExploitObserved() == null ^ this.getExploitObserved() == null) return false; if (other.getExploitObserved() != null && other.getExploitObserved().equals(this.getExploitObserved()) == false) return false; if (other.getFindingArn() == null ^ this.getFindingArn() == null) return false; if (other.getFindingArn() != null && other.getFindingArn().equals(this.getFindingArn()) == false) return false; if (other.getReferenceUrls() == null ^ this.getReferenceUrls() == null) return false; if (other.getReferenceUrls() != null && other.getReferenceUrls().equals(this.getReferenceUrls()) == false) return false; if (other.getRiskScore() == null ^ this.getRiskScore() == null) return false; if (other.getRiskScore() != null && other.getRiskScore().equals(this.getRiskScore()) == false) return false; if (other.getTools() == null ^ this.getTools() == null) return false; if (other.getTools() != null && other.getTools().equals(this.getTools()) == false) return false; if (other.getTtps() == null ^ this.getTtps() == null) return false; if (other.getTtps() != null && other.getTtps().equals(this.getTtps()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getCisaData() == null) ? 0 : getCisaData().hashCode()); hashCode = prime * hashCode + ((getCwes() == null) ? 0 : getCwes().hashCode()); hashCode = prime * hashCode + ((getEpssScore() == null) ? 0 : getEpssScore().hashCode()); hashCode = prime * hashCode + ((getEvidences() == null) ? 0 : getEvidences().hashCode()); hashCode = prime * hashCode + ((getExploitObserved() == null) ? 0 : getExploitObserved().hashCode()); hashCode = prime * hashCode + ((getFindingArn() == null) ? 0 : getFindingArn().hashCode()); hashCode = prime * hashCode + ((getReferenceUrls() == null) ? 0 : getReferenceUrls().hashCode()); hashCode = prime * hashCode + ((getRiskScore() == null) ? 0 : getRiskScore().hashCode()); hashCode = prime * hashCode + ((getTools() == null) ? 0 : getTools().hashCode()); hashCode = prime * hashCode + ((getTtps() == null) ? 0 : getTtps().hashCode()); return hashCode; } @Override public FindingDetail clone() { try { return (FindingDetail) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.inspector2.model.transform.FindingDetailMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy