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

vverbose output duplicates some lines, sometimes #2323

Closed
williballenthin opened this issue Aug 22, 2024 · 4 comments · Fixed by #2324
Closed

vverbose output duplicates some lines, sometimes #2323

williballenthin opened this issue Aug 22, 2024 · 4 comments · Fixed by #2324
Assignees
Labels
bug Something isn't working

Comments

@williballenthin
Copy link
Collaborator

it seems that the vverbose output mode duplicates some lines, sometimes. see this screenshot when running against PMA 01-01:

Screenshot 2024-08-22 11 09 15 AM

@williballenthin williballenthin added the bug Something isn't working label Aug 22, 2024
@williballenthin
Copy link
Collaborator Author

the result document has multiple entries:
image

so its not that vverbose is wrong, the result document has duplicates.

@williballenthin
Copy link
Collaborator Author

this comes from the rule:
image

and the fact that we trim the DLL name from API features:

image

so we end up with logic that looks like:

- or:
  - api: recv
  - api: recv

which is correctly matched and rendered.

to fix, we should deduplicate these features that the rule wants to match.

@williballenthin
Copy link
Collaborator Author

the trimming was introduced here: c9df782
#1824 and #1815

@fariss
Copy link
Collaborator

fariss commented Aug 22, 2024

Yeah, I noticed this as well while working on explorer:

Example: the first 2 socket api statements in "create TCP socket": https://mandiant.github.io/capa/explorer/#/?rdoc=https://raw.githubusercontent.com/mandiant/capa-testfiles/master/rd/0000a65749f5902c4d82ffa701198038f0b4870b00a27cfca109f8f933476d82.json.gz

image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants