diff --git a/scripts/evtx_dump_chunk_slack.py b/scripts/evtx_dump_chunk_slack.py index 906f9af..21bd176 100755 --- a/scripts/evtx_dump_chunk_slack.py +++ b/scripts/evtx_dump_chunk_slack.py @@ -40,7 +40,10 @@ def main(): last_allocated_offset = chunk_start for record in chunk.records(): last_allocated_offset = record.offset() + record.size() - sys.stdout.write(buf[last_allocated_offset:chunk_start + 0x10000]) + try: + sys.stdout.buffer.write(buf[last_allocated_offset:chunk_start + 0x10000]) + except: + sys.stdout.write(buf[last_allocated_offset:chunk_start + 0x10000]) if __name__ == "__main__":