Vector35 / Vector35/binaryninja-api
Bitfield resolution in MLIL/HLIL
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 1.3k
- Forks
- 298
- Avg merge
- 5d 5h
- Merged PRs (30d)
- 19
Description
What is the feature you'd like to have?
I would like to see resolved accesses to bitfields in HLIL, since we now can express them (bitfields) in our type system.
Is your feature request related to a problem?
Currently you must do math in your head to determine the accessed bitfield, for example:
The above is setting the first member a to 1 and 4 respectively for each structure.
Another, more annotated example:
MLIL listing:
Types:
Additional Information:
We also likely want to stop showing the first member being accessed, e.g. a in the examples above, and show either no access (the structure itself is loaded into the register) or some anonymous access, so that users do not get confused as to what is really getting accessed.
The above binary is available with: echo nebula rises persistently
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by reading the MLIL/HLIL bitfield examples in the issue and the referenced binary, then review issue 694's discussion of bitfields in the type system. Determine how resolved bitfield accesses should appear in HLIL and whether the first accessed member should be hidden or represented anonymously. Done means the examples show the actual bitfield accesses without requiring manual arithmetic.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp
- Domain
- compilers, reverse-engineering
- Issue type
- Feature
- Difficulty
- 5/5
- Estimated time
- Over a week
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100