Coder Social home page Coder Social logo

marlboromoo / php-exif-backdoors-generator-using-custom-shellcode Goto Github PK

View Code? Open in Web Editor NEW

This project forked from ccsir/php-exif-backdoors-generator-using-custom-shellcode

0.0 3.0 0.0 241 KB

PHPEB is a small tool that generates and stores obfuscated shellcode in user specified EXIF handlers.

Home Page: http://ccsir.org

License: GNU General Public License v3.0

php-exif-backdoors-generator-using-custom-shellcode's Introduction

PHP EXIF Backdoors generator using custom shellcode

PHPEB is a small tool that generates and stores obfuscated shellcode in user specified EXIF handlers. The backdoor is divided into two parts. The first part is a mix of the exif_read_data function to read the image headers and the preg_replace function to execute the content and the second is the real payload obfuscated in EXIF a JPG/TIFF file headers.

Both functions are harmless by themselves. Exif_read_data is commonly used to read images and preg_replace to replace the content of strings. However, preg_replace has a hidden and tricky option where if you pass the โ€œ/eโ€ modifier it will execute the content (eval), instead of just searching/replacing.

Another interesting point is that the image that we generate still loads and works properly.

Started from Sucuri Research.

If you have any other cool ideas for obfuscating the shellcode, feel free to commit.

Note: This application has been created as a POC and it has an educational purpose only. We are not responsibles for any damage you may inflict/get using this tool.

##Usage

php phpeb.php [params]

##Params

  • -i path_to_image.jpg
  • -o path_to_backdoored_image.jpg
  • -s shellcode (optional)
  • -h EXIF headers (N/A in v1.0, Default:Make,Model)
  • -v verbose 1 or 0(optional, Default:0)
  • Default: !empty($1=@$_GET[1]) && $1($_GET[2]);

##Help

  • No need. Just download these files and upload in an environment that supports PHP. You can send any feedback or questions to contact [at] ccsir [dot] org

##License

Copyright (C) 2013 Cyber Security Research Center from Romania

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 3 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, see http://www.gnu.org/licenses/.

php-exif-backdoors-generator-using-custom-shellcode's People

Contributors

andreiavadanei avatar russiancoder avatar nicolaisoeborg avatar

Watchers

Timothy Lee avatar James Cloos avatar  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.