@bchr/bchr-front-lib 0.3.110 → 0.3.111
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -364,10 +364,7 @@ var HttpService = /*#__PURE__*/function () {
|
|
|
364
364
|
var containsHTML = /<(br|basefont|hr|input|source|frame|param|area|meta|!--|col|link|option|base|img|wbr|!DOCTYPE).*?>|<(a|abbr|acronym|address|applet|article|aside|audio|b|bdi|bdo|big|blockquote|body|button|canvas|caption|center|cite|code|colgroup|command|datalist|dd|del|details|dfn|dialog|dir|div|dl|dt|em|embed|fieldset|figcaption|figure|font|footer|form|frameset|head|header|hgroup|h1|h2|h3|h4|h5|h6|html|i|iframe|ins|kbd|keygen|label|legend|li|map|mark|menu|meter|nav|noframes|noscript|object|ol|optgroup|output|p|pre|progress|q|rp|rt|ruby|s|samp|script|section|select|small|span|strike|strong|style|sub|summary|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|track|tt|u|ul|var|video).*?<\/\2>/i.test(str);
|
|
365
365
|
|
|
366
366
|
if (containsHTML) {
|
|
367
|
-
|
|
368
|
-
p["catch"](function () {
|
|
369
|
-
throw new Error("不安全的输入,请检查!");
|
|
370
|
-
});
|
|
367
|
+
throw new Error("不安全的输入,请检查!");
|
|
371
368
|
}
|
|
372
369
|
}
|
|
373
370
|
}, {
|
package/package.json
CHANGED
|
@@ -341,11 +341,7 @@ class HttpService {
|
|
|
341
341
|
|
|
342
342
|
let containsHTML = /<(br|basefont|hr|input|source|frame|param|area|meta|!--|col|link|option|base|img|wbr|!DOCTYPE).*?>|<(a|abbr|acronym|address|applet|article|aside|audio|b|bdi|bdo|big|blockquote|body|button|canvas|caption|center|cite|code|colgroup|command|datalist|dd|del|details|dfn|dialog|dir|div|dl|dt|em|embed|fieldset|figcaption|figure|font|footer|form|frameset|head|header|hgroup|h1|h2|h3|h4|h5|h6|html|i|iframe|ins|kbd|keygen|label|legend|li|map|mark|menu|meter|nav|noframes|noscript|object|ol|optgroup|output|p|pre|progress|q|rp|rt|ruby|s|samp|script|section|select|small|span|strike|strong|style|sub|summary|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|track|tt|u|ul|var|video).*?<\/\2>/i.test(str);
|
|
343
343
|
if (containsHTML) {
|
|
344
|
-
|
|
345
|
-
|
|
346
|
-
p.catch(function() {
|
|
347
|
-
throw new Error("不安全的输入,请检查!");
|
|
348
|
-
});
|
|
344
|
+
throw new Error("不安全的输入,请检查!");
|
|
349
345
|
}
|
|
350
346
|
}
|
|
351
347
|
|