Coder Social home page Coder Social logo

caesar-utils's Introduction

Build Status

Caesar utils

Description

Customizable Caesar cipher encrypting/decrypting CLI tool written in C. Supports custom dictionaries, finding the correct variant by the known part of a string (implemented using Levenshtein distance and Wagner-Fischer algorithm).  

Usage

usage: ./caesar-utils [-h] [-sae] [-c] [-v]

default: decode Caesar cipher knowing original message with some replaced symbols.
-s Decode Caesar cipher knowing substring of the original string.
-e Encrypt text at offset n.
-c Use custom alphabet (default: a-Z0-9).
-a Print all the possible variants.
-h Print this message.
-v Print debug information.

 

Download && Build

git clone https://github.com/nightshiba/caesar-utils
cd caesar-utils
cmake .
make

 

Run tests

chmod +x test.sh
./test.sh

 

Examples

  • ./caesar-utils
Enter the encrypted string:
efbecffg
Enter the corrupted original string:
somebeef

-> deadbeef

 

  • ./caesar-utils -a -c
Enter the custom alphabet:
1234
Enter the encrypted string:
23

->

23
34
41
12

 

  • ./caesar-utils -s
Enter the encrypted string:
mkoCkB
Enter the corrupted part or substring of the original string:
aes

-> caesar

 

  • ./caesar-utils -e -c
Enter the custom alphabet:
abcdefghijklmnopqrstuvwxyz
Enter the original string to encrypt:
secret
Enter shift offset:
2

-> ugetgv

 

License

caesar-utils's People

Contributors

nightshiba avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.