@@ -3,7 +3,6 @@ package report
3
3
import (
4
4
"context"
5
5
"fmt"
6
- "html"
7
6
"io"
8
7
"net/url"
9
8
"path/filepath"
@@ -171,8 +170,8 @@ func (sw *SarifWriter) Write(ctx context.Context, report types.Report) error {
171
170
locationMessage : fmt .Sprintf ("%v: %v@%v" , path , vuln .PkgName , vuln .InstalledVersion ),
172
171
locations : sw .getLocations (vuln .PkgName , vuln .InstalledVersion , path , res .Packages ),
173
172
resultIndex : getRuleIndex (vuln .VulnerabilityID , ruleIndexes ),
174
- shortDescription : html . EscapeString ( vuln .Title ) ,
175
- fullDescription : html . EscapeString ( fullDescription ) ,
173
+ shortDescription : vuln .Title ,
174
+ fullDescription : fullDescription ,
176
175
helpText : fmt .Sprintf ("Vulnerability %v\n Severity: %v\n Package: %v\n Fixed Version: %v\n Link: [%v](%v)\n %v" ,
177
176
vuln .VulnerabilityID , vuln .Severity , vuln .PkgName , vuln .FixedVersion , vuln .VulnerabilityID , vuln .PrimaryURL , vuln .Description ),
178
177
helpMarkdown : fmt .Sprintf ("**Vulnerability %v**\n | Severity | Package | Fixed Version | Link |\n | --- | --- | --- | --- |\n |%v|%v|%v|[%v](%v)|\n \n %v" ,
@@ -199,8 +198,8 @@ func (sw *SarifWriter) Write(ctx context.Context, report types.Report) error {
199
198
},
200
199
},
201
200
resultIndex : getRuleIndex (misconf .ID , ruleIndexes ),
202
- shortDescription : html . EscapeString ( misconf .Title ) ,
203
- fullDescription : html . EscapeString ( misconf .Description ) ,
201
+ shortDescription : misconf .Title ,
202
+ fullDescription : misconf .Description ,
204
203
helpText : fmt .Sprintf ("Misconfiguration %v\n Type: %s\n Severity: %v\n Check: %v\n Message: %v\n Link: [%v](%v)\n %s" ,
205
204
misconf .ID , misconf .Type , misconf .Severity , misconf .Title , misconf .Message , misconf .ID , misconf .PrimaryURL , misconf .Description ),
206
205
helpMarkdown : fmt .Sprintf ("**Misconfiguration %v**\n | Type | Severity | Check | Message | Link |\n | --- | --- | --- | --- | --- |\n |%v|%v|%v|%s|[%v](%v)|\n \n %v" ,
@@ -226,8 +225,8 @@ func (sw *SarifWriter) Write(ctx context.Context, report types.Report) error {
226
225
},
227
226
},
228
227
resultIndex : getRuleIndex (secret .RuleID , ruleIndexes ),
229
- shortDescription : html . EscapeString ( secret .Title ) ,
230
- fullDescription : html . EscapeString ( secret .Match ) ,
228
+ shortDescription : secret .Title ,
229
+ fullDescription : secret .Match ,
231
230
helpText : fmt .Sprintf ("Secret %v\n Severity: %v\n Match: %s" ,
232
231
secret .Title , secret .Severity , secret .Match ),
233
232
helpMarkdown : fmt .Sprintf ("**Secret %v**\n | Severity | Match |\n | --- | --- |\n |%v|%v|" ,
0 commit comments