# Cloud KMS V1 Client - Class KeyOperationAttestation (2.9.0)

2.9.0 (latest) 2.8.0 2.7.0 2.6.0 2.5.2 2.4.0 2.3.1 2.2.0 2.1.6 2.0.0 1.23.0 1.22.1 1.21.4 1.20.3 1.19.0 1.18.1 1.17.0 1.16.4 1.15.3 Reference documentation and code samples for the Cloud KMS V1 Client class KeyOperationAttestation.

Contains an HSM-generated attestation about a key operation. For more
information, see [Verifying attestations](https://cloud.google.com/kms/docs/attest-key).

Generated from protobuf message `google.cloud.kms.v1.KeyOperationAttestation`

## Namespace

Google \\ Cloud \\ Kms \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ format` | `int` Output only. The format of the attestation data. |
| `↳ content` | `string` Output only. The attestation data provided by the HSM when the key operation was performed. |
| `↳ cert_chains` | `https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.KeyOperationAttestation.CertificateChains` Output only. The certificate chains needed to validate the attestation |

### getFormat

Output only. The format of the attestation data.

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `int` | Enum of type [AttestationFormat](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.KeyOperationAttestation.AttestationFormat). |

### setFormat

Output only. The format of the attestation data.

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `int` Enum of type [AttestationFormat](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.KeyOperationAttestation.AttestationFormat). |

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

### getContent

Output only. The attestation data provided by the HSM when the key
operation was performed.

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

### setContent

Output only. The attestation data provided by the HSM when the key
operation was performed.

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

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

### getCertChains

Output only. The certificate chains needed to validate the attestation

| **Returns** ||
|---|---|
| **Type** | **Description** |
| `https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.KeyOperationAttestation.CertificateChains|null` |   |

### hasCertChains

### clearCertChains

### setCertChains

Output only. The certificate chains needed to validate the attestation

| **Parameter** ||
|---|---|
| **Name** | **Description** |
| `var` | `https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.KeyOperationAttestation.CertificateChains` |

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