Vector35 / Vector35/binaryninja-api
Loading BNDB without reanalyzing in headless missing strings
Nobody has claimed this yet.
- Dominant language
- C++
- Stars
- 1.3k
- Forks
- 298
- Avg merge
- 5d 5h
- Merged PRs (30d)
- 19
Description
On latest dev loading a BNDB in headless without reanalyzing will cause there to be no strings, I cannot repro this using the UI and the suppress reanalysis setting.
Seems to be a regression of https://github.com/Vector35/binaryninja-api/issues/2942 however that ticket never mentions headless.
>>> view = binaryninja.load("/bin/cat")
>>> len(view.strings)
195
>>> view.create_database("/Users/emesare/Documents/cat.bndb")
True
>>> view2 = binaryninja.load("/Users/emesare/Documents/cat.bndb", update_analysis=False)
>>> len(view2.strings)
0
>>> view.file.existing_views
['Mach-O', 'Raw']
>>> view.file.view
'Hex:Raw'
>>> view2.file.existing_views
['Mach-O', 'Raw']
>>> view2.file.view
'Hex:Raw'
>>> mach_view = view2.get_view_of_type('Mach-O')
>>> len(mach_view.strings)
0
>>> raw_view = view2.get_view_of_type('Raw')
>>> raw_view
<BinaryView: '/Users/emesare/Documents/cat.bndb', len 0x1d0d0>
>>> raw_view.strings
[]
>>> mach_view.strings
[]
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
Reproduce the issue with binaryninja.load, create_database, update_analysis=False, and get_view_of_type, then compare the strings results for the loaded BNDB and its Mach-O and Raw views. Trace the headless BNDB loading path and verify that strings are available without reanalysis, matching the original view and the UI behavior.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, python
- Domain
- reverse-engineering
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 42/100