Skip to main content

A secure environment variable manager

Project description

sevn 🔐

A secure environment variable manager built on 7 core principles.

The Seven Principles

  • 🔒 Secure – secrets stay local and encrypted
  • 🎯 Simple – install and go, no setup hell
  • 🎭 Scoped – use profiles, isolate secrets
  • 🔧 Script – CLI-first, shell-native
  • 📦 Share – encrypted blob = portable
  • Speed – decrypt only what you need
  • 🌐 State – no server, no risk surface

Installation

pip install sevn

Requires Python 3.9 or higher.

Quick Start

  1. Lock a secret in a profile:
sevn lock STRIPE_KEY=sk_test_123 --profile myproject
  1. List all profiles:
sevn list
  1. Load secrets into your current shell:
eval "$(sevn unlock myproject)"
  1. Or sign into a new shell with loaded secrets:
sevn sign myproject

Commands

lock - Encrypt a secret

sevn lock KEY=VALUE --profile PROFILE_NAME

unlock - Decrypt and load secrets

eval "$(sevn unlock PROFILE_NAME)"

sign - Start a new shell with secrets

sevn sign PROFILE_NAME

list - Show all profiles

sevn list

purge - Remove secrets or profiles

# Remove a specific secret
sevn purge PROFILE_NAME --key SECRET_KEY

# Remove entire profile
sevn purge PROFILE_NAME

init - Initialize new profile

# Normal initialization
sevn init

# Fun mode: Initialize with the seven deadly sins
sevn init --sin
sevn init --sin --write  # Creates .env file

Shell Integration

Add this to your .bashrc or .zshrc for easier usage:

load_secrets() {
    eval "$(sevn unlock ${1:-default})"
}

Then you can simply use:

load_secrets myproject

Security

  • All secrets are encrypted locally using strong cryptography
  • No external servers or cloud storage
  • Each profile is isolated and separately encrypted
  • Temporary files are securely cleaned up
  • Secrets never touch disk in plaintext

Requirements

  • Python >=3.9
  • cryptography >=41.0.0
  • pyyaml >=6.0.1
  • python-dotenv >=1.0.0

License

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

sevn-1.0.0.tar.gz (9.0 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

sevn-1.0.0-py3-none-any.whl (9.7 kB view details)

Uploaded Python 3

File details

Details for the file sevn-1.0.0.tar.gz.

File metadata

  • Download URL: sevn-1.0.0.tar.gz
  • Upload date:
  • Size: 9.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.0

File hashes

Hashes for sevn-1.0.0.tar.gz
Algorithm Hash digest
SHA256 046d4d51af911dc52e72f8b014b62eb0be698c5e742fecf6874139fdd851f0df
MD5 87ad012129320328e62199f94b2cac3a
BLAKE2b-256 1fae9ce73a8f3126c8036f64954889600fd258232322ee65b6b711d80096cee9

See more details on using hashes here.

File details

Details for the file sevn-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: sevn-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 9.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.11.0

File hashes

Hashes for sevn-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 5536ac35fe93a276a1fe7adf9c6df95b5222812046435090752a5d454b4c66dc
MD5 b498e6e6c69d585803a0adf6c9d2193a
BLAKE2b-256 3ad5b2f0879b5c575441dc88a22b443cdcae540d195fcab13848bc8a36da5cf6

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page