All Downloads are FREE. Search and download functionalities are using the official Maven repository.
Please wait. This can take some minutes ...
Many resources are needed to download a project. Please understand that we have to compensate our server costs. Thank you in advance.
Project price only 1 $
You can buy this project and download/modify it how often you want.
com.huaweicloud.sdk.hss.v5.model.VulInfo Maven / Gradle / Ivy
package com.huaweicloud.sdk.hss.v5.model;
import com.fasterxml.jackson.annotation.JsonInclude;
import com.fasterxml.jackson.annotation.JsonProperty;
import java.util.ArrayList;
import java.util.List;
import java.util.Objects;
import java.util.function.Consumer;
/**
* 漏洞列表
*/
public class VulInfo {
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "vul_name")
private String vulName;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "vul_id")
private String vulId;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "label_list")
private List labelList = null;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "repair_necessity")
private String repairNecessity;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "severity_level")
private String severityLevel;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "host_num")
private Integer hostNum;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "unhandle_host_num")
private Integer unhandleHostNum;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "scan_time")
private Long scanTime;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "solution_detail")
private String solutionDetail;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "url")
private String url;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "description")
private String description;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "type")
private String type;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "host_id_list")
private List hostIdList = null;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "cve_list")
private List cveList = null;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "patch_url")
private String patchUrl;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "repair_priority")
private String repairPriority;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "hosts_num")
private VulnerabilityHostNumberInfo hostsNum;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "repair_success_num")
private Integer repairSuccessNum;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "fixed_num")
private Long fixedNum;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "ignored_num")
private Long ignoredNum;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "verify_num")
private Integer verifyNum;
@JsonInclude(JsonInclude.Include.NON_NULL)
@JsonProperty(value = "repair_priority_list")
private List repairPriorityList = null;
public VulInfo withVulName(String vulName) {
this.vulName = vulName;
return this;
}
/**
* 漏洞名称
* @return vulName
*/
public String getVulName() {
return vulName;
}
public void setVulName(String vulName) {
this.vulName = vulName;
}
public VulInfo withVulId(String vulId) {
this.vulId = vulId;
return this;
}
/**
* 漏洞ID
* @return vulId
*/
public String getVulId() {
return vulId;
}
public void setVulId(String vulId) {
this.vulId = vulId;
}
public VulInfo withLabelList(List labelList) {
this.labelList = labelList;
return this;
}
public VulInfo addLabelListItem(String labelListItem) {
if (this.labelList == null) {
this.labelList = new ArrayList<>();
}
this.labelList.add(labelListItem);
return this;
}
public VulInfo withLabelList(Consumer> labelListSetter) {
if (this.labelList == null) {
this.labelList = new ArrayList<>();
}
labelListSetter.accept(this.labelList);
return this;
}
/**
* 漏洞标签
* @return labelList
*/
public List getLabelList() {
return labelList;
}
public void setLabelList(List labelList) {
this.labelList = labelList;
}
public VulInfo withRepairNecessity(String repairNecessity) {
this.repairNecessity = repairNecessity;
return this;
}
/**
* 修复必要性 - Critical : 漏洞cvss评分大于等于9;对应控制台页面的高危 - High : 漏洞cvss评分大于等于7,小于9;对应控制台页面的中危 - Medium : 漏洞cvss评分大于等于4,小于7;对应控制台页面的中危 - Low : 漏洞cvss评分小于4;对应控制台页面的低危
* @return repairNecessity
*/
public String getRepairNecessity() {
return repairNecessity;
}
public void setRepairNecessity(String repairNecessity) {
this.repairNecessity = repairNecessity;
}
public VulInfo withSeverityLevel(String severityLevel) {
this.severityLevel = severityLevel;
return this;
}
/**
* 漏洞级别 - Critical : 漏洞cvss评分大于等于9;对应控制台页面的高危 - High : 漏洞cvss评分大于等于7,小于9;对应控制台页面的中危 - Medium : 漏洞cvss评分大于等于4,小于7;对应控制台页面的中危 - Low : 漏洞cvss评分小于4;对应控制台页面的低危
* @return severityLevel
*/
public String getSeverityLevel() {
return severityLevel;
}
public void setSeverityLevel(String severityLevel) {
this.severityLevel = severityLevel;
}
public VulInfo withHostNum(Integer hostNum) {
this.hostNum = hostNum;
return this;
}
/**
* 受影响服务器台数
* minimum: 0
* maximum: 2147483647
* @return hostNum
*/
public Integer getHostNum() {
return hostNum;
}
public void setHostNum(Integer hostNum) {
this.hostNum = hostNum;
}
public VulInfo withUnhandleHostNum(Integer unhandleHostNum) {
this.unhandleHostNum = unhandleHostNum;
return this;
}
/**
* 未处理主机台数,除已忽略和已修复的主机数量
* minimum: 0
* maximum: 2147483647
* @return unhandleHostNum
*/
public Integer getUnhandleHostNum() {
return unhandleHostNum;
}
public void setUnhandleHostNum(Integer unhandleHostNum) {
this.unhandleHostNum = unhandleHostNum;
}
public VulInfo withScanTime(Long scanTime) {
this.scanTime = scanTime;
return this;
}
/**
* 最近扫描时间,时间戳单位:毫秒
* minimum: 0
* maximum: 9223372036854775807
* @return scanTime
*/
public Long getScanTime() {
return scanTime;
}
public void setScanTime(Long scanTime) {
this.scanTime = scanTime;
}
public VulInfo withSolutionDetail(String solutionDetail) {
this.solutionDetail = solutionDetail;
return this;
}
/**
* 修复漏洞的指导意见
* @return solutionDetail
*/
public String getSolutionDetail() {
return solutionDetail;
}
public void setSolutionDetail(String solutionDetail) {
this.solutionDetail = solutionDetail;
}
public VulInfo withUrl(String url) {
this.url = url;
return this;
}
/**
* URL链接
* @return url
*/
public String getUrl() {
return url;
}
public void setUrl(String url) {
this.url = url;
}
public VulInfo withDescription(String description) {
this.description = description;
return this;
}
/**
* 漏洞描述
* @return description
*/
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public VulInfo withType(String type) {
this.type = type;
return this;
}
/**
* 漏洞类型,包含如下: -linux_vul : linux漏洞 -windows_vul : windows漏洞 -web_cms : Web-CMS漏洞 -app_vul : 应用漏洞
* @return type
*/
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public VulInfo withHostIdList(List hostIdList) {
this.hostIdList = hostIdList;
return this;
}
public VulInfo addHostIdListItem(String hostIdListItem) {
if (this.hostIdList == null) {
this.hostIdList = new ArrayList<>();
}
this.hostIdList.add(hostIdListItem);
return this;
}
public VulInfo withHostIdList(Consumer> hostIdListSetter) {
if (this.hostIdList == null) {
this.hostIdList = new ArrayList<>();
}
hostIdListSetter.accept(this.hostIdList);
return this;
}
/**
* 可处置该漏洞的主机列表
* @return hostIdList
*/
public List getHostIdList() {
return hostIdList;
}
public void setHostIdList(List hostIdList) {
this.hostIdList = hostIdList;
}
public VulInfo withCveList(List cveList) {
this.cveList = cveList;
return this;
}
public VulInfo addCveListItem(VulInfoCveList cveListItem) {
if (this.cveList == null) {
this.cveList = new ArrayList<>();
}
this.cveList.add(cveListItem);
return this;
}
public VulInfo withCveList(Consumer> cveListSetter) {
if (this.cveList == null) {
this.cveList = new ArrayList<>();
}
cveListSetter.accept(this.cveList);
return this;
}
/**
* CVE列表
* @return cveList
*/
public List getCveList() {
return cveList;
}
public void setCveList(List cveList) {
this.cveList = cveList;
}
public VulInfo withPatchUrl(String patchUrl) {
this.patchUrl = patchUrl;
return this;
}
/**
* 补丁地址
* @return patchUrl
*/
public String getPatchUrl() {
return patchUrl;
}
public void setPatchUrl(String patchUrl) {
this.patchUrl = patchUrl;
}
public VulInfo withRepairPriority(String repairPriority) {
this.repairPriority = repairPriority;
return this;
}
/**
* 修复优先级 Critical 紧急 High 高 Medium 中 Low 低
* @return repairPriority
*/
public String getRepairPriority() {
return repairPriority;
}
public void setRepairPriority(String repairPriority) {
this.repairPriority = repairPriority;
}
public VulInfo withHostsNum(VulnerabilityHostNumberInfo hostsNum) {
this.hostsNum = hostsNum;
return this;
}
public VulInfo withHostsNum(Consumer hostsNumSetter) {
if (this.hostsNum == null) {
this.hostsNum = new VulnerabilityHostNumberInfo();
hostsNumSetter.accept(this.hostsNum);
}
return this;
}
/**
* Get hostsNum
* @return hostsNum
*/
public VulnerabilityHostNumberInfo getHostsNum() {
return hostsNum;
}
public void setHostsNum(VulnerabilityHostNumberInfo hostsNum) {
this.hostsNum = hostsNum;
}
public VulInfo withRepairSuccessNum(Integer repairSuccessNum) {
this.repairSuccessNum = repairSuccessNum;
return this;
}
/**
* 修复成功次数
* minimum: 0
* maximum: 1000000
* @return repairSuccessNum
*/
public Integer getRepairSuccessNum() {
return repairSuccessNum;
}
public void setRepairSuccessNum(Integer repairSuccessNum) {
this.repairSuccessNum = repairSuccessNum;
}
public VulInfo withFixedNum(Long fixedNum) {
this.fixedNum = fixedNum;
return this;
}
/**
* 修复数量
* minimum: 0
* maximum: 1000000
* @return fixedNum
*/
public Long getFixedNum() {
return fixedNum;
}
public void setFixedNum(Long fixedNum) {
this.fixedNum = fixedNum;
}
public VulInfo withIgnoredNum(Long ignoredNum) {
this.ignoredNum = ignoredNum;
return this;
}
/**
* 忽略数量
* minimum: 0
* maximum: 1000000
* @return ignoredNum
*/
public Long getIgnoredNum() {
return ignoredNum;
}
public void setIgnoredNum(Long ignoredNum) {
this.ignoredNum = ignoredNum;
}
public VulInfo withVerifyNum(Integer verifyNum) {
this.verifyNum = verifyNum;
return this;
}
/**
* 验证数量
* minimum: 0
* maximum: 1000000
* @return verifyNum
*/
public Integer getVerifyNum() {
return verifyNum;
}
public void setVerifyNum(Integer verifyNum) {
this.verifyNum = verifyNum;
}
public VulInfo withRepairPriorityList(List repairPriorityList) {
this.repairPriorityList = repairPriorityList;
return this;
}
public VulInfo addRepairPriorityListItem(RepairPriorityListInfo repairPriorityListItem) {
if (this.repairPriorityList == null) {
this.repairPriorityList = new ArrayList<>();
}
this.repairPriorityList.add(repairPriorityListItem);
return this;
}
public VulInfo withRepairPriorityList(Consumer> repairPriorityListSetter) {
if (this.repairPriorityList == null) {
this.repairPriorityList = new ArrayList<>();
}
repairPriorityListSetter.accept(this.repairPriorityList);
return this;
}
/**
* 修复优先级,每个修复优先级对应的主机数量
* @return repairPriorityList
*/
public List getRepairPriorityList() {
return repairPriorityList;
}
public void setRepairPriorityList(List repairPriorityList) {
this.repairPriorityList = repairPriorityList;
}
@Override
public boolean equals(java.lang.Object obj) {
if (this == obj) {
return true;
}
if (obj == null || getClass() != obj.getClass()) {
return false;
}
VulInfo that = (VulInfo) obj;
return Objects.equals(this.vulName, that.vulName) && Objects.equals(this.vulId, that.vulId)
&& Objects.equals(this.labelList, that.labelList)
&& Objects.equals(this.repairNecessity, that.repairNecessity)
&& Objects.equals(this.severityLevel, that.severityLevel) && Objects.equals(this.hostNum, that.hostNum)
&& Objects.equals(this.unhandleHostNum, that.unhandleHostNum)
&& Objects.equals(this.scanTime, that.scanTime) && Objects.equals(this.solutionDetail, that.solutionDetail)
&& Objects.equals(this.url, that.url) && Objects.equals(this.description, that.description)
&& Objects.equals(this.type, that.type) && Objects.equals(this.hostIdList, that.hostIdList)
&& Objects.equals(this.cveList, that.cveList) && Objects.equals(this.patchUrl, that.patchUrl)
&& Objects.equals(this.repairPriority, that.repairPriority) && Objects.equals(this.hostsNum, that.hostsNum)
&& Objects.equals(this.repairSuccessNum, that.repairSuccessNum)
&& Objects.equals(this.fixedNum, that.fixedNum) && Objects.equals(this.ignoredNum, that.ignoredNum)
&& Objects.equals(this.verifyNum, that.verifyNum)
&& Objects.equals(this.repairPriorityList, that.repairPriorityList);
}
@Override
public int hashCode() {
return Objects.hash(vulName,
vulId,
labelList,
repairNecessity,
severityLevel,
hostNum,
unhandleHostNum,
scanTime,
solutionDetail,
url,
description,
type,
hostIdList,
cveList,
patchUrl,
repairPriority,
hostsNum,
repairSuccessNum,
fixedNum,
ignoredNum,
verifyNum,
repairPriorityList);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class VulInfo {\n");
sb.append(" vulName: ").append(toIndentedString(vulName)).append("\n");
sb.append(" vulId: ").append(toIndentedString(vulId)).append("\n");
sb.append(" labelList: ").append(toIndentedString(labelList)).append("\n");
sb.append(" repairNecessity: ").append(toIndentedString(repairNecessity)).append("\n");
sb.append(" severityLevel: ").append(toIndentedString(severityLevel)).append("\n");
sb.append(" hostNum: ").append(toIndentedString(hostNum)).append("\n");
sb.append(" unhandleHostNum: ").append(toIndentedString(unhandleHostNum)).append("\n");
sb.append(" scanTime: ").append(toIndentedString(scanTime)).append("\n");
sb.append(" solutionDetail: ").append(toIndentedString(solutionDetail)).append("\n");
sb.append(" url: ").append(toIndentedString(url)).append("\n");
sb.append(" description: ").append(toIndentedString(description)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
sb.append(" hostIdList: ").append(toIndentedString(hostIdList)).append("\n");
sb.append(" cveList: ").append(toIndentedString(cveList)).append("\n");
sb.append(" patchUrl: ").append(toIndentedString(patchUrl)).append("\n");
sb.append(" repairPriority: ").append(toIndentedString(repairPriority)).append("\n");
sb.append(" hostsNum: ").append(toIndentedString(hostsNum)).append("\n");
sb.append(" repairSuccessNum: ").append(toIndentedString(repairSuccessNum)).append("\n");
sb.append(" fixedNum: ").append(toIndentedString(fixedNum)).append("\n");
sb.append(" ignoredNum: ").append(toIndentedString(ignoredNum)).append("\n");
sb.append(" verifyNum: ").append(toIndentedString(verifyNum)).append("\n");
sb.append(" repairPriorityList: ").append(toIndentedString(repairPriorityList)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}