hbctool
hbctool copied to clipboard
Hermes Bytecode Reverse Engineering Tool (Assemble/Disassemble Hermes Bytecode)
Add support for the latest Hermes.
The example `index.android.bundle` file is version 74 and not 76 ``` 00000000: c61f bc03 c103 191f 4a00 0000 d031 0a88 ........J....1.. ``` byte `0x9` should be `4c` and not `4a`
Hi, i got error with command "hbctool disasm index.android.bundle test_hasm". Please help: [*] Disassemble 'index.android.bundle' to 'test_hasm' path Traceback (most recent call last): File "C:\Program Files\Python310\lib\runpy.py", line 196, in _run_module_as_main...
I can't understand the decompiled file, can I restore it to JavaScript in the future? This is very helpful to me, thanks!
I've listed commit tree url for every hermes bytecode version. So it can be easy to search for building the opcodes: - 78 https://github.com/facebook/hermes/blob/c57fde25efaef83cec7e80b27e064d31d7bb166e/include/hermes/BCGen/HBC/ - 79 https://github.com/facebook/hermes/tree/05b29726e766594ae0a9be7947dd1378303d9a42/include/hermes/BCGen/HBC - 80 https://github.com/facebook/hermes/tree/e70045d8430e7913e2f74695402d9fb12214e4f4/include/hermes/BCGen/HBC...
If not, can it be supported?
As it stands, it's difficult to (a) determine the object keys/values used in `New*WithBuffer` instructions, and (b) determine the exact location of a jump. It would be great if this...
``` hbctool Traceback (most recent call last): File "/usr/local/bin/hbctool", line 11, in load_entry_point('hbctool==0.1.5', 'console_scripts', 'hbctool')() File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 489, in load_entry_point return get_distribution(dist).load_entry_point(group, name) File "/usr/local/lib/python2.7/dist-packages/pkg_resources/__init__.py", line 2793, in load_entry_point...
When I " hbctool asm edited index.android.bundle" hbc.setString(string["id"], string["value"]) \appdata\local\programs\python\python39-32\lib\site-packages\hbctool\hbc\hbc59\__init__.py", line 142, in setString assert l
I think it is hard to write patch code to hbc, when I added some patch code to hbc in some offset of instruction segment, the offset will be reuse...