Hacker News new | ask | show | jobs
by est 499 days ago
I remember there was a similar project on github allows visualize any type of binary data by a given schema. There was an TCP/IP example IIRC.
3 comments

https://kaitai.io/ maybe?

It looks perfectly nice for its role, but I didn’t use it for my last project because I need serialization as well.

Kaitai is very useful for reverse engineering a binary file that you have some assumptions of. I've used it for save file reverse engineering and then creating a read/write library for it. It should be usable for PDF Metadata.
HexFiend also has a template syntax for binary data visualization. It’s based on Tcl.

https://github.com/HexFiend/HexFiend/blob/master/templates/T...

Be careful, "any" is a strong word in this context. Interestingly enough, I actually use PDF as the "hello world" for kicking the tires on any such file format descriptor I find because PDF is such a crazypants specification. Thus, if the descriptor language is able to accurately capture the layout of a PDF, it's obviously well thought out.

I haven't had a lot of luck thus far, except ones which allow escaping out of declarative mode over into "and then run this code"