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.18

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.18
File Size Uploaded Provenance Actions
ash_kms-0.1.18.tar.gz 3.1 kB Without provenance Details for ash_kms-0.1.18.tar.gz

Built distribution (wheel)

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

Total release size: 6.6 kB

Release files / ash_kms-0.1.18.tar.gz

Download URL ash_kms-0.1.18.tar.gz
Size 3.1 kB
Tags Source
SHA-256 checksum
How to use checksums
c87ec20e6357f1e72d1f01c68e0a4d07ba2a9928ddf6bea1067ec963dfab55c5
BLAKE2b-256 checksum
How to use checksums
abce3c5313d469d6cf57cec9e59b8a6035c82339e7c00a50c7e4f67120b8c1c7
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.18-py3-none-any.whl

Download URL ash_kms-0.1.18-py3-none-any.whl
Size 3.5 kB
Tags Python 3
SHA-256 checksum
How to use checksums
30e036dafd9b136f83d1491598164531bf96d03083af3cbe0dbd83b23652e0b5
BLAKE2b-256 checksum
How to use checksums
0c8c5e05d81d372bd6de0c7441a3245744afa4e5c013dca350f7a938d8d10feb
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.18

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