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

Do not report exception message in fault details #73034

Merged
merged 2 commits into from
Apr 16, 2024

Conversation

dibarbet
Copy link
Member

@dibarbet dibarbet commented Apr 15, 2024

@dibarbet dibarbet requested a review from a team as a code owner April 15, 2024 21:37
@dotnet-issue-labeler dotnet-issue-labeler bot added Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead labels Apr 15, 2024
// If we couldn't get a stack, do this
return exception.Message;
// If we couldn't get a stack, report a generic message.
// The exception message is already reported in a separate cred-scanned property.
Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

the fault description field is not client side cred-scanned by VS telemetry. We should not report the message again here, there is already an exception message property that is cred-scanned.

@@ -78,10 +78,9 @@ internal static bool ResetRenameTrackingStateWorker(Workspace workspace, Documen
if (textBuffer == null)
{
var ex = new InvalidOperationException(string.Format(
"document with name {0} is open but textBuffer is null. Textcontainer is of type {1}. SourceText is: {2}",
"document with name {0} is open but textBuffer is null. Textcontainer is of type {1}.",
Copy link
Member Author

@dibarbet dibarbet Apr 15, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This isn't 100% necessary to resolve the bug given we also have the change below (and assuming the message field is cred scanned), but in general we shouldn't be reporting the full source in fault telemetry.

ToddGrun
ToddGrun previously approved these changes Apr 15, 2024
Copy link
Contributor

@ToddGrun ToddGrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@ToddGrun ToddGrun dismissed their stale review April 15, 2024 23:34

revoking review

Copy link
Contributor

@ToddGrun ToddGrun left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

:shipit:

@dibarbet dibarbet merged commit 1b3be09 into dotnet:main Apr 16, 2024
24 of 27 checks passed
@dibarbet dibarbet deleted the fix_cred_scan branch April 16, 2024 21:17
@dotnet-policy-service dotnet-policy-service bot added this to the Next milestone Apr 16, 2024
@dibarbet dibarbet modified the milestones: Next, 17.11 P1 Apr 29, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Area-IDE untriaged Issues and PRs which have not yet been triaged by a lead
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants