-
Notifications
You must be signed in to change notification settings - Fork 1.5k
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
Enable mechanism for some control over correlation #2577
Conversation
if ($MetadataCollection) | ||
{ | ||
$wingetUtilPath = Join-Path $PSScriptRoot "WinGetUtil.dll" | ||
$installAndCorrelationExpression = -join($installAndCorrelationExpression, ' -meta "', $wingetUtilPath, '" -sys32 "', $System32Path,'"') |
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.
// Number of changed ARP entries that match the installed package | ||
size_t CountOfIntersectionOfChangesAndMatches{}; | ||
|
||
ARPCorrelationResult& operator=(ARPHeuristicsCorrelationResult&& other) |
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.
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.
Honestly, I was surprised it didn't work out of the box. The goal is to be able to assign just the base portion of the object, which seems very intuitive to me.
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.
Change
The primary change is to enable some control over the correlation functionality so that different situations can behave differently. Specifically, the utility functionality of metadata collection, which is intended to be run in a "clean room" environment, can assume that a single change to ARP represents the target entry.
In addition, this change enables diagnostic information to be output by the metadata collection. This includes the reason that an entry was chosen, and the confidence value for various possible entries if the heuristic matching is attempted.
Finally, the correlation testbed is enhanced to run the metadata collection, allowing it to be tested alongside the inline correlation. The scripts have various improvements, such as a
-Wait
to leave the sandbox active and forcing the CSV to be output with a UTF8-BOM (Excel requires the BOM in order to open the CSV as UTF8).Microsoft Reviewers: Open in CodeFlow