Relative offsets and possibly other structure assisting tools

Wishlists for new functionality and features.
Post Reply
MulleDK19
Posts: 2
Joined: 09 Jun 2018 22:37

Relative offsets and possibly other structure assisting tools

Post by MulleDK19 »

I mostly use Hex Editor Neo, because it has a lot of tools for modifying structures, and it makes construction of eg. PE files extremely easy.
But I'm planning on doing some tutorials in the future, and don't want to force a paid tool onto my viewers, so I'm looking for a free HEX editor.

I've used HxD in the past, and it's arguably one of the best free editors. But it doesn't make it easy to modify structures.
One thing that makes it hard, is the fact that it can't show offsets relative to a byte, so if you need to modify a structure that starts at eg. offset 0x47, it becomes a tedious mess of calculating offsets based off of that.

I'm currently resorting to editing the structures in a new empty file, then copying the data into the actual file.

It'd be nice if HxD was able to show the offsets relative to a specific file offset. Something like:
85HDq8m.png
85HDq8m.png (11.26 KiB) Viewed 4335 times
And maybe other tools to assist in editing complex structures. Like marking bytes with a color to easily find inline structures.

Obviously a structure viewer would be optimal, but that's no trivial feature.
wpe
Posts: 6
Joined: 15 Jun 2018 01:40

Re: Relative offsets and possibly other structure assisting tools

Post by wpe »

Wouldn't copying that data structure out to a new file be an easy alternative way? It will start at offset 0000 without any calculation.
Fireboyd78
Posts: 14
Joined: 02 Jan 2013 10:34

Re: Relative offsets and possibly other structure assisting tools

Post by Fireboyd78 »

Until something like this gets implemented (if ever), you could try using my method of seeking to relative offsets:
  1. Place the cursor at the beginning of the structure.
  2. Press Ctrl + E to bring up the 'Select block' dialog.
  3. Tab twice to the 'Length' input box.
  4. Enter the relative offset to the data.
  5. ???
  6. Profit!
Obviously you'd need to keep track of where the beginning of each structure is if you need to move the cursor at all, but typically if I'm checking multiple fields it's just a matter of adjusting the amount of selected bytes. Hopefully that makes sense.

Demonstration:
21D7N5O.gif
21D7N5O.gif (867.55 KiB) Viewed 4333 times
MulleDK19
Posts: 2
Joined: 09 Jun 2018 22:37

Re: Relative offsets and possibly other structure assisting tools

Post by MulleDK19 »

This would still very much be a welcome addition.
Maël
Site Admin
Posts: 1455
Joined: 12 Mar 2005 14:15

Re: Relative offsets and possibly other structure assisting tools

Post by Maël »

There is another request for importing Intel Hex files that have gaps (also at the start).
Something like this could be adapted, to have a folded region at the start (with undefined data), effectively "shifting" the starting offset.

A structure view is planned as well.

Currently, I develop UTF-8 support, which is a complicated topic: viewtopic.php?f=4&t=1004
Post Reply