abrignoni / abrignoni/iLEAPP

Reading discordmanifest artifact had errors! - 'charmap' codec can't decode byte 0x9d in position 1331: character maps to <undefined>

Offen
#1,093 0 Kommentare 0 Reaktionen 0 zugewiesene Personen Auf GitHub ansehen
Vorherrschende Sprache
Python
Sterne
1.2k
Forks
303
Ø Merge
4 Std. 32 Min.
Gemergte PRs (30 T.)
216

Beschreibung

Hi,

I was trying to parse an iTunes backup on Windows, and the discordManifest.py module crashes with this error:

```
Reading discordmanifest artifact had errors!
Error was 'charmap' codec can't decode byte 0x9d in position 1331: character maps to
Exception Traceback: Traceback (most recent call last):
File "C:\Users\DFIR\Downloads\iLEAPP\ileapp.py", line 426, in crunch_artifacts
artifact_data = plugin.method(files_found, category_folder, seeker, wrap_text, time_offset)
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
File "C:\Users\DFIR\Downloads\iLEAPP\scripts\artifacts\discordManifest.py", line 19, in get_discordManifest
for jsondata in f_in:
^^^^
File "C:\Users\DFIR\AppData\Local\Programs\Python\Python312\Lib\encodings\cp1252.py", line 23, in decode
return codecs.charmap_decode(input,self.errors,decoding_table)[0]
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
UnicodeDecodeError: 'charmap' codec can't decode byte 0x9d in position 1331: character maps to
```

It seems like it is related with the `open` function missing an encoding parameter.

I added `encoding="utf8"` in it, and it is working.

But, I think that the definition of the artifact it too generic, because it is extracting not only Discord, but also other apps that have this path:
`*/mobile/Containers/Data/Application/*/Documents/RCTAsyncLocalStorage_V1/manifest.json`.

Hope it helps!

Thanks!

Beitragsleitfaden

Für dieses Repository ist kein Beitragsleitfaden indexiert

Bewertung

Dieses Issue wurde noch nicht bewertet.

Neue Issues direkt in Ihr Postfach

Eine kurze Übersicht über anfängerfreundliche GitHub-Issues.