Coder Social home page Coder Social logo

Comments (8)

hugsy avatar hugsy commented on August 25, 2024

That's not implemented yet, but it's on the TODO list.

from gef.

Grazfather avatar Grazfather commented on August 25, 2024

I played with this tonight. Shouldn't be too difficult.

We need a way to have structures reference eachother.

  1. The name shoudn't have to be Template
  2. We should allow more than one per file. Maybe they would be referenced by module? e.g. dt heap.main_arena, allowing something like heap.fast_bins to exist in the same module and obviously allow them to reference each other.
  3. Should we allow inter-module? This gets a bit tricky because the importing between would be weird. I hacked this in a test module by editing sys.path which is very bad style

Note that this only works for embedded structures not pointers to structures.

from gef.

hugsy avatar hugsy commented on August 25, 2024

@Grazfather : I totally missed your comment on this ... I needed this feature on a CTF this weekend, so I was about to get to it. Do you already have a patch ready for that?

from gef.

Grazfather avatar Grazfather commented on August 25, 2024

Mine is super ugly, but I can push it.

EDIT: https://github.com/Grazfather/gef/tree/embed

from gef.

hugsy avatar hugsy commented on August 25, 2024

I'll have a look but I've also started on my end 😄

from gef.

Grazfather avatar Grazfather commented on August 25, 2024

For sure. It's easy enough to implement, I just wasn't sure a nice way to have the modules find each other (sys.path stuff) and how to make it look.

from gef.

hugsy avatar hugsy commented on August 25, 2024

For now, I'm using pcustom.struct_path to "manually" load the desired module (with imp): for every .py file in the directory, I am importing all classes from the variable exportables. This approach allows to not touch the Python path, but also to select which class are to be visible.

from gef.

hugsy avatar hugsy commented on August 25, 2024

This was fixed long ago.

from gef.

Related Issues (20)

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.