-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Fio 7544 html sanitization issue (#5559)
* FIO-7544: Fixes an issue where scripts inside HTML component will be executed during interpolation * Refactoring * Added test for interpolation in HTML component
- Loading branch information
1 parent
5649728
commit 0ffd33b
Showing
4 changed files
with
77 additions
and
8 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,38 @@ | ||
export default { | ||
type: 'form', | ||
display: 'form', | ||
components: [ | ||
{ | ||
label: 'Text Field', | ||
applyMaskOn: 'change', | ||
tableView: true, | ||
key: 'textField', | ||
type: 'textfield', | ||
input: true, | ||
}, | ||
{ | ||
label: 'HTML', | ||
attrs: [ | ||
{ | ||
attr: '', | ||
value: '', | ||
}, | ||
], | ||
content: '<img src=1 onerror=alert("htmlContent")>\n<div class="myClass {{data.textField + \'-class\'}}">{{' + | ||
' data.textField ? data.textField : \'No Text\'}}</div>', | ||
refreshOnChange: true, | ||
key: 'html', | ||
type: 'htmlelement', | ||
input: false, | ||
tableView: false, | ||
}, | ||
{ | ||
type: 'button', | ||
label: 'Submit', | ||
key: 'submit', | ||
disableOnInvalid: true, | ||
input: true, | ||
tableView: false, | ||
}, | ||
], | ||
}; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,3 +1,4 @@ | ||
import comp1 from './comp1'; | ||
import comp2 from './comp2'; | ||
export { comp1, comp2 }; | ||
import comp3 from './comp3'; | ||
export { comp1, comp2, comp3 }; |