Skip to main content

ash-kms

The library provides functionality to handle GCP KMS encryption keys and operations

  • The library allows the creation of a new key-ring within GCP KMS.
  • The library allows the creation of a new encryption key within GCP KMS.
  • The library provides functionality to encrypt secrets using the specified encryption key.
  • Users can decrypt secrets using the specified encryption key.

Installation

pip install ash-kms

Usage

from ash_kms import EncryptionService

key_ring_id = "test_key_ring_id"
key_id = "test_key"
location_id = "global"
plaintext = "asdf1234"

service = EncryptionService(project_id="ash-dev-273120")

key_ring_name = service.create_key_ring(location_id=location_id, key_ring_id=key_ring_id)
print(key_ring_name)

key = service.create_key_symmetric_encrypt_decrypt(location_id=location_id, key_ring_id=key_ring_id, key_id=key_id)
print(key.name)

ciphertext = service.encrypt_symmetric(location_id=location_id, key_ring_id=key_ring_id, key_id=key_id,
                                       plaintext=plaintext)

print(f"{ciphertext=}")
decrypted_plaintext = service.decrypt_symmetric(location_id=location_id, key_ring_id=key_ring_id, key_id=key_id,
                                                ciphertext=ciphertext)

print(f"{plaintext=}")

assert decrypted_plaintext == plaintext

Metadata

Release files for ash-kms 0.1.17

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for ash-kms 0.1.17
File Size Uploaded Provenance Actions
ash_kms-0.1.17.tar.gz 3.1 kB Without provenance Details for ash_kms-0.1.17.tar.gz

Built distribution (wheel)

Table of built distributions (wheels) for ash-kms 0.1.17
File Interpreter ABI Platform Actions
ash_kms-0.1.17-py3-none-any.whl Python 3 none any Details for ash_kms-0.1.17-py3-none-any.whl

Total release size: 6.6 kB

Release files / ash_kms-0.1.17.tar.gz

Download URL ash_kms-0.1.17.tar.gz
Size 3.1 kB
Tags Source
SHA-256 checksum
How to use checksums
da8835c24cd48372db8e028e41641a909d3103d051ac8fe0a0ab3bb4d81d280c
BLAKE2b-256 checksum
How to use checksums
a47374d1710b5820ffd57f182f249f3a736b4063388377cbf75e26210261398b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.13 {"installer":{"name":"uv","version":"0.11.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Release files / ash_kms-0.1.17-py3-none-any.whl

Download URL ash_kms-0.1.17-py3-none-any.whl
Size 3.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
b5a9d719e8f684da7559ae964c962b369b98261d5df4d408dadfc6a8408d4f6c
BLAKE2b-256 checksum
How to use checksums
89df0ace5fd44d101ee080f8c57826d6da20143f74580605094f3d7b1fbbbc1a
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.13 {"installer":{"name":"uv","version":"0.11.13","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

Security for ash-kms 0.1.17

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page