reVault for Python
reVault is a fast, local toolkit for creating secure portable archives called Lockboxes. Each Lockbox is encrypted, compressed, and signed. It can store files and directory trees, variables such as API keys, and forms such as login details.
Lockboxes are easy to copy, share, and back up, and they do not require a hosted service. The engine is designed for speed and effective compression. Applications can read, write, and seek within stored files without extracting the archive, and recover data from partial corruption. reVault provides a command line tool for everyday work and APIs for application code.
Read the reVault manual for the quick start, core concepts, and security model.
Your Vault holds your profile and contacts. The CLI protects a new Lockbox for your profile by default, and you can grant access to contacts using their public keys. Use password access when you do not have a recipient's contact (public key) details.
Platform wheels include the reVault engine and expose Python classes for Lockboxes, Vaults, keys, and the session agent.
Installation and native runtime
python -m pip install revault-api
PyPI publishes a wheel for each supported operating system and architecture.
The wheel stores the matching library inside revault_api/_native, and the
package loads it through ctypes. Installing from a source archive does not
supply a library unless the package is assembled with the matching native
files.
The complete method example index is maintained in the source repository.
from revault_api import Revault, SecretString, Vault
runtime = Revault.load() # loading does not open a Vault
signing = runtime.generate_profile_signing_key_pair()
public_signing_key = signing.public_key()
with runtime.lockbox_create(bytes(32)) as box: # Lockbox held by this process
box.set_owner_signing_key(signing) # Profile becomes this Lockbox's owner
box.add_file("/hello.txt", b"hello\n", False)
box.set_variable("owner", "alice")
box.set_secret_variable("token", bytearray(b"secret"))
size = box.with_secret_variable("token", lambda token: len(token))
box.commit()
public_signing_key.close()
signing.close()
with SecretString("Vault passphrase") as vault_passphrase:
persistent = Vault.open_or_create("/tmp/revault-vault", vault_passphrase)
persistent.close()
Revault.load(native_library_path=...) can load a native library supplied by
the application. Otherwise, reVault checks REVAULT_LIBRARY and then the
library inside the installed wheel. A bare name uses the operating system
search path.
The value passed to a secret callback is a temporary bytearray; it is
cleared after the callback. Do not convert it to a retained str or bytes.
SecretString and SecretBytes own mutable buffers and wipe them on
close(). Ordinary Lockbox operations never contact the agent.
Core API concepts
Revaultloads the runtime.Vaultowns persistent local state.Lockboxowns an open archive.AgentSessioncaches selected content keys.
Prefer context managers and close each object independently.
API documentation and support
The wheel ships typed public classes and method docstrings. Use
help(revault_api) or an API documentation generator for the installed
version. The
method examples
and Python conformance program
cover the common operation inventory.
Create, open, and replace
Open methods require existing Vaults and Lockboxes; they never create missing
state. Use open or create only when creation is acceptable and replacement
methods only after an explicit destructive choice. commit() persists
pending Lockbox changes. close() releases the handle and content key held by
the current process but does not commit or delete the archive.
Open that archive using its Lockbox password, a profile key, or a credential resolved from the Vault. A profile signing key becomes a Lockbox owner key only after explicit assignment.
Secrets, exceptions, and ownership
A vault passphrase, Lockbox password, and 32-byte content key are different
secrets. Use SecretString, SecretBytes, and mutable bytearray values;
close or clear them promptly. Python str and bytes objects cannot be
reliably wiped.
Use context managers for every Vault, Lockbox, key, secret, and agent value.
Secret callbacks receive a temporary bytearray that is cleared after return
and must not escape. Native failures raise typed exceptions with structured
details and recovery guidance.
Optional session agent
Ordinary Lockbox opens never start or consult the agent. Use AgentSession
when Lockbox keys need to be shared across processes or remain available after
the process that opened the Lockbox exits. Closing an entry forgets the
agent's cached key; it does not delete the Lockbox or a credential stored in
the Vault.
Platform credential store
The operating system credential store can hold the Vault passphrase. The user's operating system login normally unlocks that store. After login, another process running as that user may be able to retrieve the passphrase if the access policy applied to the saved Vault passphrase does not require approval for each retrieval. Exact access depends on the operating system, the credential store configuration, and that access policy.
A process that retrieves the Vault passphrase can open the Vault. The Vault can then provide access to Lockboxes through profile keys or remembered Lockbox passwords. Both remain encrypted inside the Vault; they are not copied to the operating system credential store.
Agent expiry improves memory hygiene. It is not an authentication boundary after login if the saved Vault passphrase can be retrieved without approval.
Missing or placeholder package docstrings are binding defects; the executable conformance program is the worked reference for each operation.
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distributions
Built Distributions
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file revault_api-0.3.13-py3-none-win_arm64.whl.
File metadata
- Download URL: revault_api-0.3.13-py3-none-win_arm64.whl
- Upload date:
- Size: 3.0 MB
- Tags: Python 3, Windows ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
54e1287b9902fe15b5a5e7a5f89255737fd3453e9b12fada6f08969076108daa
|
|
| MD5 |
dd3b703ed7cbdfd6584300c3266e2894
|
|
| BLAKE2b-256 |
3223f73f85f0acfbee08b408f589e80db73cdc8d829614efb9693a0dd67a16e1
|
Provenance
The following attestation bundles were made for revault_api-0.3.13-py3-none-win_arm64.whl:
Publisher:
bindings-native-release.yml on onepub-dev/reVault
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
revault_api-0.3.13-py3-none-win_arm64.whl -
Subject digest:
54e1287b9902fe15b5a5e7a5f89255737fd3453e9b12fada6f08969076108daa - Sigstore transparency entry: 2649965990
- Sigstore integration time:
-
Permalink:
onepub-dev/reVault@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Branch / Tag:
refs/tags/revault-api-v0.3.13 - Owner: https://github.com/onepub-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
bindings-native-release.yml@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Trigger Event:
push
-
Statement type:
File details
Details for the file revault_api-0.3.13-py3-none-win_amd64.whl.
File metadata
- Download URL: revault_api-0.3.13-py3-none-win_amd64.whl
- Upload date:
- Size: 3.3 MB
- Tags: Python 3, Windows x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
160f21b2e56e66c11e8f1fd7043e890dace219e28dc8f63bb379f5b39a2fdb42
|
|
| MD5 |
7ee3f5e0c366ba1746d5445261fc8bd6
|
|
| BLAKE2b-256 |
4665574cc5a953546c63348277bda8c7038c239eccacb51802e5e964c36fbae7
|
Provenance
The following attestation bundles were made for revault_api-0.3.13-py3-none-win_amd64.whl:
Publisher:
bindings-native-release.yml on onepub-dev/reVault
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
revault_api-0.3.13-py3-none-win_amd64.whl -
Subject digest:
160f21b2e56e66c11e8f1fd7043e890dace219e28dc8f63bb379f5b39a2fdb42 - Sigstore transparency entry: 2649965923
- Sigstore integration time:
-
Permalink:
onepub-dev/reVault@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Branch / Tag:
refs/tags/revault-api-v0.3.13 - Owner: https://github.com/onepub-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
bindings-native-release.yml@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Trigger Event:
push
-
Statement type:
File details
Details for the file revault_api-0.3.13-py3-none-manylinux_2_39_x86_64.whl.
File metadata
- Download URL: revault_api-0.3.13-py3-none-manylinux_2_39_x86_64.whl
- Upload date:
- Size: 5.5 MB
- Tags: Python 3, manylinux: glibc 2.39+ x86-64
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
55cf6cba91e63c5d77ab235ea32004a8fd91722ecf42becc2bf3ab0d46a0ac15
|
|
| MD5 |
7d3c70d48a0db5247490be93f4ef6d31
|
|
| BLAKE2b-256 |
eea36cad1fc8d720633697104ac8ddab359bdbb3ffe2ab400396c71bdf15ad8a
|
Provenance
The following attestation bundles were made for revault_api-0.3.13-py3-none-manylinux_2_39_x86_64.whl:
Publisher:
bindings-native-release.yml on onepub-dev/reVault
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
revault_api-0.3.13-py3-none-manylinux_2_39_x86_64.whl -
Subject digest:
55cf6cba91e63c5d77ab235ea32004a8fd91722ecf42becc2bf3ab0d46a0ac15 - Sigstore transparency entry: 2649965944
- Sigstore integration time:
-
Permalink:
onepub-dev/reVault@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Branch / Tag:
refs/tags/revault-api-v0.3.13 - Owner: https://github.com/onepub-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
bindings-native-release.yml@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Trigger Event:
push
-
Statement type:
File details
Details for the file revault_api-0.3.13-py3-none-manylinux_2_39_aarch64.whl.
File metadata
- Download URL: revault_api-0.3.13-py3-none-manylinux_2_39_aarch64.whl
- Upload date:
- Size: 5.2 MB
- Tags: Python 3, manylinux: glibc 2.39+ ARM64
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
a96182995edf074ef618b29c5ac752adaf10083187c9c82d7ff64a6fc10c10a0
|
|
| MD5 |
3b91f09887f5957c65039780bff5dafe
|
|
| BLAKE2b-256 |
89675b9063cac725b2e3c62760f69c43392ba2a03aeb1f8434c53824b411b50f
|
Provenance
The following attestation bundles were made for revault_api-0.3.13-py3-none-manylinux_2_39_aarch64.whl:
Publisher:
bindings-native-release.yml on onepub-dev/reVault
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
revault_api-0.3.13-py3-none-manylinux_2_39_aarch64.whl -
Subject digest:
a96182995edf074ef618b29c5ac752adaf10083187c9c82d7ff64a6fc10c10a0 - Sigstore transparency entry: 2649965971
- Sigstore integration time:
-
Permalink:
onepub-dev/reVault@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Branch / Tag:
refs/tags/revault-api-v0.3.13 - Owner: https://github.com/onepub-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
bindings-native-release.yml@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Trigger Event:
push
-
Statement type:
File details
Details for the file revault_api-0.3.13-py3-none-macosx_11_0_universal2.whl.
File metadata
- Download URL: revault_api-0.3.13-py3-none-macosx_11_0_universal2.whl
- Upload date:
- Size: 2.2 MB
- Tags: Python 3, macOS 11.0+ universal2 (ARM64, x86-64)
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
24f87a774569dacd3d116c1224650755e6c3e7ec34fb98473c06c52ef1bf370e
|
|
| MD5 |
8c42b612e1749a0a9a299c530321b570
|
|
| BLAKE2b-256 |
1ba43473dc473d0ebd7e31abd24703adbd11f5d6d936ee5982ce17e1be5fa195
|
Provenance
The following attestation bundles were made for revault_api-0.3.13-py3-none-macosx_11_0_universal2.whl:
Publisher:
bindings-native-release.yml on onepub-dev/reVault
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
revault_api-0.3.13-py3-none-macosx_11_0_universal2.whl -
Subject digest:
24f87a774569dacd3d116c1224650755e6c3e7ec34fb98473c06c52ef1bf370e - Sigstore transparency entry: 2649965906
- Sigstore integration time:
-
Permalink:
onepub-dev/reVault@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Branch / Tag:
refs/tags/revault-api-v0.3.13 - Owner: https://github.com/onepub-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
bindings-native-release.yml@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Trigger Event:
push
-
Statement type:
File details
Details for the file revault_api-0.3.13-py3-none-macosx_10_13_universal2.whl.
File metadata
- Download URL: revault_api-0.3.13-py3-none-macosx_10_13_universal2.whl
- Upload date:
- Size: 2.4 MB
- Tags: Python 3, macOS 10.13+ universal2 (ARM64, x86-64)
- Uploaded using Trusted Publishing? Yes
- Uploaded via:
twine/7.0.0 CPython/3.13.14
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
5f6136640cc4201218d56654b2d9ef88e818944fd0ae8312f0c85baedb89aa9f
|
|
| MD5 |
515bfb6342825a8cf3a6a877fd21f46d
|
|
| BLAKE2b-256 |
59d8d59247bb07b9bf3717fc9ecbe94c0abcedeb96a7d7a2fef85978783d40fa
|
Provenance
The following attestation bundles were made for revault_api-0.3.13-py3-none-macosx_10_13_universal2.whl:
Publisher:
bindings-native-release.yml on onepub-dev/reVault
-
Statement:
-
Statement type:
https://in-toto.io/Statement/v1 -
Predicate type:
https://docs.pypi.org/attestations/publish/v1 -
Subject name:
revault_api-0.3.13-py3-none-macosx_10_13_universal2.whl -
Subject digest:
5f6136640cc4201218d56654b2d9ef88e818944fd0ae8312f0c85baedb89aa9f - Sigstore transparency entry: 2649965961
- Sigstore integration time:
-
Permalink:
onepub-dev/reVault@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Branch / Tag:
refs/tags/revault-api-v0.3.13 - Owner: https://github.com/onepub-dev
-
Access:
public
-
Token Issuer:
https://token.actions.githubusercontent.com -
Runner Environment:
github-hosted -
Publication workflow:
bindings-native-release.yml@ffb09dac9851348e4d7c98bb5e435fb00941c8da -
Trigger Event:
push
-
Statement type: