Set constant value for structure members

Aperta
#8,670 0 commenti 1 reazione 0 assegnatari Vedi su GitHub

I maintainer di solito rispondono entro 2 giorni

Nessuno ha ancora preso questa issue.

Valutazione

Difficoltà
5/5
Tempo stimato
Più di una settimana
Idoneità per principianti
12/100
Tipo di issue
Funzionalità
Chiarezza
Da chiarire
Stato di attività
Attiva
Stack tecnologico
cpp

Direzione di ricerca

The issue names no files, tests or entry points, so the first step is to find where structure member types and dataflow constant values are handled in the Binary Ninja analysis code. The open question is whether the constant belongs to the type or to the view, and that needs a maintainer decision before any code is written. Done would mean a settled design plus a way to assert a member's value during dataflow.

Scritto dal modello di indicizzazione a partire dal testo della issue.

Descrizione

What is the feature you'd like to have?
I want the ability to specify a constant value of a structure type member, such that when that member is read during analysis, dataflow asserts that the value is whatever constant I have specified. Not sure if this should be a property of the type itself or of the view as a sort of view-level UIDF constant.

Is your feature request related to a problem?

  1. I have a structure with a field that is always set to a specific constant, and I want all functions using this structure to know of that value
  2. I have a C++ class definition with a vtable and want to poke the address of the vtable in the data segment into the vtable member, such that indirect calls through the vtable can automatically discover the concrete destinations for functions.

Are any alternative solutions acceptable?
I can write a script to iterate all uses of that structure member and UIDF the variable it gets loaded into, but this is kinda messy and needs to be re-ran every time analysis updates

Additional Information:
Reported by loadlibrary on Slack, also me because I want the vtable thing

Lingua principale
C++
Stelle
1.3k
Fork
304
Merge medio
2g 20h
PR unite (30g)
10

Preparare l'ambiente

Questo progetto non fornisce container di sviluppo, Dockerfile né guida per i contributori, quindi l'ambiente è a tuo carico: parti dal suo README e consulta la nostra guida al primo contributo per i passaggi generali.

Come iniziare

  1. Leggi tutta la issue e poi la guida ai contributi del progetto.
  2. Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
  3. Fai un fork del repository e lavora su un branch.
  4. Apri una pull request che faccia riferimento al numero della issue.

Altre issue di Vector35/binaryninja-api

Tutte le issue di Vector35/binaryninja-api

Issue simili

Altre issue su C++

Ricevi le nuove issue nella tua casella

Un breve riepilogo di issue GitHub adatte ai principianti.