Skip to content

Commit 67a16eb

Browse files
committed
Bug #14752
Fix bug by using the more adequant OWASP Encode method.
1 parent 8c43bd5 commit 67a16eb

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

core-web/src/main/java/org/silverpeas/core/web/attachment/tag/SimpleDocumentContextualMenu.java

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -215,7 +215,7 @@ private void buildDocumentStateActions(SimpleDocument attachment, LocalizationBu
215215
"switchState('" + attachment.getId() + "', " + attachment.isVersioned() + ", " +
216216
isLastPublicVersion + ");", message);
217217
prepareMenuItem(builder, "deleteAttachment('" + attachment.getId() + "','" +
218-
Encode.forHtml(attachment.getFilename()) + "');", resources.getString("GML.delete"));
218+
Encode.forJavaScriptAttribute(attachment.getFilename()) + "');", resources.getString("GML.delete"));
219219
message = resources.getString("attachment.download.allowReaders");
220220
boolean isDownloadAllowedForReaders = attachment.isDownloadAllowedForReaders();
221221
if (isDownloadAllowedForReaders) {

0 commit comments

Comments
 (0)