Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/rudifa/private-public-key

Demo basic usage of private + public key to encrypt/decrypt and sign/verify
https://github.com/rudifa/private-public-key

Last synced: 24 days ago
JSON representation

Demo basic usage of private + public key to encrypt/decrypt and sign/verify

Awesome Lists containing this project

README

        

# private + public key

[overview](https://chat.openai.com/c/d143f08d-2a61-4ca4-891e-935647da843f)

- encrypt / decrypt
-
```
message = ...
ciphertext = public_key.encrypt(message, ...)

...

decrypted_message = private_key.decrypt(ciphertext, ...)
```
- sign / verify
-
```
signature = private_key.sign(message, ...)

...

public_key.verify(signature, message, ...)
```