-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
Regression in Include directive #796
Comments
@trufae can you provide more details about how to reproduce the issue? I did some quick tests both in Mac OS X and Windows and relative path includes are working fine for me in version 3.7.0. There's even a test case for includes that consists in a relative include. So, maybe you hit some particular bug. |
here's a test case. type make and compare behaviour between 3.6.3 and 3.7.0 |
Perfect, now I see the problem. It happens when the path in some include directive is not relative to the current path. I'll commit a fix as soon as possible. |
awesome, thanks! |
If you use Fix # the issue is closed automatically |
The yara include directive got broken in c0fa0bf but this commit doesnt builds , so it wasnt visible until d4283df (the next commit).
The problem is that now, yara doesnt handles relative path includes because the callback logic doesnt covers the stack level, so it expects all includes to be happening from the root directory which is incorrect.
Reverting this commit is not possible because there are so many conflicts and the test introduced in this change to show its working is pretty limited as long as it just does 1 include, but doesnt expects this include to contain other includes in relative paths.
There are 121 commits after that and 3.7 has been released, so the 3.7 release is broken, the last working one was 3.6.3. I think this change must be properly tested because the current behaviour is not the one i would expect and changes the way it was working before.
Hopefully this should be included in a 3.7.x bug-fix release or in 3.8
The text was updated successfully, but these errors were encountered: