Merge pull request #16610 from nextcloud/backport/16599/stable16

[stable16] Fix/xss/on favorite file
This commit is contained in:
Roeland Jago Douma 2019-07-30 16:30:19 +02:00 committed by GitHub
commit 07d32779db
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23
2 changed files with 2 additions and 2 deletions

View File

@ -103,7 +103,7 @@
var innerTagA = document.createElement('A');
innerTagA.setAttribute("href", url);
innerTagA.setAttribute("class", "nav-icon-files svg");
innerTagA.innerHTML = appName;
innerTagA.innerHTML = _.escape(appName);
var length = listLIElements.length + 1;
var innerTagLI = document.createElement('li');

View File

@ -1100,7 +1100,7 @@ var jsc = {
if (jsc.isElementType(this.valueElement, 'input')) {
this.valueElement.value = value;
} else {
this.valueElement.innerHTML = value;
this.valueElement.innerHTML = _.escape(value);
}
}
if (!(flags & jsc.leaveStyle)) {