Code Monkey home page Code Monkey logo

pcode-parser's Introduction

Pcode Parser

Parser for raw (low-level) Pcode generated from Ghidra, written in Rust.

Example in main.rs

The program parses a Pcode program like this one:

0x400f9c
(unique,0x5380,1) = LOAD (const,0x55706c52be80,8) (register,0x0,8)
(register,0x200,1) = INT_CARRY (unique,0x5380,1) (register,0x0,1)
[...]
0x400f9e

as follows:

Address: 0x400f9c
Inst { opcode: Load, output: Some(Varnode { var: Unique(0x5380), size: Byte }), inputs: [Varnode { var: Const("0x5643218c0ff0"), size: Quad }, Varnode { var: Register(0), size: Quad }] }
Inst { opcode: IntCarry, output: Some(Varnode { var: Register(200), size: Byte }), inputs: [Varnode { var: Unique(0x5380), size: Byte }, Varnode { var: Register(0), size: Byte }] }
[...]
Address: 0x400f9e

Usage

You can generate the raw Pcode of a binary using Pcode-generator and then use Pcode-parser to parse the produced pcode.

Credits and Acknowledgments

This Rust program was developed with the assistance and contributions of the following individuals and organizations:

  • @cchr-ledger : For providing the template for this parser, which was crucial for the successful completion of this project.
  • Michael Chesser (@mchesser) and Rubens Brandao (@rbran) : For their extensive knowledge in binaries parsing and Rust language, which greatly enhanced the functionality of this program.

pcode-parser's People

Contributors

kajaaz avatar rbran avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar

Forkers

rbran

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.