v0.2.6
This commit is contained in:
4
dist/xss.js
vendored
4
dist/xss.js
vendored
@@ -474,8 +474,8 @@ function getTagName (html) {
|
||||
var tagName = html.slice(1, i + 1);
|
||||
}
|
||||
tagName = _.trim(tagName).toLowerCase();
|
||||
if (tagName[0] === '/') tagName = tagName.slice(1);
|
||||
if (tagName[tagName.length - 1] === '/') tagName = tagName.slice(0, -1);
|
||||
if (tagName.slice(0, 1) === '/') tagName = tagName.slice(1);
|
||||
if (tagName.slice(-1) === '/') tagName = tagName.slice(0, -1);
|
||||
return tagName;
|
||||
}
|
||||
|
||||
|
||||
2
dist/xss.min.js
vendored
2
dist/xss.min.js
vendored
File diff suppressed because one or more lines are too long
@@ -1,7 +1,7 @@
|
||||
{
|
||||
"name": "xss",
|
||||
"main": "./lib/index.js",
|
||||
"version": "0.2.5",
|
||||
"version": "0.2.6",
|
||||
"description": "Sanitize untrusted HTML (to prevent XSS) with a configuration specified by a Whitelist. 根据白名单过滤HTML(防止XSS攻击)",
|
||||
"author": "leizongmin <leizongmin@gmail.com> (http://ucdok.com)",
|
||||
"contributors": [
|
||||
|
||||
Reference in New Issue
Block a user