Browse Source

Disable <video> and <audio> HTML tag

pull/6/head
Menci 8 years ago
parent
commit
414c87bf7e
  1. 2
      utility.js

2
utility.js

@ -83,6 +83,8 @@ module.exports = {
let XSS = require('xss'); let XSS = require('xss');
let CSSFilter = require('cssfilter'); let CSSFilter = require('cssfilter');
let whiteList = Object.assign({}, require('xss/lib/default').whiteList); let whiteList = Object.assign({}, require('xss/lib/default').whiteList);
delete whiteList.audio;
delete whiteList.video;
for (let tag in whiteList) whiteList[tag] = whiteList[tag].concat(['id', 'style', 'class']); for (let tag in whiteList) whiteList[tag] = whiteList[tag].concat(['id', 'style', 'class']);
let xss = new XSS.FilterXSS({ let xss = new XSS.FilterXSS({
css: { css: {

Loading…
Cancel
Save