Hacker News new | ask | show | jobs
by smackay 5160 days ago
This is not as much of a burden as would first appear. The vast majority of Flash files (except those that rely exclusively on actionscript for rendering) are based on as relatively small set of primitives/instructions: place object, move object, show frame, etc. When new features were added typically a new instruction was introduced. Only very rarely was an existing instruction modified for example PlaceObject2 being extended to include optional event handlers for movie clips.

A big problem with all things Flash-related is that Adobe was rather half-hearted in its commitment to making Flash open so the documentation was never quite as polished as it could be. Another problem which probably the source of the frustration in the original post is that functionality was added rather than existing code upgraded. That probably meant that the existing code along with all the warts was left untouched rather than run the risk of making breaking changes.

The "interesting stuff like jumps past the end of function" were I think attempts at obfuscation since decompiling flash files and actipnscript is not very difficult. Another example was to append actionscript byte-codes at the end of a table used for strings and amend the length of the table to hide the code. The following actionscript byte-codes could then add jump into this hidden code which would hopefully but not successfully confuse the decompilers.