Skip to content

Conversation

@WeiN76LQh
Copy link

In Binary Ninja it can be quite confusing when a segment is added that doesn't have any sections. libobjc.A.dylib::__OBJC_RW is an example of this. When scrolling through that segment there is no bar at the top of the linear view indicating where the data came from. When looking at the list of segments there are no names and with the different segment and section lists it can be hard to eyeball where a segment lands within the list of sections.

There is an argument here that the better solution is to change the way Binary Ninja displays information. For instance when scrolling through the linear view through a segment with no section, the segment information should be displayed at the top. Additionally segment names could be displayed in the segment list.

In Binary Ninja it can be quite confusing when a segment is added that doesn't have any sections. `libobjc.A.dylib::__OBJC_RW` is an example of this. When scrolling through that segment there is no bar at the top of the linear view indicating where the data came from. When looking at the list of segments there are no names and with the different segment and section lists it can be hard to eyeball where a segment lands within the list of sections.

There is an argument here that the better solution is to change the way Binary Ninja displays information. For instance when scrolling through the linear view through a segment with no section, the segment information should be displayed at the top. Additionally segment names could be displayed in the segment list.
WeiN76LQh pushed a commit to WeiN76LQh/binaryninja-api that referenced this pull request Mar 23, 2025
Similar to what is discussed in PR Vector35#6513 its useful to be able to see where an image header is as sometimes you want to inspect the load commands. Without a section its not very obvious where the header is.

The naming scheme of `${imageName}::__header` was chosen based on the naming choice of the DSC header.
@fuzyll fuzyll added the File Format: SharedCache Issue with the dyld_shared_cache plugin label Apr 3, 2025
@0cyn
Copy link
Member

0cyn commented Apr 28, 2025

I am of the opinion that the solution here is to:

  • Add support for names on segments (MemoryRegions, which dsc uses instead of segments, already adds names)
  • Add an Address display mode that supports segments
  • Add display of segment names in the Memory Map
  • Add a proper display of the segment name in the LinearView sticky header.

I think the golden standard would be sections in the view accurately reflecting sections in memory. There could be analysis repercussions from this. I'll invite further discussion on the topic.

@WeiN76LQh
Copy link
Author

I agree with all of that, this was just a stop gap solution because I didn't see any movement in that space in the time being and this didn't feel too problematic to implement for the time being.

@plafosse plafosse added this to the Helion milestone Jun 24, 2025
@0cyn
Copy link
Member

0cyn commented Jul 8, 2025

Hi! Thank you so much for the PR! After some internal discussion we've decided that we'd like to continue working towards a proper full solution for this rather than a bandaid fix, and discussion/progress can be tracked further via #7602 .

Thank you again for the PR

@0cyn 0cyn closed this Jul 8, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

File Format: SharedCache Issue with the dyld_shared_cache plugin

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants