mirror of
https://github.com/gchq/CyberChef.git
synced 2025-05-11 16:51:31 -04:00
Merge branch 'master' into feature-async-ops
This commit is contained in:
commit
cb642c156b
18 changed files with 1766 additions and 11 deletions
|
@ -109,6 +109,10 @@
|
|||
"OutputWaiter": false,
|
||||
"RecipeWaiter": false,
|
||||
"SeasonalWaiter": false,
|
||||
"WindowWaiter": false
|
||||
"WindowWaiter": false,
|
||||
|
||||
/* tests */
|
||||
"TestRegister": false,
|
||||
"TestRunner": false
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -139,7 +139,7 @@ Dish.prototype.translate = function(toType) {
|
|||
this.type = Dish.BYTE_ARRAY;
|
||||
break;
|
||||
case Dish.HTML:
|
||||
this.value = this.value ? Utils.strToByteArray(Utils.stripHtmlTags(this.value, true)) : [];
|
||||
this.value = this.value ? Utils.strToByteArray(Utils.unescapeHtml(Utils.stripHtmlTags(this.value, true))) : [];
|
||||
this.type = Dish.BYTE_ARRAY;
|
||||
break;
|
||||
default:
|
||||
|
|
|
@ -152,7 +152,6 @@ var FlowControl = {
|
|||
maxJumps = ings[1];
|
||||
|
||||
if (state.numJumps >= maxJumps) {
|
||||
state.progress++;
|
||||
return state;
|
||||
}
|
||||
|
||||
|
@ -180,7 +179,6 @@ var FlowControl = {
|
|||
maxJumps = ings[2];
|
||||
|
||||
if (state.numJumps >= maxJumps) {
|
||||
state.progress++;
|
||||
return state;
|
||||
}
|
||||
|
||||
|
|
|
@ -928,6 +928,33 @@ var Utils = {
|
|||
},
|
||||
|
||||
|
||||
/**
|
||||
* Unescapes HTML tags in a string to make them render again.
|
||||
*
|
||||
* @param {string} str
|
||||
* @returns string
|
||||
*
|
||||
* @example
|
||||
* // return "A <script> tag"
|
||||
* Utils.unescapeHtml("A <script> tag");
|
||||
*/
|
||||
unescapeHtml: function(str) {
|
||||
var HTML_CHARS = {
|
||||
"&": "&",
|
||||
"<": "<",
|
||||
">": ">",
|
||||
""": '"',
|
||||
"'": "'",
|
||||
"/": "/",
|
||||
"`": "`"
|
||||
};
|
||||
|
||||
return str.replace(/&#?x?[a-z0-9]{2,4};/ig, function (match) {
|
||||
return HTML_CHARS[match] || match;
|
||||
});
|
||||
},
|
||||
|
||||
|
||||
/**
|
||||
* Expresses a number of milliseconds in a human readable format.
|
||||
*
|
||||
|
|
1159
src/js/lib/es6-promise.auto.js
Normal file
1159
src/js/lib/es6-promise.auto.js
Normal file
File diff suppressed because it is too large
Load diff
Loading…
Add table
Add a link
Reference in a new issue