mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-26 09:46:17 -04:00
Merge 0a94c4a7c9
into 7c8be12d52
This commit is contained in:
commit
53d92eb7eb
3 changed files with 13 additions and 2 deletions
|
@ -72,7 +72,7 @@ class RailFenceCipherDecode extends Operation {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
return plaintext.join("").trim();
|
return plaintext.join("");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -66,7 +66,7 @@ class RailFenceCipherEncode extends Operation {
|
||||||
rows[rowIdx] += plaintext[pos];
|
rows[rowIdx] += plaintext[pos];
|
||||||
}
|
}
|
||||||
|
|
||||||
return rows.join("").trim();
|
return rows.join("");
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -528,4 +528,15 @@ TestRegister.addTests([
|
||||||
}
|
}
|
||||||
],
|
],
|
||||||
},
|
},
|
||||||
|
{
|
||||||
|
name: "Rail Fence Cipher Encode: Normal with Offset with Spaces",
|
||||||
|
input: "No one expects the spanish Inquisition.",
|
||||||
|
expectedOutput: " e n ut.ooeepcstesaihIqiiinNnxthpsnso",
|
||||||
|
recipeConfig: [
|
||||||
|
{
|
||||||
|
"op": "Rail Fence Cipher Encode",
|
||||||
|
"args": [3, 2]
|
||||||
|
}
|
||||||
|
],
|
||||||
|
},
|
||||||
]);
|
]);
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue