Skip to main content

No project description provided

Project description

Gatekeeper CDR (Python)

This package provides native Python bindings to the Gatekeeper CDR core, a zero-trust Content Disarm and Reconstruction engine. It sanitizes potentially malicious files by deeply inspecting and rebuilding them from raw pixel data, effectively stripping away any steganography, macros, or hidden exploits.

Installation

pip install gatekeeper-cdr

(Note: Pre-built wheels are provided for Linux, macOS, and Windows. You do not need Rust installed to use this package).

Usage

import gatekeeper_cdr

# 1. Read a suspicious file
with open("suspicious.jpg", "rb") as f:
    raw_payload = f.read()

# 2. Detect the true format of the file without fully parsing it
try:
    fmt = gatekeeper_cdr.sniff_format(raw_payload)
    print(f"Detected Format: {fmt}") # "Jpeg", "Png", etc.
except Exception as e:
    print(f"Unknown or invalid format: {e}")

# 3. Disarm the file (returns a clean bytes object)
try:
    clean_payload = gatekeeper_cdr.disarm(raw_payload)
    with open("clean.png", "wb") as f:
        f.write(clean_payload)
    print("File successfully sanitized and saved as clean.png!")
except Exception as e:
    print(f"Failed to sanitize file: {e}")

Security

If the file is malformed, structurally invalid, or contains an unknown format, Gatekeeper will intentionally raise an Exception rather than attempting to process it. This default-deny stance ensures that only provably safe files make it into your application's storage.

Project details


Download files

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

Source Distributions

No source distribution files available for this release.See tutorial on generating distribution archives.

Built Distributions

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

gatekeeper_cdr-0.4.1-cp38-abi3-win_amd64.whl (1.4 MB view details)

Uploaded CPython 3.8+Windows x86-64

gatekeeper_cdr-0.4.1-cp38-abi3-manylinux_2_34_x86_64.whl (1.6 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.34+ x86-64

gatekeeper_cdr-0.4.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl (1.5 MB view details)

Uploaded CPython 3.8+manylinux: glibc 2.17+ ARM64

gatekeeper_cdr-0.4.1-cp38-abi3-macosx_11_0_arm64.whl (1.3 MB view details)

Uploaded CPython 3.8+macOS 11.0+ ARM64

gatekeeper_cdr-0.4.1-cp38-abi3-macosx_10_12_x86_64.whl (1.5 MB view details)

Uploaded CPython 3.8+macOS 10.12+ x86-64

File details

Details for the file gatekeeper_cdr-0.4.1-cp38-abi3-win_amd64.whl.

File metadata

File hashes

Hashes for gatekeeper_cdr-0.4.1-cp38-abi3-win_amd64.whl
Algorithm Hash digest
SHA256 70e20d8a45d2941b4005586e40bbd6fa8948fdf99bf60c2bbd4d4d560e8188f3
MD5 093e6cd71a2f39d9166c5c0710fb896c
BLAKE2b-256 21d7a8921a55054e868fc821d39caedacc84f712f116f118dc163483031047ce

See more details on using hashes here.

File details

Details for the file gatekeeper_cdr-0.4.1-cp38-abi3-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for gatekeeper_cdr-0.4.1-cp38-abi3-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 5ae837fb31fcc99e709af21b33cb770b515d9cea9f472b9d9ac4d4bff7f2346d
MD5 855bb1da1c1d95cb4b3f721d90618a21
BLAKE2b-256 c83d7f54cacabca0ab3f9a7bfcf901244f1935adc543b5a625b5136ece613a39

See more details on using hashes here.

File details

Details for the file gatekeeper_cdr-0.4.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl.

File metadata

File hashes

Hashes for gatekeeper_cdr-0.4.1-cp38-abi3-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Algorithm Hash digest
SHA256 2e881a1e25eae8a62ba3b83693bd14c39e31807efe461742eb3b9ccb567f520d
MD5 cacbc3309b70407c336aac1792854697
BLAKE2b-256 6ecfe48389d2b1bc7cb60b0c53fa255f2effafa9715405a834680afabc637610

See more details on using hashes here.

File details

Details for the file gatekeeper_cdr-0.4.1-cp38-abi3-macosx_11_0_arm64.whl.

File metadata

File hashes

Hashes for gatekeeper_cdr-0.4.1-cp38-abi3-macosx_11_0_arm64.whl
Algorithm Hash digest
SHA256 d4e19745e0808df7d1c39acc35567a549a650d8521ec9b5a9dccd8c8a5461766
MD5 28086ef49a0b2fb82433ae33d7a47d48
BLAKE2b-256 0efceac67ef018965de14100c7451573d153db4d2de617315bc06bbd24e6a525

See more details on using hashes here.

File details

Details for the file gatekeeper_cdr-0.4.1-cp38-abi3-macosx_10_12_x86_64.whl.

File metadata

File hashes

Hashes for gatekeeper_cdr-0.4.1-cp38-abi3-macosx_10_12_x86_64.whl
Algorithm Hash digest
SHA256 d4497c0e37fc967c322db858af57bbce0c95423f1a5fd1736c4a6de6460e9f8c
MD5 a43c25327b3aadeeca71aca6db04c098
BLAKE2b-256 8723809d258b870b4533e0951d64901d3c378595ba17a2455fa5d7c539296778

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