Giter Site home page Giter Site logo

pyexfil's Introduction

PyExfil

Stress Testing Detection & Creativity

Contributions Welcome HitCount PyPI download month PyPI license GitHub stars made-with-python

Logo

PyExfil was born as a PoC and kind of a playground and grew to be something a bit more. In my eyes it's still a messy PoC that needs a lot more work and testing to become stable. The purpose of PyExfil is to set as many exfiltration, and now also communication, techniques that CAN be used by various threat actors/malware around to bypass various detection and mitigation tools and techniques. You can track changes at the official GitHub page.

Putting it simply, it's meant to be used as a testing tool rather than an actual Red Teaming tool. Although most techniques and methods should be easily ported and compiled to various operating systems, some stable some experimental, the transmission mechanism should be stable on all techniques. Clone it, deploy on a node in your organization and see which systems can catch which techniques.

Getting Started

PIP

For using pip (not necessarily the most updated):

pip install --user PyExfil

Prerequisites

For source:

git clone https://www.github.com/ytisf/PyExfil
cd PyExfil
pip install --user -r requirements.txt

We recommend installing py2exe as well so that you may cross compile various modules to a binary for easier transportation. You can do that with:

pip install py2exe

Installing

Go to the same folder where PyExfil was cloned to and:

pip setup.py --user install

List of Techniques

For usage per modules have a look at the USAGE file.

Data Generation

Although this tool was initially created as a game and later on turned to be a Red Team oriented tool, at the end of a day a major usage of PyExfil is to test various DLP (Data Leakage Protection) systems as well as detection of intrusion. To make the latter mission simpler we have created a little module to generate fake data with a structure that matches both PII and PCI data sets. These are intended to trigger alerts while being broadcated outside of the network.

Here is how to use it:

from pyexfil.includes import CreateTestData

c = CreateTestData(rows=1000, output_location="/tmp/list.csv")
c.Run()

After this you can use which ever PyExfil module you would like to try and exfiltrate the data set created. This way you can test your detection without risking exfiltrating valuable data.

Contributions

We welcome it! From testing, to improving quality of code and up to entirely new methods.

Future Changes

Versioning

For details about version look at the tags on this repository.

Version 1.0.0!

  • Surprise on restructure (Add Another).
  • Split DOCUMENTATION.md and README.md to two different files.
  • Get a nice logo.
  • Uniform calling convention for newer modules.
  • Exfiltration data-set generator (PII&PCI).

Version 1.3 - Harpax:

  • Adding 4 new modules.
  • General fixups.
  • Some old modules recoded to fit new standard.
  • Full compatibility between Python2 and Python3.

Version 1.4 - ?:

  • Expand physical exfiltration channels.
  • Re-test servers on older modules.
  • Add file manipulation class (for example, module zipception does not fit into any existing category although currently residing under Stega).

Hopefully - Close Future

  • Attempt at creating a more uniform call convention.
  • Fix that poorly written setup.py.
  • Backport all old modules to new calling convention.

In the Distant Future - The Year 2000

  • Add Golang/C++ support for portability.
  • Extensive testing for py2exe support.

Acknowledgments

People & Companies

  • Big shout out to JetBrains!!!
  • Thanks to barachy and AM for ideas on protocols to use.
  • Thanks to Itzik Kotler for some ideas.

Resources

  • Thanks Wireshark for your awesome wiki and tool. Especially packet dumps.
  • Shout out to the nmap guys.
  • Thanks to Trey Hunner for the package names.
  • The Faker package.
  • Special thanks to Thomas Baruchel and Fredrik de Vibe for the txt2pdf package we used in the braille exfiltration package.

pyexfil's People

Contributors

ytisf avatar dzertlife avatar matthieuxyz avatar james-richards-privitar avatar dabi0ne avatar adulau avatar sheksa avatar tisf avatar

Watchers

James Cloos 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.