Skip to content

Commit

Permalink
Merge pull request #80 from CybercentreCanada/yara_compat/strings
Browse files Browse the repository at this point in the history
Respect cases where an extractor might pin an older version of yara-python
  • Loading branch information
cccs-rs authored Feb 5, 2025
2 parents fdd29bf + 0582bcf commit 0664264
Showing 1 changed file with 4 additions and 2 deletions.
6 changes: 4 additions & 2 deletions maco/utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -70,9 +70,11 @@ def object_hook(self, obj):
import logging
try:
from maco import yara
except:
# Respect cases where the extractor is tied to certain version of yara-python for processing
import yara
except:
# Otherwise fallback to MACO's interface for yara-python==4.5.x
from maco import yara
from base64 import b64encode
Expand Down

0 comments on commit 0664264

Please sign in to comment.