Skip to main content

cPass

Encode/Decode your passwords with Morse code.

License cPass Version

Summary

🏃‍♂️‍➡️ TL;DR

Encode your passphrase/password

cpass encode "craftwork thus robust dares lullaby"
cpass encode "myp4ssw0rd!"

Decode your passphrase/password

cpass decode "-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. --- -... ..- ... - / -.. .- .-. . ... / .-.. ..- .-.. .-.. .- -... -.--"
cpass decode "-- -.-- .--. ....- ... ... .-- ----- .-. -.. -.-.--"

Encode your .txt file

cpass encode "/path/to/your/file.txt"

Decode your .txt file

cpass decode "/path/to/your/file.txt"

Encode your secret words (crypto users)

cpass encrypto "/path/to/your/secret-words.txt"

Decode your secret words (crypto users)

cpass decrypto "/path/to/your/encoded-secret-words.txt"

💻 Installation

Install with pip

Requirements

Python Version

pip install c-pass

📖 Documentation

cpass encode --help
cpass decode --help
cpass encrypto --help
cpass decrypto --help

[required] input argument

Your passphrase/password or your file path to encode/decode.

cpass encode "my beautiful passphrase"
cpass encode "/path/to/your/file.txt"
cpass decode ". -. -.-. --- -.. .. -. --."
cpass decode "/path/to/your/file.txt"
cpass encrypto "/path/to/your/secret-words.txt"
cpass decrypto "/path/to/your/encoded-secret-words.txt"

[optional] -L/--language option

Language of your password/passphrase. It's english by default.

cpass encode "encoding" --language english
cpass encode "préparer" -L french
cpass encode "además" -L spanish
cpass encode "здравствуйте" -L russian
cpass encode "вчіться" -L ukrainian
cpass encode "123456789" -L numbers
cpass encode ".;?!@-+=/" -L special
cpass decode ". -. -.-. --- -.. .. -. --." --language english
cpass decode ".--. .-. ..-.. .--. .- .-. . .-." -L french
cpass decode ".- -.. . -- .--.- ..." -L spanish
cpass decode "--.. -.. .-. .- .-- ... - .-- ..- .--- - ." -L russian
cpass decode ".-- ---. .. - -..- ... .-.-" -L ukrainian
cpass decode ".---- ..--- ...-- ....- ..... -.... --... ---.. ----." -L numbers
cpass decode ".-.-.- -.-.-. ..--.. -.-.-- .--.-. -....- .-.-. -...- -..-." -L special
cpass encrypto "/path/to/your/secret-words.txt" --language english
cpass encrypto "/path/to/your/secret-words.txt" -L french
cpass encrypto "/path/to/your/secret-words.txt" -L spanish
cpass encrypto "/path/to/your/secret-words.txt" -L russian
cpass encrypto "/path/to/your/secret-words.txt" -L ukrainian
cpass decrypto "/path/to/your/encoded-secret-words.txt" --language english
cpass decrypto "/path/to/your/encoded-secret-words.txt" -L french
cpass decrypto "/path/to/your/encoded-secret-words.txt" -L spanish
cpass decrypto "/path/to/your/encoded-secret-words.txt" -L russian
cpass decrypto "/path/to/your/encoded-secret-words.txt" -L ukrainian

⚠️ Some special characters aren't supported. Here is the list:

["#", "[", "]", "{", "}", "<", ">", "|", "*", "µ", "£", "^", "~", "°", "`", "§", "%"]

[optional] -d/--dot option

Character representing the dot. It's . by default.

cpass encode "encoding" -d "p"
cpass encode "encoding" --dot "p"
cpass decode "p -p -p-p --- -pp pp -p --p" -d "p"
cpass decode "p -p -p-p --- -pp pp -p --p" --dot "p"
cpass encrypto "/path/to/your/secret-words.txt" -d "p"
cpass encrypto "/path/to/your/secret-words.txt" --dot "p"
cpass decrypto "/path/to/your/encoded-secret-words.txt" -d "p"
cpass decrypto "/path/to/your/encoded-secret-words.txt" --dot "p"

[optional] -D/--dash option

Character representing the dash. It's - by default.

cpass encode "encoding" -D "t"
cpass encode "encoding" --dash "t"
cpass decode ". t. t.t. ttt t.. .. t. tt." -D "t"
cpass decode ". t. t.t. ttt t.. .. t. tt." --dash "t"
cpass encrypto "/path/to/your/secret-words.txt" -D "t"
cpass encrypto "/path/to/your/secret-words.txt" --dash "t"
cpass decrypto "/path/to/your/encoded-secret-words.txt" -D "t"
cpass decrypto "/path/to/your/encoded-secret-words.txt" --dash "t"

[optional] -s/--separator option

Character representing the words spacing. It's / by default.

cpass encode "abcde fghijk lmnopq" -s "|"
cpass encode "abcde fghijk lmnopq" --separator "|"
cpass decode ".- -... -.-. -.. . | ..-. --. .... .. .--- -.- | .-.. -- -. --- .--. --.-" -s "|"
cpass decode ".- -... -.-. -.. . | ..-. --. .... .. .--- -.- | .-.. -- -. --- .--. --.-" --separator "|"

[optional] -o/--output option

Absolute or relative path to store your encoded/decoded password/passphrase/file.

cpass encode "encoding" -o /path/to/your/file.txt
cpass encode "encoding" --output /path/to/your/file.txt
cpass decode ". -. -.-. --- -.. .. -. --." -o /path/to/your/file.txt
cpass decode ". -. -.-. --- -.. .. -. --." --output /path/to/your/file.txt
cpass encrypto "/path/to/your/secret-words.txt" -o /path/to/your/encoded-words.txt
cpass encrypto "/path/to/your/secret-words.txt" --output /path/to/your/encoded-words.txt
cpass decrypto "/path/to/your/encoded-secret-words.txt" -o /path/to/your/decoded-words.txt
cpass decrypto "/path/to/your/encoded-secret-words.txt" --output /path/to/your/decoded-words.txt

[optional] --markup option

Shows the original character in brackets before its Morse code (or vice versa).

Encoding

cpass encode "encoding" --markup

Output:

[E] . [N] -. [C] -.-. [O] --- [D] -.. [I] .. [N] -. [G] --.

Decoding

cpass decode ". -. -.-. --- -.. .. -. --." --markup

Output:

[.] e [-.] n [-.-.] c [---] o [-..] d [..] i [-.] n [--.] g

[optional] -u/--upper-case option

Show your decoded passphrase in UPPERCASE.

cpass decode ". -. -.-. --- -.. .. -. --. / -.. . -.-. --- -.. .. -. --." -u
cpass decode ". -. -.-. --- -.. .. -. --. / -.. . -.-. --- -.. .. -. --." --upper-case

Output:

ENCODING DECODING

⚠️ This option is for decode subcommand only.

[optional] -t/--title-case option

Show your decoded passphrase in Title Case.

cpass decode ". -. -.-. --- -.. .. -. --. / -.. . -.-. --- -.. .. -. --." -t
cpass decode ". -. -.-. --- -.. .. -. --. / -.. . -.-. --- -.. .. -. --." --title-case

Output:

Encoding Decoding

⚠️ This option is for decode subcommand only.

[optional] -f/--fingerprint option

Determine which letter is uppercase or lowercase. The length of the fingerprint must match with the length of your (decoded) passphrase.

cpass decode ". -. -.-. --- -.. .. -. --. / -.. . -.-. --- -.. .. -. --." -f 11212211322112121
cpass decode ". -. -.-. --- -.. .. -. --. / -.. . -.-. --- -.. .. -. --." --fingerprint 11212211322112121

Output:

enCoDIng DEcoDiNg

⚠️ This option is for decode subcommand only.

💡 The fingerprint is automaticaly generated if your passphrase is chaotic_case (contains uppercase and lowercase letters).

[optional] --hidden option

Hide your original secret words in a table.

cpass encrypto "/path/to/your/secret-words.txt" --hidden
cpass decrypto "/path/to/your/encoded-secret-words.txt" --hidden

📝 Usage

I want to encode my passphrase: craftwork thus robust dares lullaby

cpass encode "craftwork thus robust dares lullaby"
cpass encode "CRAFTWORK THUS ROBUST DARES LULLABY"
cpass encode "Craftwork Thus Robust Dares Lullaby"

Output:

-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. --- -... ..- ... - / -.. .- .-. . ... / .-.. ..- .-.. .-.. .- -... -.--

ℹ️ Note there are no differences between lowercase, UPPERCASE and Title Case for encoding.

I want to encode my passphrase and store the value in a .txt file

cpass encode "craftwork thus robust dares lullaby" --output /path/to/your/file.txt

I want to encode my passphrase with i as -, h as . and | as /

cpass encode "craftwork thus robust dares lullaby" -D i -d h -s "|"

Output:

ihih hih hi hhih i hii iii hih ihi | i hhhh hhi hhh | hih iii ihhh hhi hhh i | ihh hi hih h hhh | hihh hhi hihh hihh hi ihhh ihii

I want to encode my passphrase in chaotic case: crAftwoRk Thus r0Bust dAr3s Lull4by

cpass encode "crAftwoRk Thus r0Bust dAr3s Lull4by"

Output:

-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. ----- -... ..- ... - / -.. .- .-. ...-- ... / .-.. ..- .-.. .-.. ....- -... -.--
Fingerprint: 11211112182111518211141216152111711

💡 Note that the fingerprint is used to determine the uppercase and lowercase letters in the passphrase.

I want to encode my .txt file

cpass encode "/path/to/your/file.txt"

I want to encode my password: Th1sIs4Str0ng-p@ssw0rd!

cpass encode "Th1sIs4Str0ng-p@ssw0rd!"

Output:

- .... .---- ... .. ... ....- ... - .-. ----- -. --. -....- .--. .--.-. ... ... .-- ----- .-. -.. -.-.--
Fingerprint: 21312132113113131113113

💀 WTF is this sh*t?

I want to encode my encoded passphrase: crAftwoRk Thus r0Bust dAr3s Lull4by!

cpass encode "crAftwoRk Thus r0Bust dAr3s Lull4by" -d "Д" -D "й" -s "з"
cpass encode "йДйД ДйД Дй ДДйД й Дйй ййй ДйД йДй з й ДДДД ДДй ДДД з ДйД ййййй йДДД ДДй ДДД й з йДД Дй ДйД ДДДйй ДДД з ДйДД ДДй ДйДД ДйДД ДДДДй йДДД йДйй" -d "á" -D "Ñ" -s "ó" -L russian

Output:

йДйД ДйД Дй ДДйД й Дйй ййй ДйД йДй з й ДДДД ДДй ДДД з ДйД ййййй йДДД ДДй ДДД й з йДД Дй ДйД ДДДйй ДДД з ДйДД ДДй ДйДД ДйДД ДДДДй йДДД йДйй
Fingerprint: 11211112162111319211161219132111511
áÑÑÑ Ñáá áÑÑÑ Ñáá ó Ñáá áÑÑÑ Ñáá ó Ñáá áÑÑÑ ó Ñáá Ñáá áÑÑÑ Ñáá ó áÑÑÑ ó Ñáá áÑÑÑ áÑÑÑ ó áÑÑÑ áÑÑÑ áÑÑÑ ó Ñáá áÑÑÑ Ñáá ó áÑÑÑ Ñáá áÑÑÑ ó ÑÑáá ó áÑÑÑ ó Ñáá Ñáá Ñáá Ñáá ó Ñáá Ñáá áÑÑÑ ó Ñáá Ñáá Ñáá ó ÑÑáá ó Ñáá áÑÑÑ Ñáá ó áÑÑÑ áÑÑÑ áÑÑÑ áÑÑÑ áÑÑÑ ó áÑÑÑ Ñáá Ñáá Ñáá ó Ñáá Ñáá áÑÑÑ ó Ñáá Ñáá Ñáá ó áÑÑÑ ó ÑÑáá ó áÑÑÑ Ñáá Ñáá ó Ñáá áÑÑÑ ó Ñáá áÑÑÑ Ñáá ó Ñáá Ñáá Ñáá áÑÑÑ áÑÑÑ ó Ñáá Ñáá Ñáá ó ÑÑáá ó Ñáá áÑÑÑ Ñáá Ñáá ó Ñáá Ñáá áÑÑÑ ó Ñáá áÑÑÑ Ñáá Ñáá ó Ñáá áÑÑÑ Ñáá Ñáá ó Ñáá Ñáá Ñáá Ñáá áÑÑÑ ó áÑÑÑ Ñáá Ñáá Ñáá ó áÑÑÑ Ñáá áÑÑÑ áÑÑÑ
Fingerprint: 121262126213221271421191115212312161516222252218222915212411111712229221922241514122721821262221182226192122822182122621226222213122241211

I want to decode my encoded passphrase in lowercase: craftwork thus robust dares lullaby

cpass decode "-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. --- -... ..- ... - / -.. .- .-. . ... / .-.. ..- .-.. .-.. .- -... -.--"

Output:

craftwork thus robust dares lullaby

I want to decode my encoded passphrase in uppercase: CRAFTWORK THUS ROBUST DARES LULLABY

cpass decode "-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. --- -... ..- ... - / -.. .- .-. . ... / .-.. ..- .-.. .-.. .- -... -.--" --upper-case

Output:

CRAFTWORK THUS ROBUST DARES LULLABY

I want to decode my encoded passphrase in titlecase: Craftwork Thus Robust Dares Lullaby

cpass decode "-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. --- -... ..- ... - / -.. .- .-. . ... / .-.. ..- .-.. .-.. .- -... -.--" --title-case

Output:

Craftwork Thus Robust Dares Lullaby

I want to decode my encoded passphrase and store the value in a .txt file

cpass decode "-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. --- -... ..- ... - / -.. .- .-. . ... / .-.. ..- .-.. .-.. .- -... -.--" --output /path/to/your/file.txt

I want to decode my encoded passphrase in chaotic case: crAftwoRk Thus r0Bust dAr3s Lull4by

cpass decode "-.-. .-. .- ..-. - .-- --- .-. -.- / - .... ..- ... / .-. ----- -... ..- ... - / -.. .- .-. ...-- ... / .-.. ..- .-.. .-.. ....- -... -.--" --fingerprint 11211112182111518211141216152111711

Output:

crAftwoRk Thus r0Bust dAr3s Lull4by

I want to decode my encoded password: Th1sIs4Str0ng-p@ssw0rd!

cpass decode "- .... .---- ... .. ... ....- ... - .-. ----- -. --. -....- .--. .--.-. ... ... .-- ----- .-. -.. -.-.--" -f 21312132113113131113113

Output:

Th1sIs4Str0ng-p@ssw0rd!

I want to decode my .txt file

cpass decode "/path/to/your/file.txt"
cpass decode "/path/to/your/file.txt" --upper-case
cpass decode "/path/to/your/file.txt" --title-case
cpass decode "/path/to/your/file.txt" --fingerprint FINGERPRINT

💀 Holy sh*t!

I want to decode my encoded passphrase!

cpass decode "áÑÑÑ Ñáá áÑÑÑ Ñáá ó Ñáá áÑÑÑ Ñáá ó Ñáá áÑÑÑ ó Ñáá Ñáá áÑÑÑ Ñáá ó áÑÑÑ ó Ñáá áÑÑÑ áÑÑÑ ó áÑÑÑ áÑÑÑ áÑÑÑ ó Ñáá áÑÑÑ Ñáá ó áÑÑÑ Ñáá áÑÑÑ ó ÑÑáá ó áÑÑÑ ó Ñáá Ñáá Ñáá Ñáá ó Ñáá Ñáá áÑÑÑ ó Ñáá Ñáá Ñáá ó ÑÑáá ó Ñáá áÑÑÑ Ñáá ó áÑÑÑ áÑÑÑ áÑÑÑ áÑÑÑ áÑÑÑ ó áÑÑÑ Ñáá Ñáá Ñáá ó Ñáá Ñáá áÑÑÑ ó Ñáá Ñáá Ñáá ó áÑÑÑ ó ÑÑáá ó áÑÑÑ Ñáá Ñáá ó Ñáá áÑÑÑ ó Ñáá áÑÑÑ Ñáá ó Ñáá Ñáá Ñáá áÑÑÑ áÑÑÑ ó Ñáá Ñáá Ñáá ó ÑÑáá ó Ñáá áÑÑÑ Ñáá Ñáá ó Ñáá Ñáá áÑÑÑ ó Ñáá áÑÑÑ Ñáá Ñáá ó Ñáá áÑÑÑ Ñáá Ñáá ó Ñáá Ñáá Ñáá Ñáá áÑÑÑ ó áÑÑÑ Ñáá Ñáá Ñáá ó áÑÑÑ Ñáá áÑÑÑ áÑÑÑ" -d "á" -D "Ñ" -s "ó" -L russian -f 121262126213221271421191115212312161516222252218222915212411111712229221922241514122721821262221182226192122822182122621226222213122241211
cpass decode "йДйД ДйД Дй ДДйД й Дйй ййй ДйД йДй з й ДДДД ДДй ДДД з ДйД ййййй йДДД ДДй ДДД й з йДД Дй ДйД ДДДйй ДДД з ДйДД ДДй ДйДД ДйДД ДДДДй йДДД йДйй" -d "Д" -D "й" -s "з" -f 11211112162111319211161219132111511

Output:

йДйД ДйД Дй ДДйД й Дйй ййй ДйД йДй з й ДДДД ДДй ДДД з ДйД ййййй йДДД ДДй ДДД й з йДД Дй ДйД ДДДйй ДДД з ДйДД ДДй ДйДД ДйДД ДДДДй йДДД йДйй
crAftwoRk Thus r0Bust dAr3s Lull4by

I want to encode my secret words for my crypto wallet

cpass encrypto "/path/to/your/secret-words.txt"

Output:

+----------------+--------------------------------------+
| Original words | Encoded words                        |
+----------------+--------------------------------------+
| 1. abricot     | 1. .- -... .-. .. -.-. --- -         |
| 2. carapuce    | 2. -.-. .- .-. .- .--. ..- -.-. .    |
| 3. tristan     | 3. - .-. .. ... - .- -.              |
| 4. parapluie   | 4. .--. .- .-. .- .--. .-.. ..- .. . |
| 5. ouvrir      | 5. --- ..- ...- .-. .. .-.           |
| 6. rateau      | 6. .-. .- - . .- ..-                 |
| 7. clavier     | 7. -.-. .-.. .- ...- .. . .-.        |
| 8. souris      | 8. ... --- ..- .-. .. ...            |
| 9. ordinateur  | 9. --- .-. -.. .. -. .- - . ..- .-.  |
| 10. travail    | 10. - .-. .- ...- .- .. .-..         |
| 11. traduire   | 11. - .-. .- -.. ..- .. .-. .        |
| 12. oublier    | 12. --- ..- -... .-.. .. . .-.       |
+----------------+--------------------------------------+

I want to encode my secret words and store the value in a .txt file

cpass encrypto "/path/to/your/secret-words.txt" --output /path/to/your/encoded-words.txt

I want to decode my encoded secret words

cpass decrypto "/path/to/your/encoded-secret-words.txt"

Output:

+--------------------------------------+---------------+
| Encoded words                        | Decoded words |
+--------------------------------------+---------------+
| 1. .- -... .-. .. -.-. --- -         | 1. abricot    |
| 2. -.-. .- .-. .- .--. ..- -.-. .    | 2. carapuce   |
| 3. - .-. .. ... - .- -.              | 3. tristan    |
| 4. .--. .- .-. .- .--. .-.. ..- .. . | 4. parapluie  |
| 5. --- ..- ...- .-. .. .-.           | 5. ouvrir     |
| 6. .-. .- - . .- ..-                 | 6. rateau     |
| 7. -.-. .-.. .- ...- .. . .-.        | 7. clavier    |
| 8. ... --- ..- .-. .. ...            | 8. souris     |
| 9. --- .-. -.. .. -. .- - . ..- .-.  | 9. ordinateur |
| 10. - .-. .- ...- .- .. .-..         | 10. travail   |
| 11. - .-. .- -.. ..- .. .-. .        | 11. traduire  |
| 12. --- ..- -... .-.. .. . .-.       | 12. oublier   |
+--------------------------------------+---------------+

I want to decode my encoded secret words and store the value in a .txt file

cpass decrypto "/path/to/your/encoded-secret-words.txt" --output /path/to/your/decoded-words.txt

🙏 Support me

Liberapay

Liberapay Receives

Bitcoin

Bitcoin

Metadata

Release files for cpass-cli 1.0.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for cpass-cli 1.0.0
File Size Uploaded
cpass_cli-1.0.0.tar.gz 24.5 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for cpass-cli 1.0.0
File Interpreter ABI Platform
cpass_cli-1.0.0-py3-none-any.whl Python 3 none any Details

Total release size: 45.4 kB

Release files / cpass_cli-1.0.0.tar.gz

Download URL cpass_cli-1.0.0.tar.gz
Size 24.5 kB
Tags Source
SHA-256 checksum
How to use checksums
1f07a990cca4aab9b9e0b820e1be4290805fb5e4e8cd216316e4e1240345d51d
BLAKE2b-256 checksum
How to use checksums
576dcb242383fa9cd8282c2afe081c5f4cb0ce2407ebcd258db855f70fafc60b
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release files / cpass_cli-1.0.0-py3-none-any.whl

Download URL cpass_cli-1.0.0-py3-none-any.whl
Size 20.9 kB
Tags Python 3
SHA-256 checksum
How to use checksums
c575d0e68d7e58f3788d2da223bd5eba6577f233aa42eda0df46030dea8f185d
BLAKE2b-256 checksum
How to use checksums
397286571071d32d3da38fa0e7d2d0944776b6146ccb45c101f11047c52fda84
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.13.15

Release history Release notifications | RSS feed

This release

1.0.0 This release

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page