RABCDAsm is a collection of utilities for working with ActionScript 3 bytecode, including an assembler/disassembler and tools for manipulating SWF files.
- Parse and manipulate ABC (ActionScript Byte Code) files
- Extract and modify SWF file contents
- Assemble and disassemble ActionScript 3 bytecode
- Python API for programmatic access to all features
pip install -r requirements.txt
from rabcdasm import ABCFile, SWFFile, Assembler
# Load and parse a SWF file
swf = SWFFile()
swf.load('example.swf')
# Extract ABC blocks
abc_blocks = swf.extract_abc()
# Parse ABC file
abc = ABCFile()
abc.load('script.abc')
# Assemble ActionScript
assembler = Assembler()
bytecode = assembler.assemble('script.asasm')
# Extract ABC from SWF
python -m rabcdasm extract example.swf
# Disassemble ABC file
python -m rabcdasm disassemble script.abc
# Assemble ABC file
python -m rabcdasm assemble script.asasm
The syntax of the disassembly is designed to be simple and allow fast and easy parsing. It closely represents the ABC file format while remaining human-readable.
- ABC File Format: The compiled bytecode format for ActionScript 3
- SWF File Format: The container format for Flash content
- Assembly Syntax: A human-readable representation of ABC bytecode
For more details, see the AVM2 Overview.
- Fork the repository
- Create your feature branch (
git checkout -b feature/amazing-feature
) - Commit your changes (
git commit -am 'Add some amazing feature'
) - Push to the branch (
git push origin feature/amazing-feature
) - Open a Pull Request
This project is licensed under the MIT License - see the LICENSE file for details.
- Adobe's AVM2 Overview documentation
- The Flash/ActionScript community