Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pe.version_info when RT_VERSION doesn't exist #1931

Closed
djlukic opened this issue Jul 10, 2023 · 2 comments
Closed

pe.version_info when RT_VERSION doesn't exist #1931

djlukic opened this issue Jul 10, 2023 · 2 comments

Comments

@djlukic
Copy link

djlukic commented Jul 10, 2023

Hi,

I am having a weird situation where I am trying to match a sample where in condition I specified
and not pe.version_info["FileDescription"] == "Test"
and I also tried with
pe.version_info["FileDescription"] != "Test"
but it doesn't hit because RT_VERSION resource doesn't exist.
Is this intended that and not or != won't have a match when RT_VERSION doesn't exist?

Thanks!

@cherepanov74
Copy link
Contributor

version_info can be YR_UNDEFINED,
Try to use something like this:
and (not defined pe.version_info["FileDescription"] or not (pe.version_info["FileDescription"] matches /Test/) )

@djlukic
Copy link
Author

djlukic commented Jul 31, 2023

Thank you!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants