Skip to content

Latest commit

 

History

History
81 lines (54 loc) · 909 Bytes

README.md

File metadata and controls

81 lines (54 loc) · 909 Bytes

CypherX

Tool to encode and decode simple cyphers.


CaesarCypher

Encode and decode Caesar cypher.

from CypherX import CaesarCypher

cypher = CaesarCypher("Hello World!!!", 13)

print(cypher)

"""
RAW: Hello World!!!
Key: 13
Encoded: Uryyb Jbeyq!!!
Decoded: Uryyb Jbeyq!!!
"""

print(cypher.encoded)

"""
Uryyb Jbeyq!!!
"""

CaesarCracker

Crack Caesar cypher.

from CypherX import CaesarCracker

cracker = CaesarCracker("Uryyb Jbeyq!!!")

print(cracker)

"""
...
12: Ifmmp Xpsme!!!
13: Hello World!!!
14: Gdkkn Vnqkc!!!
...
"""

VigenereCypher

Encode and decode Vigenere cypher.

from CypherX import VigenereCypher

cypher = VigenereCypher("Hello World!!!", "pizza")

print(cypher)

"""
RAW: Hello World!!!
Key: [15, 8, 25, 25, 0]
Encoded: Wmkko Lwqkd!!!
Decoded: Swmmo Hgsmd!!!
"""

print(cypher.encoded)

"""
Wmkko Lwqkd!!!
"""