Class SecurityVulnerabilityDescriptor
java.lang.Object
org.xwiki.extension.index.security.SecurityVulnerabilityDescriptor
An individual security vulnerability descriptor.
- Since:
- 15.5RC1
- Version:
- $Id: 0896bb057c9a25b6146872684744d01583c267bd $
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionboolean
Retrieves the set of aliases associated with the current object.org.xwiki.extension.version.Version
getId()
double
getScore()
getURL()
int
hashCode()
boolean
isSafe()
setAliases
(Set<String> aliases) Sets the set of aliases associated with the current object.setFixVersion
(org.xwiki.extension.version.Version fixVersion) setReviews
(String reviews) setSafe
(boolean safe) setScore
(double score) setSeverityScore
(String vector) Compute and store the score from the provided CVSS vector.toString()
-
Constructor Details
-
SecurityVulnerabilityDescriptor
public SecurityVulnerabilityDescriptor()
-
-
Method Details
-
setId
- Parameters:
id
- the security vulnerability id, by default a CVE id, or another id if no CVE is found- Returns:
- the current object
-
getId
- Returns:
- the security vulnerability id, by default a CVE id, or another id if no CVE is found
-
setURL
- Parameters:
url
- an external URL providing more details on the vulnerability- Returns:
- the current object
-
getURL
- Returns:
- an external URL providing more details on the vulnerability
-
setSeverityScore
Compute and store the score from the provided CVSS vector.- Parameters:
vector
- a CVSS vector to parse and compute the based score from- Returns:
- the current object
- See Also:
-
getScore
public double getScore()- Returns:
- the CVSS score of the security vulnerability
-
setScore
- Parameters:
score
- the CVSS score of the security vulnerability- Returns:
- the current object
-
getFixVersion
public org.xwiki.extension.version.Version getFixVersion()- Returns:
- the minimal version to which to upgrade to get the issue fixed automatically
-
setFixVersion
public SecurityVulnerabilityDescriptor setFixVersion(org.xwiki.extension.version.Version fixVersion) - Parameters:
fixVersion
- the minimal version to which to upgrade to get the issue fixed automatically- Returns:
- the current object
-
isSafe
@Unstable public boolean isSafe()- Returns:
true
when the extension has some known vulnerabilities, but all are reviewed as safe,false
otherwise- Since:
- 15.6RC1
-
setSafe
- Parameters:
safe
-true
when the extension has some known vulnerabilities, but all are reviewed as safe,false
otherwise- Returns:
- the current object
- Since:
- 15.6RC1
-
getReviews
- Returns:
- the ignored vulnerabilities description, this is an html content containing all the false-positive analysis
- Since:
- 15.6RC1
-
setReviews
- Parameters:
reviews
- the ignored vulnerabilities description, this is an html content containing all the false-positive analysis- Returns:
- the current object
- Since:
- 15.6RC1
-
getAliases
Retrieves the set of aliases associated with the current object.- Returns:
- a set of aliases, used for vulnerability comparison, two vulnerabilities sharing an alias or an id are considered equals
- Since:
- 15.9RC1, 15.5.4
-
setAliases
Sets the set of aliases associated with the current object.- Parameters:
aliases
- a set of aliases, used for vulnerability comparison, two vulnerabilities sharing an alias or an id are considered equals- Returns:
- the current object
- Since:
- 15.9RC1, 15.5.4
-
equals
-
hashCode
public int hashCode() -
toString
-