mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-20 14:56:19 -04:00
Code quality improvements
This commit is contained in:
parent
60b5fe0e76
commit
9cc177a9ad
3 changed files with 3 additions and 3 deletions
|
@ -2,7 +2,6 @@
|
||||||
|
|
||||||
[](https://github.com/gchq/CyberChef/actions?query=workflow%3A%22Master+Build%2C+Test+%26+Deploy%22)
|
[](https://github.com/gchq/CyberChef/actions?query=workflow%3A%22Master+Build%2C+Test+%26+Deploy%22)
|
||||||
[](https://lgtm.com/projects/g/gchq/CyberChef/context:javascript)
|
[](https://lgtm.com/projects/g/gchq/CyberChef/context:javascript)
|
||||||
[](https://david-dm.org/gchq/CyberChef)
|
|
||||||
[](https://www.npmjs.com/package/cyberchef)
|
[](https://www.npmjs.com/package/cyberchef)
|
||||||
[](https://github.com/gchq/CyberChef/blob/master/LICENSE)
|
[](https://github.com/gchq/CyberChef/blob/master/LICENSE)
|
||||||
[](https://gitter.im/gchq/CyberChef?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
|
[](https://gitter.im/gchq/CyberChef?utm_source=badge&utm_medium=badge&utm_campaign=pr-badge)
|
||||||
|
|
|
@ -723,7 +723,8 @@ class Utils {
|
||||||
}
|
}
|
||||||
|
|
||||||
if (removeScriptAndStyle) {
|
if (removeScriptAndStyle) {
|
||||||
htmlStr = recursiveRemove(/<(script|style)[^>]*>.*?<\/(script|style)>/gi, htmlStr);
|
htmlStr = recursiveRemove(/<script[^>]*>.*?<\/script>/gi, htmlStr);
|
||||||
|
htmlStr = recursiveRemove(/<style[^>]*>.*?<\/style>/gi, htmlStr);
|
||||||
}
|
}
|
||||||
return htmlStr.replace(/<[^>]+>/g, "");
|
return htmlStr.replace(/<[^>]+>/g, "");
|
||||||
}
|
}
|
||||||
|
|
|
@ -67,7 +67,7 @@ class DeriveEVPKey extends Operation {
|
||||||
iterations = args[2],
|
iterations = args[2],
|
||||||
hasher = args[3],
|
hasher = args[3],
|
||||||
salt = Utils.convertToByteString(args[4].string, args[4].option),
|
salt = Utils.convertToByteString(args[4].string, args[4].option),
|
||||||
key = CryptoJS.EvpKDF(passphrase, salt, {
|
key = CryptoJS.EvpKDF(passphrase, salt, { // lgtm [js/insufficient-password-hash]
|
||||||
keySize: keySize,
|
keySize: keySize,
|
||||||
hasher: CryptoJS.algo[hasher],
|
hasher: CryptoJS.algo[hasher],
|
||||||
iterations: iterations,
|
iterations: iterations,
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue