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

Unable to run the tool on Kali linux #5

Open
edwinsunder opened this issue Apr 25, 2023 · 1 comment
Open

Unable to run the tool on Kali linux #5

edwinsunder opened this issue Apr 25, 2023 · 1 comment

Comments

@edwinsunder
Copy link

The below errors occur

  1. Does anyone have a compiled binary executable for hwfw?
  2. Tested with more than one BIN file - anyway the errors are talking about the script having an issue.
  3. Just FYI - I have a HG8145v device that I am trying to unlock - It lets me go to shell but i cant do anything there except for exit or run one .sh file
  4. Main question once unpacked and then modified - will I be able to burn this Modified/edited firmware from the routers webpage - where it lets you select and upgrade firmware's from?
  5. Or will it need the HW_ONT_Tool.exe to burn/write the firmware to router?

─# python hwfw.py unpack -v -r fw/ ./test2/R020.bin
Traceback (most recent call last):
File "/home/kali/Downloads/hwfw/hwfw.py", line 287, in
main()
File "/home/kali/Downloads/hwfw/hwfw.py", line 284, in main
sys.exit(entry(opt))
^^^^^^^^^^
File "/home/kali/Downloads/hwfw/hwfw.py", line 268, in entry
return unpack(opt)
^^^^^^^^^^^
File "/home/kali/Downloads/hwfw/hwfw.py", line 259, in unpack
fw.open(opt['FILE'])
File "/home/kali/Downloads/hwfw/hwfw.py", line 47, in open
self._loadFromString(data, noItemData)
File "/home/kali/Downloads/hwfw/hwfw.py", line 55, in _loadFromString
offset += self._parseItemInfo(data, offset, noItemData)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "/home/kali/Downloads/hwfw/hwfw.py", line 71, in _parseItemInfo
for i in xrange(self.header.itemCount):
^^^^^^
NameError: name 'xrange' is not defined. Did you mean: 'range'?

@D0MlNIC
Copy link

D0MlNIC commented Jan 9, 2024

I don't know if you are still trying to achieve the above task.

But this python script is written in python2 not in python3.

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

2 participants