Affected versions
All before 10.0.1
User Story
Some ZK components handle XSS issues by encoding user input, but not cover all component attributes.
Acceptance Criteria
Encoding by default, and use white list.
Details
Workaround
<script> /** * Purpose: Workaround Prevent XSS exploit on attributes * For version: 8.X to 10.X * Last update: 10.0.0 */ zk.afterLoad('zk', function() { var xWidget = {}; zk.override(zk.Widget.prototype, xWidget, { domTooltiptext_ : function() { var result = xWidget.domTooltiptext_.apply(this, arguments); return zUtl.encodeXMLAttribute(result); }, domClass_ : function() { var result = xWidget.domClass_.apply(this, arguments); return zUtl.encodeXMLAttribute(result); } });//zk.override });//zk.afterLoad </script>
- relates to
-
ZK-5161 page directive's attributes are not encoded before rendering into HTML
- Closed
-
ZK-5162 emptyMessage is not escaped with HTML characters
- Closed
-
ZK-5260 chosenbox options don't escape HTML characters
- Closed
-
ZK-5722 DomPurify doesn't neutralize double quotes in attribute string, can be used for XSS attacks
- Closed