Coder Social home page Coder Social logo

scarletthoefler / cipheycore Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ciphey/cipheycore

0.0 0.0 0.0 178 KB

Some cryptanalysis tidbits written in a *proper* language

License: MIT License

CMake 2.14% C++ 95.34% SWIG 1.82% Python 0.70%

cipheycore's Introduction

PyPI Tests Downloads Downloads Downloads

CipheyCore

Some cryptanalysis tidbits written in a proper language

This core provides many crackers, encryption methods & decryption methods as well as cryptanalysis tidbitis to Ciphey. Written in C++ for the speed.

Installation

CipheyCore can be installed via MacPorts:

sudo port install py-cipheycore

By default, this installs CipheyCore for python 3.9. To install it for Python 3.8, replace py-cipheycore with py38-cipheycore.

Dependencies

CipheyCore builds as a static library, but depends on some of Boost's header-only libraries.

Platform Command
Debian/Ubuntu/Mint apt-get install libboost-dev cmake build-essential swig
Arch pacman -S boost gcc cmake make swig
CentOS/RHEL yum install boost-devel cmake3 llvm-toolchain-7 make swig
Homebrew (macOS) brew install boost swig
MacPorts (macOS) sudo port install cmake boost poetry swig-python swig
Chocolatey (Windows) choco install swig and install boost from boost.org

โš ๏ธ Note: This project requires gcc>=8. Depending on which platform you are on, you might experience that the default gcc is a lower version. You can check your gcc version by running gcc -v.

Building

CipheyCore can be used as a C++ library for use in other C++ projects, or as a python3 module (with reduced functionality and speed).

The python module depends on the C++ library, so follow both instructions if you want the python module.

C++ library

Linux/OSX/other Unices

git clone https://github.com/Ciphey/CipheyCore
cd CipheyCore
rm -rf build
mkdir build
cd build
cmake .. -DCMAKE_BUILD_TYPE=Release -DCIPHEY_CORE_TEST=OFF # Or '-DCMAKE_BUILD_TYPE=Debug' for a debug build
cmake --build . -t ciphey_core

If that doesn't work, try setting -DCIPHEY_CORE_PYTHON= to the folder containing your python headers and -DBOOST_ROOT= to the directory containing your boost headers.

Windows

git clone https://github.com/Ciphey/CipheyCore
cd CipheyCore
rd /S build
cd build
cmake .. -DCIPHEY_CORE_TEST=OFF
cmake --build . -t ciphey_core --config Release # Or '--config Debug' for a debug build
poetry build

As with the Unix compilation, if you are having problems with missing files, try setting -DCIPHEY_CORE_PYTHON and BOOST_ROOT.

Python3 library

This requires python-poetry, which can be installed with python3 -m pip install poetry (or, failing that, python -m pip install poetry).

After you have built the C++ library, compile the python interface with

cmake --build . -t ciphey_core_py --config Release # Or '--config Debug' for a debug build
poetry build

The wheel will be located in the dist folder. The source distribution (.tar.gz file) produced is rather useless, as it contains the compiled platform-specific library.

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.