Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

The HBC version (94) is not supported. #40

Open
lt1023 opened this issue Dec 27, 2023 · 10 comments
Open

The HBC version (94) is not supported. #40

lt1023 opened this issue Dec 27, 2023 · 10 comments

Comments

@lt1023
Copy link

lt1023 commented Dec 27, 2023

please!

@powereureka
Copy link

i have a version with support of hbc v94

@flex0geek
Copy link

Hi, where is the version that help with v94.

@jamesmacwhite
Copy link

jamesmacwhite commented Jan 27, 2024

There is a fork that has it: https://github.com/gilcu3/hbctool under https://github.com/gilcu3/hbctool/tree/hbc94

Credit: https://www.linkedin.com/pulse/reverse-engineering-lovebox-react-native-app-high-level-zagaria-vmhre

There's also https://github.com/P1sec/hermes-dec/ which supports up to version 96 at the time of writing.

@flex0geek
Copy link

thank you @jamesmacwhite for your comment, Do you have documentation for the bytecodes of Hermes?

@jamesmacwhite
Copy link

thank you @jamesmacwhite for your comment, Do you have documentation for the bytecodes of Hermes?

This exists, which P1 security wrote: https://p1sec.github.io/hermes-dec/opcodes_table.html. The hermes-dec tool can also generate psedo JavaScript from the bytecode, but it's not technically going to be 100% accurate to the original JavaScript.

@flex0geek
Copy link

thank you so much for this link @jamesmacwhite, I'm trying to change the logic of the application and rebuild it successfully from the hasm file which outputs from hbctool the app that I'm working on is hermes v94 and the opcode table stops at 89, do you have recommendation for this?
I want to do simple things like swap the condition from if not to if or something like that.

@jamesmacwhite
Copy link

jamesmacwhite commented Jan 30, 2024

You need to use the forked version and build the source yourself: https://github.com/gilcu3/hbctool/tree/hbc94

Then install package directly: https://github.com/gilcu3/hbctool/tree/hbc94?tab=readme-ov-file#contribution.

There is an alternative tool that has direct support for newer versions: https://github.com/P1sec/hermes-dec/, however I don't believe it can re-assemble.

I can't advise on modifying bytecode itself, as I've only done it for reverse engineering, not to modify an application.

@flex0geek
Copy link

thank you for that if u find a way to re-assemble it i will be thankful if you share it with me https://twitter.com/FlEx0Geek, thank you so much

@jamesmacwhite
Copy link

@flex0geek If you take a look at: https://www.linkedin.com/pulse/reverse-engineering-lovebox-react-native-app-high-level-zagaria-vmhre/, the author details how they reassembled a change they made. I haven't personally tried it, but use that as your reference.

As mentioned before you will need to clone the fork linked with the hbc94 branch, build the source and install the locally built package for hbctool to have version 94 support, then do what you need to do.

@flex0geek
Copy link

Thank you so much for this reference it will be helpful.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

4 participants