Is there an unofficial spec anywhere that explains how to reverse engineer a Flash .FLA file?
I'm specifically interested in creating an application that can "auto-scene plan" a Flash document programmatically, pulling in content from other files, arranging that content into layers, without needing the Flash IDE open. Animators would then be able to take these pre-assembled FLA's and begin animating them. I've already built a JSFL script that does this, but it runs very slowly, is difficult to debug or re-purpose.
I've spent days looking around the internet, to see if there is anyway in to, do a reverse engineer but nought really. I don't there is a .FLA spec floating about. I've spent the last couple of days looking. If there was one, and you were using it, you would receive a cease and desist letter from Adobe, followed by the Canadian equivalent of the DMCA take down notice.
According to Wikipedia, the format is a binary format, which is based on a Microsoft Binary compound file format specification, described here on Wikipedia. Compound File Format. But strangely because of, I think, the European anti trust settlements forcing Microsoft to publish their specs means you can download the MS Compound File Format, here by typing Microsoft compound file format into Google. The first entry is the download link.
Once you have studied it, then you need to get a tool set together. It may be possible, there is a decompiler available for that format from MS. If not, your looking at maybe 3-6 months of work to get a basic spec together.
In the early 90's I reversed engineered the Novell IPX protocol and the NCP stack, which was a case of sending messages to the server, and getting a reply. So it fairly mechanical and tedious, after a few months we had a really good idea what was needed, and we built up a map of the IPX protocol calls, and replies. Same with NCP. We eventually were contacted by Novell who sent us a cease and desist and eventually wanted to sue us. But at the end of the day, they crapped out because we were using Clean Room techniques Wikipedia Clean Rooms explained. We pretty much took it apart from a server product in Binary, using a packet analyser, and rebuilt it using C++. But that was protocol reverse engineering. Much easier that what you are reflecting on.
So the first thing you need, is a disassembler. I can't give you any advice on what one to use, but there is many out there. Once you get the format, and you disassemble the file, you have to try and identify file headers, footers, constants, things like special symbol sequences, so you can start to create a map. For example on page 6 of the Windows Compound Binary File Format, it says in _absig has a signature format of DOCF 11E0 A1B1 1AE1. If you can find that kind of info in a the file, you start the map.
But before you go to that length, see if their is a decompiler about. I think most of the decompilers you find in Google will perhaps be lightweight. Go to hacker groups like these. CrackZ. That IDA product is a disassembler. This may help. Introduction to Reverse Engineering. Reverse Engineering Community
Hope that help. If you do, do it. It will take months. Persevere!
It should be noted that all FLA files saved in CS5 or later are now technically ZIP files that use the open XFL format. You can actually rename a FLA file to ZIP and decompress it. Subsequently, Flash supports saving directly to the XFL format.
The XFL format is a folder structure consisting of files and folders that correspond to the typical Flash file. These include a folders for the library and binary data (images, audio, etc.), as well as XML files which describe geometry, animation, etc. There are also XML files that keep track of global project settings such as linkages and export settings.
Finally, there is a .XFL file which acts as the entry point for the entire structure. This is what Flash looks for when it scans folders to determine if they're Flash XFL projects.
I would strongly recommend this format for anyone operating at an animation studio who needs to scene plan files externally from Flash. The library, scenes and other connections can all be created programmatically in the XFL format using whatever external programming language or tools you wish.
You might wanna check the swf file specification: http://www.adobe.com/devnet/swf/
Although there is no official documentation, this guy tried at least in some primary analysis
The fla format | benjaminwolsey.de http://benjaminwolsey.de/node/49
来源:https://stackoverflow.com/questions/1494617/is-there-an-unofficial-flash-fla-spec