Add support for blob-level KMS encryption keys#5221
Conversation
Allow passing only one of 'encryption_key' or 'kms_encryption_key'.
|
|
||
| :type kms_encryption_key: bytes | ||
| :param kms_encryption_key: | ||
| Optional esource name of Cloud KMS key used to encrypt the blob's |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
frankyn
left a comment
There was a problem hiding this comment.
Similar to default_kms_key_name: Could you add tests which exercise the client library with GCS?
Additional tests to add:
- After rotating from CSEK to CMEK, verify the contents of the object are readable on a download.
| See https://cloud.google.com/storage/docs/encryption#customer-supplied. | ||
|
|
||
| :type kms_encryption_key: bytes | ||
| :param kms_encryption_key: |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
| download_url = blob._get_download_url() | ||
| expected_url = ( | ||
| 'https://www.googleapis.com/download/storage/v1/b/' | ||
| 'buhkit/o/bzzz-fly.txt?alt=media&{}'.format(kms_encoded)) |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
The server already knows that value.
| download_url = blob._get_download_url() | ||
| expected_url = ( | ||
| 'https://www.googleapis.com/download/storage/v1/b/' | ||
| 'buhkit/o/bzzz-fly.txt?alt=media') # kmsKeyName *not* expected |
This comment was marked as spam.
This comment was marked as spam.
Sorry, something went wrong.
|
@dpebot please merge when green. |
|
Okay! I'll merge when all statuses are green and all reviewers approve. |
|
She's been having some trouble with automerge lately, so let's see if it actually works. |
|
Merging in spite of unrelated logging systest failures. |
No description provided.