mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-23 08:16:17 -04:00
Magic operation now shows matching ops even if they are not run.
This commit is contained in:
parent
6624f25a64
commit
23bdfd04a2
2 changed files with 18 additions and 14 deletions
|
@ -174,6 +174,9 @@ class Magic {
|
|||
async speculativeExecution(depth = 0, recipeConfig = []) {
|
||||
if (depth < 0) return [];
|
||||
|
||||
// Find any operations that can be run on this data
|
||||
const matchingOps = this.findMatchingOps();
|
||||
|
||||
let results = [];
|
||||
|
||||
// Record the properties of the current data
|
||||
|
@ -182,12 +185,10 @@ class Magic {
|
|||
data: this.inputStr.slice(0, 100),
|
||||
languageScores: this.detectLanguage(),
|
||||
fileType: this.detectFileType(),
|
||||
isUTF8: this.isUTF8()
|
||||
isUTF8: this.isUTF8(),
|
||||
matchingOps: matchingOps
|
||||
});
|
||||
|
||||
// Find any operations that can be run on this data
|
||||
const matchingOps = this.findMatchingOps();
|
||||
|
||||
// Execute each of those operations, then recursively call the speculativeExecution() method
|
||||
// on the resulting data, recording the properties of each option.
|
||||
await Promise.all(matchingOps.map(async op => {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue