Skip to content

Commit 4b658d3

Browse files
committed
src/goVulncheck: add feedback link
https://go.dev/s/vsc-vulncheck-feedback Also, copy the phrase for the unaffecting vulnerabilities section from govulncheck. Change-Id: I5f5eac80f459227adea3e687db762beb97857fa4 Reviewed-on: https://go-review.googlesource.com/c/vscode-go/+/429235 Run-TryBot: Hyang-Ah Hana Kim <[email protected]> Reviewed-by: Jamal Carvalho <[email protected]> TryBot-Result: kokoro <[email protected]>
1 parent 4b6ce1f commit 4b658d3

File tree

2 files changed

+6
-2
lines changed

2 files changed

+6
-2
lines changed

media/vulncheckView.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -156,7 +156,7 @@
156156

157157
unaffectingContainer.innerText = '';
158158
if (unaffecting.length > 0) {
159-
unaffectingContainer.innerHTML = '<hr></hr><p>These vulnerabilities exist in required modules, but no vulnerable symbols are used.<br>No action is required. For more information, visit <a href="https://pkg.go.dev/vuln">https://pkg.go.dev/vuln</a></p>';
159+
unaffectingContainer.innerHTML = '<hr></hr><p>The vulnerabilities below are in packages that you import, but your code does not appear to call any vulnerable functions. You may not need to take any action. See <a href="https://pkg.go.dev/golang.org/x/vuln/cmd/govulncheck">https://pkg.go.dev/golang.org/x/vuln/cmd/govulncheck</a> for details.';
160160

161161
const details = document.createElement('table');
162162
unaffecting.forEach((vuln) => {

src/goVulncheck.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -102,6 +102,9 @@ export class VulncheckResultViewProvider implements vscode.CustomTextEditorProvi
102102
<title>Vulnerability Report - govulncheck</title>
103103
</head>
104104
<body>
105+
Vulncheck is an experimental tool.<br>
106+
Share feedback at <a href="https://go.dev/s/vsc-vulncheck-feedback">go.dev/s/vsc-vulncheck-feedback</a>.
107+
105108
<div class="log"></div>
106109
<div class="vulns"></div>
107110
<div class="unaffecting"></div>
@@ -242,6 +245,7 @@ export class VulncheckProvider {
242245
}
243246

244247
this.channel.clear();
248+
this.channel.show();
245249
this.channel.appendLine(`cd ${dir}; gopls vulncheck ${pattern}`);
246250

247251
try {
@@ -352,7 +356,7 @@ export async function vulncheck(
352356
reject('analysis cancelled');
353357
} else {
354358
channel.appendLine(buf);
355-
reject(`result in unexpected format: ${e}`);
359+
reject('vulncheck failed: see govulncheck OUTPUT');
356360
}
357361
}
358362
});

0 commit comments

Comments
 (0)