securetar
Python module to handle tarfile backups.
Decision gist · record as of 2026-08-14
Yes. Secure Tar is a straightforward, actively maintained wrapper for encrypted tar backups with low install friction and no known vulnerabilities. Install it if you need to create encrypted tar archives in Python 3.11+ and want a simpler API than managing cryptography directly. The Apache-2.0 license poses no restrictions for most use cases.AI-flagged interpretation of the facts on this page — verify before relying
Before you install
- Requires Python 3.11.0 or later; cryptography and PyNaCl must be installed as runtime dependencies.
- Low install friction with a pure-Python wheel.
- Active maintenance with a recent commit on 2026-07-29 and regular releases; currently at version 2026.4.1 released 2026-04-07.
License · maintenance · safety
Apache-2.0 (permissive) — Apache-2.0 is permissive, allowing commercial and private use with minimal restrictions; you may use, modify, and distribute this package freely as long as you include the license notice.
last release 2026-04-07 (129 days) · last repo commit 2026-07-29 · 13 stars
0 known vulnerabilities (OSV.dev, 2026-08-14) · 577,298 downloads/mo, #5,925 on PyPI
Alternatives
Verify before relying
pip install securetar
from securetar import SecureTarFile, atomic_contents_add
from pathlib import Path
with SecureTarFile("backup.tar", "w", b"AES128_KEY_SIZE") as tar:
atomic_contents_add(tar, Path("."), arcname=".")- Whether the encryption key size (e.g., 'AES128_KEY_SIZE') is validated or if arbitrary byte strings are accepted.
- Performance characteristics when handling large archives or streaming very large files.
- Whether atomic_contents_add supports recursive directory traversal by default or requires explicit configuration.
What it is and what it does
Secure Tar is a Python library that extends the standard tarfile module with encryption and secure file handling. It provides a streaming wrapper around tarfile that lets you create encrypted tar archives and handle file backups securely. The library supports both plain and encrypted archives, optional gzip compression, and a pattern for nesting multiple tar files within an outer tar container—all without writing intermediate files to disk.
The package depends on cryptography and PyNaCl for encryption operations and requires Python 3.11.0 or later. It's designed for backup workflows where you need to create encrypted archives programmatically, with a simple context-manager API that mirrors the standard tarfile interface. The library is actively maintained and has no known security vulnerabilities.
Use it for
- Create encrypted backup archives of application data or configuration directories with a single API call.
- Build nested backup structures (outer tar containing multiple inner compressed tars) without intermediate file writes.
- Add file filtering during archive creation to exclude sensitive or temporary files from backups.
- Automate secure backup pipelines that require encryption without managing raw cryptography details.
Worth the install?
AI-flagged interpretation of the facts on this page. Verify before relying on it.
Yes.
Secure Tar is a straightforward, actively maintained wrapper for encrypted tar backups with low install friction and no known vulnerabilities. Install it if you need to create encrypted tar archives in Python 3.11+ and want a simpler API than managing cryptography directly. The Apache-2.0 license poses no restrictions for most use cases.
Install
securetar on PyPI
Before you install
Low install friction with a pure-Python wheel. Active maintenance with a recent commit on 2026-07-29 and regular releases; currently at version 2026.4.1 released 2026-04-07.
Requires Python 3.11.0 or later; cryptography and PyNaCl must be installed as runtime dependencies.
License in practice
Apache-2.0 is permissive, allowing commercial and private use with minimal restrictions; you may use, modify, and distribute this package freely as long as you include the license notice.
Quickstart
pip install securetar
from securetar import SecureTarFile, atomic_contents_add
from pathlib import Path
with SecureTarFile("backup.tar", "w", b"AES128_KEY_SIZE") as tar:
atomic_contents_add(tar, Path("."), arcname=".")
Verify before relying
- Whether the encryption key size (e.g., 'AES128_KEY_SIZE') is validated or if arbitrary byte strings are accepted.
- Performance characteristics when handling large archives or streaming very large files.
- Whether atomic_contents_add supports recursive directory traversal by default or requires explicit configuration.
Package facts
| License | Apache-2.0 permissive |
| Python support | Supports the current Python release >=3.11.0 |
| Install friction | Low. Pure-Python wheel |
| Runtime dependencies | 2 packagescryptographyPyNaCl |
| Maintenance | Actively maintained 129 days since the last release |
| Last repo commit | |
| First released | |
| Downloads | 577,298 / month, #5,925 on PyPI 30-day window, as of 2026-08-14 |
| Known vulnerabilities | None known OSV.dev, checked 2026-08-14 |
| Classifiers | Intended Audience :: DevelopersOperating System :: OS IndependentProgramming Language :: PythonProgramming Language :: Python :: 3Topic :: Software Development :: Libraries :: Python Modules |
Evidence: securetar-2026.4.1-py3-none-any.whl
Tags
Let your AI agent find packages like this
Example. Real query, live index.
You found this page by searching. An agent finds it by wishing: SkillFed indexes 14,416 PyPI packages by what they can do, searchable in plain language.
wish › “encrypted tar archive”
- securetarSecure Tar wraps Python's tarfile module to add encryption and secure…
- tzsttzst creates and extracts tar archives compressed with Zstandard,…
- fastarFastar provides high-performance tar archive creation and extraction…
Give your agent the search over MCP, or paste the wish link into any chat.
More Python Modules packages
Converts domain names between Unicode and ASCII-compatible encoding (Punycode) according to IDNA 2008 and Unicode Technical Standard 46, with security validation and broader script coverage than the standard library.
Install it if you work with internationalized domain names, need to validate domains, or use HTTP clients that depend on it transitively.
Setuptools is a Python build backend and package management tool that handles building, distributing, and installing Python packages, including support for C/C++ extension modules.
PyYAML parses and emits YAML 1.1 data format, enabling serialization and deserialization of configuration files and Python objects to and from human-readable YAML text.
Pydantic validates Python data structures against type hints, coercing and checking input at runtime to ensure it matches a declared schema.
Provides reusable metadata objects for use with PEP-593 `typing.Annotated` to express common constraints like bounds, collection sizes, and predicates on types.
Install it if you use or build libraries that need to express type constraints in a standardized, inspectable way—or if you want to annotate your own types with…
Provides runtime tools to inspect and introspect Python type annotations, enabling programmatic examination of type hints at execution time.
See also tarsafe · fastar · backports.tarfile · rpmfile · unix-ar · tzst · android_backup · pyunpack · sendsafely · pyzipper