In-depth lesson · XSS
Typical fixes
Every point the XSS reports back under this heading, best-backed first, each with the reports it is seen in.
-
Encode or validate the User-Agent before inserting it into email HTML.
-
Encode or validate the User-Agent header before reflecting it into an HTML response.
Seen in 1 report
-
Encode or validate URL parameters before passing them to document.write.
Seen in 1 report
-
Encode query parameters reflected into HTML input attributes.
-
Encode query results before rendering them as HTML.
Seen in 1 report
-
Encode review fields before rendering them in the admin portal.
Seen in 1 report
-
Encode search input before reflecting it.
Seen in 1 report
-
Encode sender name and company values before printing them into HTML.
Seen in 1 report
-
Encode stored channel names and descriptions when building select boxes.
Seen in 1 report
-
Encode stored messages when rendering them.
Seen in 1 report
-
Encode the account name before embedding it in the email body.
Seen in 1 report
-
Encode the entity_type parameter before embedding it in the page.
Seen in 1 report
-
Encode the error message parameter before echoing it.
Seen in 1 report
-
Encode the jump parameter before echoing it into a script block.
Seen in 1 report
-
Encode the language parameter before output on login pages.
Seen in 1 report
-
Encode the m parameter and mark the session cookie SameSite.
Seen in 1 report
-
Encode the mapname parameter before placing it in a form action attribute.
Seen in 1 report
-
Encode the name field before inserting it into an attribute.
Seen in 1 report
-
Medium
-
-
Encode the name value before inserting it into confirmation email HTML.
Seen in 1 report
-
Encode the parameter before inserting it into an HTML attribute and block dangerous attributes rather than only tags.
Seen in 1 report
-
Encode the placeholder value instead of concatenating it into an HTML string.
Seen in 1 report
-
Encode the query_string parameter before rendering it.
Seen in 1 report
-
Encode the search parameter before reflecting it.
Seen in 1 report
-
Encode the userPage parameter before displaying it.
-
Encode unknown attribute names reflected into HTML error responses.
Seen in 1 report
-
Encode uploaded file names before rendering them.
Seen in 1 report
-
Encode URL content reflected on 404 pages and escape it when inserted into attributes.
Seen in 1 report
-
Encode URL values before inserting them into hidden input fields.
Seen in 1 report
-
Encode user input inserted into inline event handlers and broaden WAF rules.
Seen in 1 report
-
Encode user text consistently across all languages.
Seen in 1 report
-
Encode user-controlled parameters reflected into HTML or JavaScript.
Seen in 1 report
-
Encode user-controlled URL input before inserting it into a JavaScript context.
Seen in 1 report
-
Encode user-supplied names before embedding them in verification email HTML.
-
Enforce a safe content type and encode angle brackets in uploaded files.
Seen in 1 report
-
Enforce authentication checks on admin panel URLs instead of relying on hidden paths.
-
Enforce origin isolation on webviews and validate the origin of postMessage senders.
Seen in 1 report
-
$5,000
-
-
Entity-encode the custom element is value when serialising.
Seen in 1 report
-
Escape after normalising characters so normalised less-than signs are not rendered as markup.
Seen in 1 report
-
$1,000 High
-
-
Escape all metadata and output fields when generating HTML.
-
Escape and validate image attribute values in the renderer.
Seen in 1 report
-
Escape angle brackets when serialising CSS strings in the clipboard sanitiser.
Seen in 1 report
-
Escape CSV file names for a JavaScript context.
Seen in 1 report
-
Escape directory names before output.
Seen in 1 report
-
$500 Medium
-
-
Escape dots in origin allowlist regular expressions.
-
Escape double quotes when interpolating into an HTML attribute and run the sanitiser after building the HTML.
Seen in 1 report
-
Escape double quotes when reflecting input into an href.
Seen in 1 report
-
Escape double quotes when reflecting the URL path into HTML attributes.
Seen in 1 report
-
Escape EXIF metadata values before rendering.
Seen in 1 report
-
Escape GET parameters before reflecting them into the page.
Seen in 1 report
-
Escape group names and full names before rendering.
Seen in 1 report