Documentation

Google_Service_CloudKMS_Resource_ProjectsLocationsKeyRingsCryptoKeysCryptoKeyVersions extends Google_Service_Resource
in package

The "cryptoKeyVersions" collection of methods.

Typical usage is: $cloudkmsService = new Google_Service_CloudKMS(...); $cryptoKeyVersions = $cloudkmsService->cryptoKeyVersions;

Table of Contents

$client  : Google_Client
$methods  : array<string|int, mixed>
$resourceName  : string
$rootUrl  : string
$serviceName  : string
$servicePath  : string
$stackParameters  : mixed
__construct()  : mixed
asymmetricDecrypt()  : Google_Service_CloudKMS_AsymmetricDecryptResponse
Decrypts data that was encrypted with a public key retrieved from GetPublicKey corresponding to a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_DECRYPT. (cryptoKeyVersions.asymmetricDecrypt)
asymmetricSign()  : Google_Service_CloudKMS_AsymmetricSignResponse
Signs data using a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_SIGN, producing a signature that can be verified with the public key retrieved from GetPublicKey. (cryptoKeyVersions.asymmetricSign)
call()  : Google_Http_Request|expectedClass
TODO: This function needs simplifying.
create()  : Google_Service_CloudKMS_CryptoKeyVersion
Create a new CryptoKeyVersion in a CryptoKey. The server will assign the next sequential id. If unset, state will be set to ENABLED.
createRequestUri()  : string
Parse/expand request parameters and create a fully qualified request uri.
destroy()  : Google_Service_CloudKMS_CryptoKeyVersion
Schedule a CryptoKeyVersion for destruction. Upon calling this method, CryptoKeyVersion.state will be set to DESTROY_SCHEDULED and destroy_time will be set to a time 24 hours in the future, at which point the state will be changed to DESTROYED, and the key material will be irrevocably destroyed.
get()  : Google_Service_CloudKMS_CryptoKeyVersion
Returns metadata for a given CryptoKeyVersion. (cryptoKeyVersions.get)
getPublicKey()  : Google_Service_CloudKMS_PublicKey
Returns the public key for the given CryptoKeyVersion. The CryptoKey.purpose must be ASYMMETRIC_SIGN or ASYMMETRIC_DECRYPT.
import()  : Google_Service_CloudKMS_CryptoKeyVersion
Imports a new CryptoKeyVersion into an existing CryptoKey using the wrapped key material provided in the request. The version ID will be assigned the next sequential id within the CryptoKey. (cryptoKeyVersions.import)
listProjectsLocationsKeyRingsCryptoKeysCryptoKeyVersions()  : Google_Service_CloudKMS_ListCryptoKeyVersionsResponse
Lists CryptoKeyVersions.
patch()  : Google_Service_CloudKMS_CryptoKeyVersion
Update a CryptoKeyVersion's metadata. state may be changed between ENABLED and DISABLED using this method. See DestroyCryptoKeyVersion and RestoreCryptoKeyVersion to move between other states.
restore()  : Google_Service_CloudKMS_CryptoKeyVersion
Restore a CryptoKeyVersion in the DESTROY_SCHEDULED state. Upon restoration of the CryptoKeyVersion, state will be set to DISABLED, and destroy_time will be cleared. (cryptoKeyVersions.restore)
convertToArrayAndStripNulls()  : mixed

Properties

$methods

private array<string|int, mixed> $methods

$resourceName

private string $resourceName

$serviceName

private string $serviceName

$servicePath

private string $servicePath

$stackParameters

private mixed $stackParameters = array('alt' => array('type' => 'string', 'location' => 'query'), 'fields' => array('type' => 'string', 'location' => 'query'), 'trace' => array('type' => 'string', 'location' => 'query'), 'userIp' => array('type' => 'string', 'location' => 'query'), 'quotaUser' => array('type' => 'string', 'location' => 'query'), 'data' => array('type' => 'string', 'location' => 'body'), 'mimeType' => array('type' => 'string', 'location' => 'header'), 'uploadType' => array('type' => 'string', 'location' => 'query'), 'mediaUpload' => array('type' => 'complex', 'location' => 'query'), 'prettyPrint' => array('type' => 'string', 'location' => 'query'))

Methods

__construct()

public __construct(mixed $service, mixed $serviceName, mixed $resourceName, mixed $resource) : mixed
Parameters
$service : mixed
$serviceName : mixed
$resourceName : mixed
$resource : mixed
Return values
mixed

asymmetricDecrypt()

Decrypts data that was encrypted with a public key retrieved from GetPublicKey corresponding to a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_DECRYPT. (cryptoKeyVersions.asymmetricDecrypt)

public asymmetricDecrypt(string $name, Google_Service_CloudKMS_AsymmetricDecryptRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_AsymmetricDecryptResponse
Parameters
$name : string

Required. The resource name of the CryptoKeyVersion to use for decryption.

$postBody : Google_Service_CloudKMS_AsymmetricDecryptRequest
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_CloudKMS_AsymmetricDecryptResponse

asymmetricSign()

Signs data using a CryptoKeyVersion with CryptoKey.purpose ASYMMETRIC_SIGN, producing a signature that can be verified with the public key retrieved from GetPublicKey. (cryptoKeyVersions.asymmetricSign)

public asymmetricSign(string $name, Google_Service_CloudKMS_AsymmetricSignRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_AsymmetricSignResponse
Parameters
$name : string

Required. The resource name of the CryptoKeyVersion to use for signing.

$postBody : Google_Service_CloudKMS_AsymmetricSignRequest
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_CloudKMS_AsymmetricSignResponse

call()

TODO: This function needs simplifying.

public call( $name,  $arguments[,  $expectedClass = null ]) : Google_Http_Request|expectedClass
Parameters
$name :
$arguments :
$expectedClass : = null
  • optional, the expected class name
Tags
throws
Google_Exception
Return values
Google_Http_Request|expectedClass

create()

Create a new CryptoKeyVersion in a CryptoKey. The server will assign the next sequential id. If unset, state will be set to ENABLED.

public create(string $parent, Google_Service_CloudKMS_CryptoKeyVersion $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_CryptoKeyVersion

(cryptoKeyVersions.create)

Parameters
$parent : string

Required. The name of the CryptoKey associated with the CryptoKeyVersions.

$postBody : Google_Service_CloudKMS_CryptoKeyVersion
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_CloudKMS_CryptoKeyVersion

createRequestUri()

Parse/expand request parameters and create a fully qualified request uri.

public createRequestUri(string $restPath, array<string|int, mixed> $params) : string
Parameters
$restPath : string
$params : array<string|int, mixed>
Tags
static
Return values
string

$requestUrl

destroy()

Schedule a CryptoKeyVersion for destruction. Upon calling this method, CryptoKeyVersion.state will be set to DESTROY_SCHEDULED and destroy_time will be set to a time 24 hours in the future, at which point the state will be changed to DESTROYED, and the key material will be irrevocably destroyed.

public destroy(string $name, Google_Service_CloudKMS_DestroyCryptoKeyVersionRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_CryptoKeyVersion

Before the destroy_time is reached, RestoreCryptoKeyVersion may be called to reverse the process. (cryptoKeyVersions.destroy)

Parameters
$name : string

Required. The resource name of the CryptoKeyVersion to destroy.

$postBody : Google_Service_CloudKMS_DestroyCryptoKeyVersionRequest
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_CloudKMS_CryptoKeyVersion

getPublicKey()

Returns the public key for the given CryptoKeyVersion. The CryptoKey.purpose must be ASYMMETRIC_SIGN or ASYMMETRIC_DECRYPT.

public getPublicKey(string $name[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_PublicKey

(cryptoKeyVersions.getPublicKey)

Parameters
$name : string

Required. The name of the CryptoKeyVersion public key to get.

$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_CloudKMS_PublicKey

import()

Imports a new CryptoKeyVersion into an existing CryptoKey using the wrapped key material provided in the request. The version ID will be assigned the next sequential id within the CryptoKey. (cryptoKeyVersions.import)

public import(string $parent, Google_Service_CloudKMS_ImportCryptoKeyVersionRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_CryptoKeyVersion
Parameters
$parent : string

Required. The name of the CryptoKey to be imported into.

$postBody : Google_Service_CloudKMS_ImportCryptoKeyVersionRequest
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_CloudKMS_CryptoKeyVersion

listProjectsLocationsKeyRingsCryptoKeysCryptoKeyVersions()

Lists CryptoKeyVersions.

public listProjectsLocationsKeyRingsCryptoKeysCryptoKeyVersions(string $parent[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_ListCryptoKeyVersionsResponse

(cryptoKeyVersions.listProjectsLocationsKeyRingsCryptoKeysCryptoKeyVersions)

Parameters
$parent : string

Required. The resource name of the CryptoKey to list, in the format projects/locations/keyRings/cryptoKeys.

$optParams : array<string|int, mixed> = array()

Optional parameters.

Tags
opt_param

string filter Optional. Only include resources that match the filter in the response. For more information, see Sorting and filtering list results.

opt_param

int pageSize Optional. Optional limit on the number of CryptoKeyVersions to include in the response. Further CryptoKeyVersions can subsequently be obtained by including the ListCryptoKeyVersionsResponse.next_page_token in a subsequent request. If unspecified, the server will pick an appropriate default.

opt_param

string view The fields to include in the response.

opt_param

string orderBy Optional. Specify how the results should be sorted. If not specified, the results will be sorted in the default order. For more information, see Sorting and filtering list results.

opt_param

string pageToken Optional. Optional pagination token, returned earlier via ListCryptoKeyVersionsResponse.next_page_token.

Return values
Google_Service_CloudKMS_ListCryptoKeyVersionsResponse

patch()

Update a CryptoKeyVersion's metadata. state may be changed between ENABLED and DISABLED using this method. See DestroyCryptoKeyVersion and RestoreCryptoKeyVersion to move between other states.

public patch(string $name, Google_Service_CloudKMS_CryptoKeyVersion $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_CryptoKeyVersion

(cryptoKeyVersions.patch)

Parameters
$name : string

Output only. The resource name for this CryptoKeyVersion in the format projects/locations/keyRings/cryptoKeys/cryptoKeyVersions.

$postBody : Google_Service_CloudKMS_CryptoKeyVersion
$optParams : array<string|int, mixed> = array()

Optional parameters.

Tags
opt_param

string updateMask Required. List of fields to be updated in this request.

Return values
Google_Service_CloudKMS_CryptoKeyVersion

restore()

Restore a CryptoKeyVersion in the DESTROY_SCHEDULED state. Upon restoration of the CryptoKeyVersion, state will be set to DISABLED, and destroy_time will be cleared. (cryptoKeyVersions.restore)

public restore(string $name, Google_Service_CloudKMS_RestoreCryptoKeyVersionRequest $postBody[, array<string|int, mixed> $optParams = array() ]) : Google_Service_CloudKMS_CryptoKeyVersion
Parameters
$name : string

Required. The resource name of the CryptoKeyVersion to restore.

$postBody : Google_Service_CloudKMS_RestoreCryptoKeyVersionRequest
$optParams : array<string|int, mixed> = array()

Optional parameters.

Return values
Google_Service_CloudKMS_CryptoKeyVersion

convertToArrayAndStripNulls()

protected convertToArrayAndStripNulls(mixed $o) : mixed
Parameters
$o : mixed
Return values
mixed

Search results