From fa7d58d01aa6c3b6cf06175c2fabb7b036451b86 Mon Sep 17 00:00:00 2001 From: Ana Maria Martinez Gomez Date: Thu, 25 Feb 2021 10:50:25 +0100 Subject: [PATCH] Add missing va parameter to SegmentationViolation The `envi.SegmentationViolation()` was missing the `va` required parameter. This has started failing now, because calling `vw.getSegment(0x4BA190)` for the `tests/data/mimikatz.exe_` produces different results in Python 2 and Python 3. It returns `None` in Python 3 while the output in Python 2 is: `(4939776, 16840, '.data', 'mimikatz')` I have reported the issue to vivisect: https://github.com/vivisect/vivisect/issues/370 --- capa/features/extractors/viv/insn.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/capa/features/extractors/viv/insn.py b/capa/features/extractors/viv/insn.py index e741afa3..8ef505cf 100644 --- a/capa/features/extractors/viv/insn.py +++ b/capa/features/extractors/viv/insn.py @@ -239,7 +239,7 @@ def read_bytes(vw, va): """ segm = vw.getSegment(va) if not segm: - raise envi.SegmentationViolation() + raise envi.SegmentationViolation(va) segm_end = segm[0] + segm[1] try: