fkie-cad / fact_extractor

Standalone Utility for FACT-like extraction
GNU General Public License v3.0
80 stars 31 forks source link

UnicodeDecodeError in uboot plugin #78

Closed ckudera closed 3 years ago

ckudera commented 3 years ago

Extracting US_W312AV1.0BR_V2.0.0.3(1330)_EN_TDE.bin (attached in ZIP archive: US_W312AV1.0BR_V2.0.0.3(1330)_EN_TDE.zip) leads to an UnicodeDecodeError in the uboot plugin.

Output:

$ ./extract.py US_W312AV1.0BR_V2.0.0.3\(1330\)_EN_TDE.bin 
[2021-02-06 08:49:10][unpack][WARNING]: Uboot could not extract any file from /tmp/extractor/input/US_W312AV1.0BR_V2.0.0.3(1330)_EN_TDE.bin -> generic carver fallback
[2021-02-06 09:49:11][extract][WARNING]: Now taking ownership of the files. You may need to enter your password.
{
    "plugin_used": "generic_carver",
    "plugin_version": "0.8",
    "error": "<class 'UnicodeDecodeError'>: 'utf-8' codec can't decode byte 0x80 in position 6: invalid start byte",
    "analysis_date": 1612601350.8576572,
    "number_of_excluded_files": 0,
    "0_FALLBACK_Uboot": "Uboot (failed) -> generic/carver (fallback)",
    "output": "/bin/sh: 1: Syntax error: \"(\" unexpected\n",
    "filter_log": "",
    "number_of_unpacked_files": 0,
    "number_of_unpacked_directories": 0,
    "summary": [
        "packed"
    ],
    "entropy": 0.892847092329587
}

I will provide a PR which addresses this issue.