GithubHelp home page GithubHelp logo

decrypter's Introduction

decrypter

Decoder For Base Encoding Schemes

version GitHub license

DECRYPTER is a tool written in Python that can decode all alphanumeric base encoding schemes. This tool can accept single user input, multiple inputs from a file, input from argument, multi-encoded bases, bases in image EXIF data, bases on images with OCR and decode them incredibly fast.

For a basic demo, try the Web Interface that uses decrypter's API.

Fun Fact!
I initially made this after being fed up with lame CTF challenges with multi-encoded bases. Now some of them started doing that in Steganography challenges so I automated that too smh!

Table of Contents

Features

  • Decode multi-encoded bases of any pattern.
  • Decode bases in image EXIF data.
  • Decode bases on images with OCR detection.
  • Can decode multiple base encodings from a file.
  • Generate a wordlist/output with the decoded bases.
  • Predicts the type of encoding scheme.

Supported Encoding Schemes

  • Base16
  • Base32
  • Base36
  • Base58
  • Base62
  • Base64
  • Base64Url
  • Base85
  • Ascii85
  • Base91
  • Base92
  • Base100

Installation

$ git clone https://github.com/WHITEHELL097/DECRYPTER
$ cd decrypter
$ pip3 install -r requirements.txt
$ python3 decrypter.py -h

NOTE: Python3 is recommended to use!

Linux:

$ sudo apt-get update
$ sudo apt-get install tesseract-ocr libtesseract-dev

MacOS:

$ brew install tesseract

Usage

Get a list of all the arguments:

python3 decrypter.py -h

To decode a single base encoding from user input:

python3 decrypter.py

To decode a single base encoding from argument (-b/--base):

python3 decrypter.py -b SGVsbG8gV29ybGQh

To decode multiple base encodings from a file (-f/--file):

python3 decrypter.py -f file.txt

Magic Mode: To decode multi-encoded base of any pattern (-m/--magic):

python3 decrypter.py --magic

To input an image for EXIF/OCR detection mode (-i/--image):

python3 decrypter.py -i image.jpg (--exif/--ocr)

EXIF Data: To decode bases in image EXIF data (-e/--exif):

python decrypter.py -i image.jpg --exif

OCR Base Detection: To decode bases on image with OCR detection (-c/--ocr):

python decrypter.py -i image.jpg --ocr

To generate a wordlist/output with the decoded bases (-o/--output):

python decrypter.py -f file.txt -o output-wordlist.txt

Magic Mode

Now you can decode multi-encoded bases of any pattern in a single shot.

Have you ever stumbled upon that one lame CTF challenge that gives you an encoded string which is just encoded over and over with Base64, Base91, Base85 and so on? Just give that to decrypter and you're done with it! ;)

Want to test it out? Just give it this input:

IX(Fp@nNG6ef<,*TFE]IT^zdINAb9EVbp,e<u=O6nN)/u+MTnU;Fo#VvQ&cK;mLZI#Jbdook<O{W#+gY%ooe#6pTkTa.9YPU8Uc=pl9BhSM9%kISw2k:8..u/6F2BwNndPZ2o#7NHNP3g,HlZu><*[Nv+T8

and see for yourself! :)

decrypter API

decrypter can now be used as a library! Just import the decrypter() class and call the decode() function.

See API.

API

Want to use decrypter as a library? We got you covered!

Just put decrypter in your project's directory and you're ready to go!

Example:

# import the decrypter class from decrypter.py
from decrypter import decrypter

# calling the api function decode() with the encoded base
result = decrypter().decode('c3BhZ2hldHRp')

# printing the output
"""
result is tuple where:
result[0] = DECODED STRING
result[1] = ENCODING SCHEME
"""
print('Decoded String: {}'.format(result[0]))
print('Encoding Scheme: {}'.format(result[1]))

Output:

Decoded String: spaghetti
Encoding Scheme: Base64

Contribution

Ways to contribute

  • Suggest a feature
  • Report a bug
  • Fix something and open a pull request
  • Help me document the code
  • Spread the word

Before you open a PR, make sure everything's good by running the tests:

Unit Tests: (Thanks ๐Ÿ”ฅโƒžโƒจโƒ•โƒ—อŽโƒ•โƒ”อ ๐–๐‡๐ˆ๐“๐„๐Ÿ‡ฉ๐™š๐™ซ๐™ž๐™ก ๐™ ๐™ž๐™ฃ๐™œโ‰›โƒโ‰›โƒ)

python3 -m unittest discover -v -s tests

License

Licensed under the MIT License, see LICENSE for more information.

decrypter's People

Contributors

whitehell097 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.