Tuesday, January 1, 2008

Simple look at the java bytecode through python.

Here is some python code for loading the java binary class format. It only returns the first couple of bytes and will only convert the bytecode format into a data structure. It won't parse the data. Maybe we can look at that in the future.

Some useful python libraries:


"struct -- Interpret strings as packed binary data"



Another note, the java bytecode class is big-endian format and most of us work on little endian machines these days, just something to keep in mind.

No comments: