unblob
unblob copied to clipboard
Exception in AR handler invalid literal for int()
Running unblob on https://static.tp-link.com/upload/firmware/2021/202107/20210729/ER7206(UN)_v1_1.1.1%20Build%2020210723.zip produces the following error in the ar extractor:
2024-02-14 01:02.45 [error ] Unhandled Exception during chunk calculation handler=ar pid=21 severity=<Severity.ERROR: 'ERROR'> start_offset=0x0
Traceback (most recent call last):
File "/unblob/unblob/finder.py", line 35, in _calculate_chunk
return handler.calculate_chunk(file, real_offset)
File "/unblob/unblob/handlers/archive/ar.py", line 37, in calculate_chunk
ar.read_all_headers()
File "/usr/local/lib/python3.10/dist-packages/arpy.py", line 403, in read_all_headers
while self.read_next_header() is not None:
File "/usr/local/lib/python3.10/dist-packages/arpy.py", line 378, in read_next_header
header = self.__read_file_header(self.next_header_offset)
File "/usr/local/lib/python3.10/dist-packages/arpy.py", line 299, in __read_file_header
add_len = self.__fix_name(file_header)
File "/usr/local/lib/python3.10/dist-packages/arpy.py", line 350, in __fix_name
gnu_position = int(header.proxy_name[1:])
ValueError: invalid literal for int() with base 10: b'SYM64'
Upstream patch sent at https://github.com/viraptor/arpy/pull/21
PR in arpy has been opened for 9 months without any signs of progress. I'll fork it and make unblob use it.
We're thinking about implementing our own AR extractor using modern python and stronger implementation than unar or arpy right now.