# Google Cloud Security Command Center V2 Client - Class Vulnerability (2.5.1)

2.5.1 (latest) 2.5.0 2.4.2 2.3.0 2.2.1 2.1.1 2.0.4 1.32.0 1.31.0 1.30.0 1.29.0 1.28.2 1.21.0 1.20.2 1.19.1 1.18.0 1.17.0 1.16.0 1.15.1 1.14.2 1.13.1 Reference documentation and code samples for the Google Cloud Security Command Center V2 Client class Vulnerability.

Refers to common vulnerability fields e.g. cve, cvss, cwe etc.

Generated from protobuf message `google.cloud.securitycenter.v2.Vulnerability`

## Namespace

Google \\ Cloud \\ SecurityCenter \\ V2

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ cve` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Cve` CVE stands for Common Vulnerabilities and Exposures (<https://cve.mitre.org/about/>) |
| `↳ offending_package` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Package` The offending package is relevant to the finding. |
| `↳ fixed_package` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Package` The fixed package is relevant to the finding. |
| `↳ security_bulletin` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.SecurityBulletin` The security bulletin is relevant to this finding. |
| `↳ provider_risk_score` | `int|string` Provider provided risk_score based on multiple factors. The higher the risk score, the more risky the vulnerability is. |
| `↳ reachable` | `bool` Represents whether the vulnerability is reachable (detected via static analysis) |
| `↳ cwes` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Cwe>` Represents one or more Common Weakness Enumeration (CWE) information on this vulnerability. |

### getCve

CVE stands for Common Vulnerabilities and Exposures
(<https://cve.mitre.org/about/>)

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Cve|null` |   |

### hasCve

### clearCve

### setCve

CVE stands for Common Vulnerabilities and Exposures
(<https://cve.mitre.org/about/>)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Cve` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getOffendingPackage

The offending package is relevant to the finding.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Package|null` |   |

### hasOffendingPackage

### clearOffendingPackage

### setOffendingPackage

The offending package is relevant to the finding.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Package` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getFixedPackage

The fixed package is relevant to the finding.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Package|null` |   |

### hasFixedPackage

### clearFixedPackage

### setFixedPackage

The fixed package is relevant to the finding.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Package` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getSecurityBulletin

The security bulletin is relevant to this finding.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.SecurityBulletin|null` |   |

### hasSecurityBulletin

### clearSecurityBulletin

### setSecurityBulletin

The security bulletin is relevant to this finding.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.SecurityBulletin` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getProviderRiskScore

Provider provided risk_score based on multiple factors. The higher the risk
score, the more risky the vulnerability is.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int|string` |   |

### setProviderRiskScore

Provider provided risk_score based on multiple factors. The higher the risk
score, the more risky the vulnerability is.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int|string` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getReachable

Represents whether the vulnerability is reachable (detected via static
analysis)

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `bool` |   |

### setReachable

Represents whether the vulnerability is reachable (detected via static
analysis)

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `bool` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |

### getCwes

Represents one or more Common Weakness Enumeration (CWE) information on
this vulnerability.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://protobuf.dev/reference/php/api-docs/Google/Protobuf/RepeatedField<https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Cwe>` |   |

### setCwes

Represents one or more Common Weakness Enumeration (CWE) information on
this vulnerability.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `array<https://docs.cloud.google.com/php/docs/reference/cloud-security-center/latest/V2.Cwe>` |

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `$this` |   |