A simple and fun cipher (Python) https://pypi.org/project/sweecrypt
Find a file
PC Kitty e66987fa2f
All checks were successful
Test / test (push) Successful in 1m3s
Upload Python Package / deploy (release) Successful in 37s
hopefully this turns it into a positional arg
2026-04-08 15:16:48 -07:00
.forgejo/workflows make CI run work on ARM too 2026-04-08 15:11:56 -07:00
sweecrypt hopefully this turns it into a positional arg 2026-04-08 15:16:48 -07:00
.gitignore Initial commit 2024-04-02 16:38:09 -07:00
LICENSE Initial commit 2024-04-02 16:38:09 -07:00
pyproject.toml 1.1.5 2026-04-08 15:06:30 -07:00
README.md 1.1.5 2026-04-08 15:06:30 -07:00

SweeCrypt

A basic and fun cipher module for everyone. it converts regular text into symbols on a keyboard, kind of like a cipher. This is only for fun, using this module for cybersecurity is NOT ADVISED

This is a more maintained version of the Crypty Encryption Module in Swee's Replit.

Install

CLI (>= 1.1.3)

$ pipx install sweecrypt

Help page:

$ sweecrypt --help
                                                                                                                                                                     
 Usage: sweecrypt [OPTIONS] COMMAND [ARGS]...                                                                                                                        
                                                                                                                                                                     
 An easy and fun encryption module.                                                                                                                                  
                                                                                                                                                                     
                                                                                                                                                                     
╭─ Options ─────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ --install-completion          Install completion for the current shell.                                                                                           │
│ --show-completion             Show completion for the current shell, to copy it or customize the installation.                                                    │
│ --help                        Show this message and exit.                                                                                                         │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯
╭─ Commands ────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╮
│ encrypt   Encrypts a message                                                                                                                                      │
│ decrypt   Decrypts a SweeCrypt-encoded message                                                                                                                    │
╰───────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────────╯

Module

$ pip3 install sweecrypt

Import:

>>> import sweecrypt

Usage

Encrypt:

>>> sweecrypt.encrypt("hello, world!")
!?~~(:,}(>~/a
$ sweecrypt encrypt "hello, world!"
!?~~(:,}(>~/a

Decrypt:

>>> sweecrypt.decrypt("!?~~(:,}(>~/a")
hello, world!
$ sweecrypt decrypt "!?~~(:,}(>~/a"
hello, world!

Warning

Decrypting text using the CLI may cause your shell to malfunction

This can usually be fixed by using set +H before running or by piping instead

With newer versions of sweecrypt (>= 1.1.0), you can shift the encryption database:

>>> sweecrypt.encrypt("hello, world", 3)
'\\!((>ba_>](#'
>>> sweecrypt.decrypt("\\!((>ba_>](#", 3)
'hello, world'
$ sweecrypt encrypt --shift 3 "hello, world"
\!((>ba_>](#
$ sweecrypt decrypt --shift 3 "\!((>ba_>](#"
hello, world

So it will output a nonsense string if shifted incorrectly.

>>> sweecrypt.decrypt("\\!((>ba_>](#")
'khoor?!zruog'
$ sweecrypt decrypt "\!((>ba_>](#"
khoor?!zruog

In SweeCrypt >= 1.1.5, you can now pipe to the CLI

$ cat test.txt
Lorem ipsum dolor
$ xxd -p test.txt | sweecrypt encrypt > test.swcr
$ cat test.swcr
j)l^mhlkl/hplompmimkl/hpljl^l)l^mhp`c
$ sweecrypt decrypt < test.swcr | xxd -rp
Lorem ipsum dolor