Skip to content

Commit

Permalink
increase coverage
Browse files Browse the repository at this point in the history
  • Loading branch information
M4tteoP committed Jan 28, 2024
1 parent 7da392e commit 5a2e0ef
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions xss_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,8 @@ func TestIsXSS(t *testing.T) {
"<a href = javascript:alert(1); >",
"<a href=\" javascript:alert(1);\" >",
"<a href=\"JAVASCRIPT:alert(1);\" >",
// Payload sample from https://github.com/payloadbox/xss-payload-list
"<HTML xmlns:xss><?import namespace=\"xss\" implementation=\"%(htc)s\"><xss:xss>XSS</xss:xss></HTML>\"\"\",\"XML namespace.\"),(\"\"\"<XML ID=\"xss\"><I><B>&lt;IMG SRC=\"javas<!-- -->cript:javascript:alert(1)\"&gt;</B></I></XML><SPAN DATASRC=\"#xss\" DATAFLD=\"B\" DATAFORMATAS=\"HTML\"></SPAN>",
}

for _, example := range examples {
Expand Down

0 comments on commit 5a2e0ef

Please sign in to comment.