-
Notifications
You must be signed in to change notification settings - Fork 167
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
internal-dotnet-file-limitation.yml: make it valid for static scope too #990
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
With this change, capa will print the description and force users to run capa with >= -v option for every .NET file that it analyzes statically:
This dynamic analysis trace describes a .NET file.
capa rules are not yet tuned for the .NET runtime,
so its analysis may be incomplete or misleading.
This is confusing on two fronts:
- This dynamic analysis trace describes a .NET file. could confuse users attempting to analyze a .NET file statically
- capa rules are not yet tuned for the .NET runtime isn't true for static analysis as capa has a robust set of .NET rules and we don't want to turn users away from using capa to process .NET files statically.
@williballenthin I agree with your comments in mandiant/capa#2591 (comment) that a proper fix likely requires many changes. Unfortunately, I think our best option at this time is to exclude this rule until we have time to implement these changes.
This comment was marked as duplicate.
This comment was marked as duplicate.
Thanks for calling this out. That wasn't my intention for the logic of capa and the dynamic limitations. These dynamic limitations should only be used to warn users during dynamic analysis. @v1bh475u would you reproduce this behavior on your side and open a new PR to ensure these rules aren't used to warn for samples in the wrong analysis mode. @mike-hunhoff agree that in the short term we can remove the dynamic .NET rule |
@mike-hunhoff are you sure about this? when i run locally in static mode, there's not a warning about .NET files: |
Ah, I guess you're correct that the limitation isn't highlighted because of these checks: https://github.com/mandiant/capa/blob/5467fac1a57c094b6dd466e1c361bcb7f12dd340/capa/main.py#L1001-L1005. However, the rule is matched and displayed in my local instance, which isn't great but not show stopping:
|
Sure. Will start working on it! |
The issue is there are rigid matches for static file limitations, but for dynamic dotnet limitations, I couldn't find any firm constraints. Do you have any suggestions? @mike-hunhoff @williballenthin |
This is fixed in the pending #2592, where we now hide any internal rule from the default output (but will show it during vverbose, which isn't great but probably fine enough). @v1bh475u we cleared up the confusion and i don't think is any action needed by you right now, sorry! |
ref mandiant/capa#2591