CybercentreCanada / CCCS-Yara

YARA rule metadata specification and validation utility / Spécification et validation pour les règles YARA
MIT License
98 stars 19 forks source link

last_modified date being overwritten #50

Closed ed4wg closed 2 years ago

ed4wg commented 2 years ago

When running yara_validator_cli.py, the _lastmodified metadata attribute is being overwritten with the current date whether the value already exists in the yara rule or not. This is only happening for _lastmodified and not _firstimported.

I would think the expected behavior is to leave the _lastmodified date as-is if found in the rule metadata.

The scenario where i ran into this was when importing an external ruleset that already had last_modified dates set. I would like to keep those dates as-is for context.