ma1co / fwtool.py

A tool to unpack Sony camera firmware images
MIT License
159 stars 30 forks source link

"KeyError: '_winzip_' fwtool returned -1" when attempting to unpack firmware #46

Open Loki44 opened 2 months ago

Loki44 commented 2 months ago

When trying to unpack a Sony A7 firmware on windows 10 I get the following error:

PS C:\Users\xxxx\Documents\sonytest> .\fwtool-v1.2-win.exe unpack -f Update_ILCE7V320.exe -o outDir
Extracting installer binary
Traceback (most recent call last):
  File "<string>", line 297, in <module>
  File "<string>", line 285, in main
  File "<string>", line 162, in unpackCommand
  File "<string>", line 94, in unpackInstaller
KeyError: '_winzip_'
fwtool returned -1

Is this a bug? or is there something I can do to fix this?

DukeTomlist commented 2 months ago

I also encountered such a problem. I think fwtool is not able to handle .exe file format. However, you can unpack the firmware as bellow:

  1. Use the Telnet and dump the firmware to the SD card (android 4 for example): dd if=/dev/nflasha of=/android/storage/sdcard0/DUMP.DAT bs=1M
  2. Use the fwtool to unpack the .dat file: fwtool unpack -f XXX.dat -o outDir

Hoping this will be helpful to you