A Easy-to-use Crypto Tool
Project description
Crypto Plus
1. 概览
一个易用的加解密、签名、证书工具。 目前已发布到pypi。
2. 使用
2.1 安装
pip install crypto_plus
2.2 使用
from crypto_plus import CryptoPlus
# 目前支持RSA、DSA、ECDSA
rsa = CryptoPlus.generate_rsa()
# dsa = CryptoPlus.generate_dsa()
# ecdsa = CryptoPlus.generate_ecdsa()
# 加解密
plaintext = b'plaintext bytes'
ciphertext = rsa.encrypt(plaintext)
assert rsa.decrypt(ciphertext) == ciphertext
# 签名、验签
message = b'message bytes'
signature = rsa.sign(message)
rsa.verify(message, signature)
# 导出自签名证书
rsa.dump_cert(subject_name="subject", issuer_name="issuer")
# 导入导出文件
rsa.dump()
rsa_from_file = CryptoPlus.load()
3. 开发
阅读 开发手册.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
crypto_plus-1.0.5.tar.gz
(8.8 kB
view details)
Built Distribution
File details
Details for the file crypto_plus-1.0.5.tar.gz
.
File metadata
- Download URL: crypto_plus-1.0.5.tar.gz
- Upload date:
- Size: 8.8 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.12.1 Windows/11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 35629a905f291ca525cb94dd21b2894162c41f506ac755d93302deaf94bd06cf |
|
MD5 | 7f8b38edb6a96f15c7e1c9e703c71700 |
|
BLAKE2b-256 | fe1362ceea361cae554b79a2ab68845868eaa2a9905ba37d0fc5bf2d3e42ae99 |
File details
Details for the file crypto_plus-1.0.5-py3-none-any.whl
.
File metadata
- Download URL: crypto_plus-1.0.5-py3-none-any.whl
- Upload date:
- Size: 10.1 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.7.1 CPython/3.12.1 Windows/11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 61bf45dea4a4db36e9dddbdf94e57bcc90994f12251fe794782ad3e20abd866e |
|
MD5 | f337258cf6464cc05664a413a2e97118 |
|
BLAKE2b-256 | 4daf279cf915cd6a6768fa330efbeaddb091919829b16debc7562d63ffc3f16a |