Class GHVulnerability

java.lang.Object
io.github.coho04.githubapi.bases.GHBase
io.github.coho04.githubapi.entities.GHVulnerability
All Implemented Interfaces:
HttpRequestInterface, JSONHelper

public class GHVulnerability extends GHBase
This class represents a GitHub Vulnerability. It provides methods for fetching data about the vulnerability such as its package, first patched version, vulnerable version range, and vulnerable functions.
  • Constructor Details

    • GHVulnerability

      public GHVulnerability(Github github, org.json.JSONObject jsonObject)
      Constructs a new GHVulnerability instance with the provided JSON object.
      Parameters:
      jsonObject - the JSON object containing the vulnerability data
  • Method Details

    • getGhPackage

      public GHPackage getGhPackage()
      Returns the package of the vulnerability.
      Returns:
      the package of the vulnerability
    • getFirstPatchedVersion

      public String getFirstPatchedVersion()
      Returns the first patched version of the vulnerability.
      Returns:
      the first patched version of the vulnerability
    • getVulnerableVersionRange

      public String getVulnerableVersionRange()
      Returns the vulnerable version range of the vulnerability.
      Returns:
      the vulnerable version range of the vulnerability
    • getVulnerableFunctions

      public List<String> getVulnerableFunctions()
      Returns the vulnerable functions of the vulnerability.
      Returns:
      the vulnerable functions of the vulnerability