# Cloud KMS V1 Client - Class MacVerifyResponse (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 MacVerifyResponse.

Response message for
[KeyManagementService.MacVerify](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient#_Google_Cloud_Kms_V1_Client_KeyManagementServiceClient__macVerify__).

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

## Namespace

Google \\ Cloud \\ Kms \\ V1

## Methods

### __construct

Constructor.

| **Parameters** ||
|---|---|
| **Name** | **Description** |
| `data` | `array` Optional. Data for populating the Message object. |
| `↳ name` | `string` The resource name of the [CryptoKeyVersion](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.CryptoKeyVersion) used for verification. Check this field to verify that the intended resource was used for verification. |
| `↳ success` | `bool` This field indicates whether or not the verification operation for [MacVerifyRequest.mac](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getMac__) over [MacVerifyRequest.data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getData__) was successful. |
| `↳ verified_data_crc32c` | `bool` Integrity verification field. A flag indicating whether MacVerifyRequest.data_crc32c was received by [KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient) and used for the integrity verification of the [data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getData__). A false value of this field indicates either that MacVerifyRequest.data_crc32c was left unset or that it was not delivered to [KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient). If you've set MacVerifyRequest.data_crc32c but this field is still false, discard the response and perform a limited number of retries. |
| `↳ verified_mac_crc32c` | `bool` Integrity verification field. A flag indicating whether MacVerifyRequest.mac_crc32c was received by [KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient) and used for the integrity verification of the [data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getMac__). A false value of this field indicates either that MacVerifyRequest.mac_crc32c was left unset or that it was not delivered to [KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient). If you've set MacVerifyRequest.mac_crc32c but this field is still false, discard the response and perform a limited number of retries. |
| `↳ verified_success_integrity` | `bool` Integrity verification field. This value is used for the integrity verification of \[MacVerifyResponse.success\]. If the value of this field contradicts the value of \[MacVerifyResponse.success\], discard the response and perform a limited number of retries. |
| `↳ protection_level` | `int` The [ProtectionLevel](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.ProtectionLevel) of the [CryptoKeyVersion](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.CryptoKeyVersion) used for verification. |

### getName

The resource name of the
[CryptoKeyVersion](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.CryptoKeyVersion) used for
verification. Check this field to verify that the intended resource was
used for verification.

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

### setName

The resource name of the
[CryptoKeyVersion](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.CryptoKeyVersion) used for
verification. Check this field to verify that the intended resource was
used for verification.

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

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

### getSuccess

This field indicates whether or not the verification operation for
[MacVerifyRequest.mac](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getMac__) over
[MacVerifyRequest.data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getData__) was
successful.

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

### setSuccess

This field indicates whether or not the verification operation for
[MacVerifyRequest.mac](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getMac__) over
[MacVerifyRequest.data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getData__) was
successful.

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

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

### getVerifiedDataCrc32C

Integrity verification field. A flag indicating whether
MacVerifyRequest.data_crc32c
was received by
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient) and used
for the integrity verification of the
[data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getData__). A false value of this
field indicates either that
MacVerifyRequest.data_crc32c
was left unset or that it was not delivered to
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient). If you've
set
MacVerifyRequest.data_crc32c
but this field is still false, discard the response and perform a limited
number of retries.

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

### setVerifiedDataCrc32C

Integrity verification field. A flag indicating whether
MacVerifyRequest.data_crc32c
was received by
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient) and used
for the integrity verification of the
[data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getData__). A false value of this
field indicates either that
MacVerifyRequest.data_crc32c
was left unset or that it was not delivered to
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient). If you've
set
MacVerifyRequest.data_crc32c
but this field is still false, discard the response and perform a limited
number of retries.

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

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

### getVerifiedMacCrc32C

Integrity verification field. A flag indicating whether
MacVerifyRequest.mac_crc32c
was received by
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient) and used
for the integrity verification of the
[data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getMac__). A false value of this
field indicates either that
MacVerifyRequest.mac_crc32c
was left unset or that it was not delivered to
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient). If you've
set
MacVerifyRequest.mac_crc32c
but this field is still false, discard the response and perform a limited
number of retries.

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

### setVerifiedMacCrc32C

Integrity verification field. A flag indicating whether
MacVerifyRequest.mac_crc32c
was received by
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient) and used
for the integrity verification of the
[data](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.MacVerifyRequest#_Google_Cloud_Kms_V1_MacVerifyRequest__getMac__). A false value of this
field indicates either that
MacVerifyRequest.mac_crc32c
was left unset or that it was not delivered to
[KeyManagementService](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.Client.KeyManagementServiceClient). If you've
set
MacVerifyRequest.mac_crc32c
but this field is still false, discard the response and perform a limited
number of retries.

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

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

### getVerifiedSuccessIntegrity

Integrity verification field. This value is used for the integrity
verification of \[MacVerifyResponse.success\]. If the value of this field
contradicts the value of \[MacVerifyResponse.success\], discard the response
and perform a limited number of retries.

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

### setVerifiedSuccessIntegrity

Integrity verification field. This value is used for the integrity
verification of \[MacVerifyResponse.success\]. If the value of this field
contradicts the value of \[MacVerifyResponse.success\], discard the response
and perform a limited number of retries.

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

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

### getProtectionLevel

The [ProtectionLevel](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.ProtectionLevel) of the
[CryptoKeyVersion](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.CryptoKeyVersion) used for
verification.

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

### setProtectionLevel

The [ProtectionLevel](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.ProtectionLevel) of the
[CryptoKeyVersion](https://docs.cloud.google.com/php/docs/reference/cloud-kms/latest/V1.CryptoKeyVersion) used for
verification.

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

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