Skip to main content
https://github.com/razorpay/alohomora/actions/workflows/ci.yml/badge.svg

Razorpay’s Secret Credential management system.

Installation

alohomora is distributed via PyPi:

pip install razorpay.alohomora

What?

Alohomora is an opinionated project that relies on our conventions to intelligently fetch secrets at run-time.

We don’t do our own crypto. We rely on these libraries instead:

This is how the template file looks in our app repository:

# {{ alohomora_managed }}
DB_PASSWORD      = {{ lookup('db_password') }}
APP_ENV          = {{ env }}
ENV_DEBUG        = {{ ENV['DEBUG'] }}
APP_NAME         = {{ app }}

This repo runs directly on the same template and generates the equivalent file as the output.

The steps it follows are the following:

  1. Figure out the tables from which to read. All secrets are stored in a credstash-env-app table structure in dynamoDB.

  2. Fetch all secrets from that table using credstash

  3. Render the template with the secrets using jinja

How it Works?

Alohomora expects the secrets for any application to be stored in a table called credstash-{env}-{app}. The IAM roles for this table must be configured by you. Once you try to render a template, alohomora will do the following:

  1. Read the entire table and decrypt all secrets and cache them locally.

  2. Render the template with these files and 3 extra variables: env, app, and ENV variables.

ENV is same as os.environ inside the jinja template.

Configuration?

Alohomora is designed to be a zero-config solution.

We perform a few transforms on the arguments that are passed:

  • Change both app and env to lowercase

  • Replace production with prod in the env name

  • Ignore anything after - in the environment. So beta-birdie becomes beta

Usage

Please see the wiki regarding alohomora binary usage.

LICENSE

alohomora is released under the same license as credstash.

Metadata

Release files for razorpay.alohomora 0.5.0

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

Built distribution (wheel)

Table of built distributions (wheels) for razorpay.alohomora 0.5.0
File Interpreter ABI Platform
razorpay.alohomora-0.5.0-py3-none-any.whl Python 3 none any Details

Release files / razorpay.alohomora-0.5.0-py3-none-any.whl

Download URL razorpay.alohomora-0.5.0-py3-none-any.whl
Size 8.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
1af23387688cd35123ff6d7415b26f7a44590144c999bb63d9b1468e16c7e87f
BLAKE2b-256 checksum
How to use checksums
6041cf3083b931c80b7337f695cfabe939cecb1d93362e4c1930608d6b7f1f58
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/3.6.0 importlib_metadata/4.8.1 pkginfo/1.8.3 requests/2.28.1 requests-toolbelt/0.9.1 tqdm/4.64.0 CPython/3.10.6

Security for razorpay.alohomora 0.5.0

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