Downloading Public Key for an Asymmetric Version
Use the post /v1/cckm/google/keys/{id}/versions/{versionID}/download-public-key
API to download a public key for an asymmetric key version. The public key encoded in the PEM format is downloaded.
Syntax
curl -k '<IP>/api/v1/cckm/google/keys/{id}/versions/{versionID}/download-public-key' -X POST -H 'Authorization: Bearer AUTHTOKEN' --compressed
Here, {id}
represents the resource ID of the parent Google Cloud key and {versionID}
represents the resource ID of the key version for which the public key is to be downloaded.
Request Parameters
Parameter | Type | Description |
---|---|---|
AUTHTOKEN | string | Authorization token. |
Example Request
curl -k 'https://127.0.0.1/api/v1/cckm/google/keys/ecc73bfb-7605-4263-abb8-84fe431d35fb/versions/e2f79e23-749d-4579-bef1-5777a4651e9e/download-public-key' -X POST -H 'Authorization: Bearer eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJhOGY3N2IxZS1lOTY2LTQwMjEtODRjMC01YjZiNjAzMTBmOWEiLCJzdWIiOiJsb2NhbHwzM2Y5ZDFmNi04MjJiLTQ0NTItOGM4MC1mYzM0ZGYyZTI3OGQiLCJpc3MiOiJreWxvIiwiYWNjIjoia3lsbyIsInByZWZlcnJlZF91c2VybmFtZSI6ImFkbWluIiwiY3VzdCI6eyJkb21haW5faWQiOiIwMDAwMDAwMC0wMDAwLTAwMDAtMDAwMC0wMDAwMDAwMDAwMDAiLCJncm91cHMiOlsiYWRtaW4iXSwic2lkIjoiNjcyMjMzMDAtYjU2ZC00ZmVmLTkwMDEtZGE1NGY2ZDdiMzY4Iiwiem9uZV9pZCI6IjAwMDAwMDAwLTAwMDAtMDAwMC0wMDAwLTAwMDAwMDAwMDAwMCJ9LCJqd3RpZCI6IjIxYmU3YjRiLTE3ZmQtNDgzNS1hYjM1LTI2NzJkMTRlOGNlZiIsImlhdCI6MTYyMDIwMzEyMywiZXhwIjoxNjIwMjAzNDIzfQ.r7x84REJtfPZrdEQrGK-VJG1cYhHKggOVZYZ5whUMiU' --compressed
Example Response
The public key of the specified key version is downloaded. The public key is encoded in the PEM format.
Response Codes
Response Code | Description |
---|---|
2xx | Success |
4xx | Client errors |
5xx | Server errors |
Refer to HTTP status codes for details.