Ecosyste.ms: Awesome
An open API service indexing awesome lists of open source software.
https://github.com/aeyoll/vernam-rs
Encode and decode a message with a vername cipher (or one-time pad).
https://github.com/aeyoll/vernam-rs
rust vernam vernam-cipher vernam-cipher-algorithm
Last synced: 3 days ago
JSON representation
Encode and decode a message with a vername cipher (or one-time pad).
- Host: GitHub
- URL: https://github.com/aeyoll/vernam-rs
- Owner: aeyoll
- License: mit
- Created: 2021-07-25T09:13:25.000Z (over 3 years ago)
- Default Branch: main
- Last Pushed: 2021-07-25T11:28:40.000Z (over 3 years ago)
- Last Synced: 2024-11-01T23:25:09.025Z (about 2 months ago)
- Topics: rust, vernam, vernam-cipher, vernam-cipher-algorithm
- Language: Rust
- Homepage:
- Size: 10.7 KB
- Stars: 0
- Watchers: 3
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Vernam cipher
Encode and decode a message with a vername cipher (or one-time pad).
In cryptography, the one-time pad (OTP) is an encryption technique that cannot be cracked, but requires the use of a single-use pre-shared key that is no smaller than the message being sent. In this technique, a plaintext is paired with a random secret key (also referred to as a one-time pad). Then, each bit or character of the plaintext is encrypted by combining it with the corresponding bit or character from the pad using modular addition. [Read more on wikipedia](https://en.wikipedia.org/wiki/One-time_pad)
Encrypt
---```sh
vernam encrypt HELLO WMCKL # Outputs DQNVZ
```Decrypt
---```sh
vernam decrypt DQNVZ WMCKL # Outputs HELLO
```