Skip to content

Custom made cryptography algorithm, utilizing feistel network

Notifications You must be signed in to change notification settings

wirasuta/not-today-cryptography

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

16 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Not Today Cryptography

TL;DR

$ python3 main.py -h                                                  
usage: main.py [-h] [-i INPUT] [-f FILE] [-d] [-t] [-x] mode key

positional arguments:
  mode                  mode of operation, available ECB/CBC/Counter
  key                   192 bit key

optional arguments:
  -h, --help            show this help message and exit
  -i INPUT, --input INPUT
                        plaintext to be encrypted or ciphertext to be decrypted if -d is present
  -f FILE, --file FILE  input file
  -d, --decrypt         decrypt input
  -t, --time            time the encryption
  -x, --hex             print in hex format

# Encrypt string "ABBBBBBBBBBBBBBB" with mode "ECB" and key "aaaabbbbccccddddeeeeffff"
$ python3 main.py -t -i ABBBBBBBBBBBBBBB ECB aaaabbbbccccddddeeeeffff > ./result/out.enc
Elapsed time: 0.00018954

# Decrypt previously encrypted string, print result in hex
$ python3 main.py -t -d -x -f ./result/out.enc ECB aaaabbbbccccddddeeeeffff
b'41424242424242424242424242424242'
Elapsed time: 0.00026226

About

Custom made cryptography algorithm, utilizing feistel network

Topics

Resources

Stars

Watchers

Forks

Languages