Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
From https://reverseengineering.stackexchange.com/questions/33339/how-to-decrypt-zte-f670-routers-encrypted-config-bin-with-payload-type-5-with-t/33340
Step 1: Download the firmware - https://www.tripleoxygen.net/files/devices/zte/f670l/v1/firmware/stock/?SD
Step 2: Extract with
binwalk
- it has ajffs2-root
of the file systemStep 3: Interact with the file system enough to see the
httpd
service - js files associated and thehttpd
ELF file that is the server binaryStep 4: load
httpd
into IDA - See that it useslibdb.so
to manage the database. Loadlibdb.so
into IDA - it useslibharcode.so
Step 5:
libhardcode.so
uses/etc/hardcode
as input to decrypt files in/etc/hardcodefile
Step 6: RE the implementation to decrypt the file
/etc/hardcodefile/dataprotocol
to revealfor the files attached in the question
Step 7: Apply this diff to the mentioned repo
and voila you can decrypt the file too