Giter Site home page Giter Site logo

pylane's Introduction

pylane

PyPI version

简体中文

Pylane is a python vm injector with debug tools, based on gdb and ptrace. Pylane uses gdb to trace python process, inject and run some code in its python vm.

Usage

pylane_show

use inject command to inject a python script in an process:

pylane inject <PID> <YOUR_PYTHON_FILE>

use shell command to inject an interactive shell:

pylane shell <PID>

Pylane shell features:

  • use IPython as its interactive interface, support magic functions like ? and %
  • support remote automatic completion
  • provide debug toolkit functions, such as:
    • lookup class or instance by name
    • get source code of an object
    • print all threads' stack and locals

Install

pip install pylane

pylane should be installed in virtualenv the target process uses or in os python lib.

Compatibility

Support Linux and BSD

pylane's People

Contributors

amigrave avatar cclauss avatar icallhimtest avatar valensc avatar

Stargazers

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

Watchers

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

pylane's Issues

Got Segmentation fault when attach a running progress.

OS: Linux rqams 3.10.0-862.11.6.el7.x86_64 #1 SMP Tue Aug 14 21:49:04 UTC 2018 x86_64 x86_64 x86_64 GNU/Linux

GDB: GNU gdb (GDB) Red Hat Enterprise Linux 7.6.1-114.el7

Python version: 3.7.3

I tried to attach a running python progress, but the progress terminated with a Segmentation fault.

Can't use it in docker container.

root@Q01:/gw_re_processor# pylane shell 6

('ptrace is disabled, enable it by: echo 0 | sudo tee /proc/sys/kernel/yama/ptrace_scope',)

root@Q01:/gw_re_processor# echo 0 | tee /proc/sys/kernel/yama/ptrace_scope

tee: /proc/sys/kernel/yama/ptrace_scope: Read-only file system

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.