mirror of
https://github.com/wekan/wekan.git
synced 2026-02-08 17:34:19 +01:00
Security Fix JVN#86586539: Stored XSS.
Thanks to Ryoya Koyama of Mitsui Bussan Secure Directions, Inc and xet7.
This commit is contained in:
parent
a0b94065c5
commit
ee79cab7b2
9 changed files with 248 additions and 75 deletions
|
|
@ -1,6 +1,7 @@
|
|||
import { ReactiveCache } from '/imports/reactiveCache';
|
||||
import escapeForRegex from 'escape-string-regexp';
|
||||
import DOMPurify from 'dompurify';
|
||||
import { sanitizeText } from '/client/lib/secureDOMPurify';
|
||||
|
||||
CardComments = new Mongo.Collection('card_comments');
|
||||
|
||||
|
|
@ -103,7 +104,7 @@ CardComments.helpers({
|
|||
},
|
||||
|
||||
toggleReaction(reactionCodepoint) {
|
||||
if (reactionCodepoint !== DOMPurify.sanitize(reactionCodepoint)) {
|
||||
if (reactionCodepoint !== sanitizeText(reactionCodepoint)) {
|
||||
return false;
|
||||
} else {
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue