From 830bad54bd135267dd89bf8d7cfb477f137ba16e Mon Sep 17 00:00:00 2001 From: Yacine Elhamer Date: Fri, 21 Jul 2023 14:41:07 +0100 Subject: [PATCH] fix bugs --- capa/features/extractors/dnfile/extractor.py | 3 +++ capa/features/extractors/dnfile_.py | 3 +++ capa/features/extractors/dotnetfile.py | 3 +++ 3 files changed, 9 insertions(+) diff --git a/capa/features/extractors/dnfile/extractor.py b/capa/features/extractors/dnfile/extractor.py index 7f7faa49b..5d34b7cf4 100644 --- a/capa/features/extractors/dnfile/extractor.py +++ b/capa/features/extractors/dnfile/extractor.py @@ -93,6 +93,9 @@ def __init__(self, path: Path): def get_base_address(self): return NO_ADDRESS + def get_sample_hashes(self) -> SampleHashes: + return self.sample_hashes + def extract_global_features(self): yield from self.global_features diff --git a/capa/features/extractors/dnfile_.py b/capa/features/extractors/dnfile_.py index 38e95b87f..d18c325de 100644 --- a/capa/features/extractors/dnfile_.py +++ b/capa/features/extractors/dnfile_.py @@ -91,6 +91,9 @@ def __init__(self, path: Path): def get_base_address(self) -> AbsoluteVirtualAddress: return AbsoluteVirtualAddress(0x0) + def get_sample_hashes(self) -> SampleHashes: + return self.sample_hashes + def get_entry_point(self) -> int: # self.pe.net.Flags.CLT_NATIVE_ENTRYPOINT # True: native EP: Token diff --git a/capa/features/extractors/dotnetfile.py b/capa/features/extractors/dotnetfile.py index 987fad5bc..70789598a 100644 --- a/capa/features/extractors/dotnetfile.py +++ b/capa/features/extractors/dotnetfile.py @@ -175,6 +175,9 @@ def __init__(self, path: Path): def get_base_address(self): return NO_ADDRESS + def get_sample_hashes(self) -> SampleHashes: + return self.sample_hashes + def get_entry_point(self) -> int: # self.pe.net.Flags.CLT_NATIVE_ENTRYPOINT # True: native EP: Token