Skip to main content

Provides encryption and signing capabilities through Sequoia

Project description

#+TITLE: PySequoia
#+HTML_HEAD: <link rel="stylesheet" href="doc/tufte.min.css">
#+PROPERTY: header-args :tangle yes :exports both
#+OPTIONS: html-postamble:nil

Note: This is a work in progress. The API is *not* stable!

Building:

#+BEGIN_SRC sh
python3 -m venv .env
source .env/bin/activate
pip install maturin
maturin develop
#+END_SRC

Now open the console with =python= and import the library:

#+BEGIN_SRC python
import pysequoia
#+END_SRC

** Available functions

*** encrypt

Signs and encrypts a string to one or more recipients:

#+BEGIN_SRC python
s = open("signing-key.asc", "r").read()
r = open("wiktor.asc", "r").read()
pysequoia.encrypt(s, r, "content to encrypt")
#+END_SRC

*** merge

Merges data from old certificate with new packets:

#+BEGIN_SRC python
old = open("wiktor.asc", "r").read()
new = open("wiktor-fresh.asc", "r").read()
pysequoia.merge(old, new)
#+END_SRC

*** minimize

Discards expired subkeys and User IDs:

#+BEGIN_SRC python
cert = open("wiktor.asc", "r").read()
pysequoia.minimize(cert)
#+END_SRC

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

pysequoia-0.1.2.tar.gz (3.2 MB view details)

Uploaded Source

Built Distribution

pysequoia-0.1.2-cp310-cp310-manylinux_2_34_x86_64.whl (1.6 MB view details)

Uploaded CPython 3.10 manylinux: glibc 2.34+ x86-64

File details

Details for the file pysequoia-0.1.2.tar.gz.

File metadata

  • Download URL: pysequoia-0.1.2.tar.gz
  • Upload date:
  • Size: 3.2 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: maturin/0.14.2

File hashes

Hashes for pysequoia-0.1.2.tar.gz
Algorithm Hash digest
SHA256 3cdd1e8620f2c23b691d005423e65f6b981fbf5adb2b4cfa8fc8f134401ad67f
MD5 959ed16c3f9a0040a7f1fab89741f21f
BLAKE2b-256 7a0eb0883ea0eef92e711e835c9a128c93028846d5c8c7a8a7f72dd3706d7299

See more details on using hashes here.

File details

Details for the file pysequoia-0.1.2-cp310-cp310-manylinux_2_34_x86_64.whl.

File metadata

File hashes

Hashes for pysequoia-0.1.2-cp310-cp310-manylinux_2_34_x86_64.whl
Algorithm Hash digest
SHA256 10fc0b1fc768d70c69f06bca7f1d80b676329e286d9bbf3577d5ff20fa557fea
MD5 269faab0a56db7957500f5a7b6818302
BLAKE2b-256 772515183a2ba36c146d5823e3f5a28f61504496e9a1ad156fd28785b5bebf38

See more details on using hashes here.

Supported by

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