Vector35 / Vector35/binaryninja-api
Expose binaryview length / end on BinaryReader / BinaryWriter
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?
_BNIsEndOfFile already makes use of a function that gets the end of the underlying view. Expose this function (and ideally also the base and length getters) for BinaryReaders / BinaryWriters.
Is your feature request related to a problem?
I'm trying to use python libraries that expect a reader to act like a file object that's seekable and use os.SEEK_END. I want to implement this functionality on the BinaryReader.seek implementation (#3701).
Are any alternative solutions acceptable?
Alternative solutions for include:
- A getter for the underlying
BNBinaryViewobject on the BNBinaryReader. - saving a reference to the binaryview on the binary reader in python.
- documentation of the internal structure of the core structs so we can get the data out ourselves ;)
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 tracing the existing _BNIsEndOfFile function and the BinaryReader.seek implementation referenced in issue #3701, then inspect the BinaryReader and BinaryWriter APIs. Done means the underlying view's end, base, and length are exposed to readers and writers, or an explicitly documented equivalent supports the requested seek behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, python
- Domain
- devtools, reverse-engineering
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 38/100