mirror of
https://github.com/gchq/CyberChef
synced 2025-12-22 03:03:26 +00:00
Compare commits
4 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
0805a011b9 | ||
|
|
3e3322e1f0 | ||
|
|
61d40b5a0b | ||
|
|
d175aa958c |
2
package-lock.json
generated
2
package-lock.json
generated
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "cyberchef",
|
"name": "cyberchef",
|
||||||
"version": "9.7.15",
|
"version": "9.7.17",
|
||||||
"lockfileVersion": 1,
|
"lockfileVersion": 1,
|
||||||
"requires": true,
|
"requires": true,
|
||||||
"dependencies": {
|
"dependencies": {
|
||||||
|
|||||||
@@ -1,6 +1,6 @@
|
|||||||
{
|
{
|
||||||
"name": "cyberchef",
|
"name": "cyberchef",
|
||||||
"version": "9.7.15",
|
"version": "9.7.17",
|
||||||
"description": "The Cyber Swiss Army Knife for encryption, encoding, compression and data analysis.",
|
"description": "The Cyber Swiss Army Knife for encryption, encoding, compression and data analysis.",
|
||||||
"author": "n1474335 <n1474335@gmail.com>",
|
"author": "n1474335 <n1474335@gmail.com>",
|
||||||
"homepage": "https://gchq.github.io/CyberChef",
|
"homepage": "https://gchq.github.io/CyberChef",
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ class DESDecrypt extends Operation {
|
|||||||
DES uses a key length of 8 bytes (64 bits).
|
DES uses a key length of 8 bytes (64 bits).
|
||||||
Triple DES uses a key length of 24 bytes (192 bits).`);
|
Triple DES uses a key length of 24 bytes (192 bits).`);
|
||||||
}
|
}
|
||||||
if (iv.length !== 8) {
|
if (iv.length !== 8 && mode !== "ECB") {
|
||||||
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
||||||
|
|
||||||
DES uses an IV length of 8 bytes (64 bits).
|
DES uses an IV length of 8 bytes (64 bits).
|
||||||
|
|||||||
@@ -73,7 +73,7 @@ class DESEncrypt extends Operation {
|
|||||||
DES uses a key length of 8 bytes (64 bits).
|
DES uses a key length of 8 bytes (64 bits).
|
||||||
Triple DES uses a key length of 24 bytes (192 bits).`);
|
Triple DES uses a key length of 24 bytes (192 bits).`);
|
||||||
}
|
}
|
||||||
if (iv.length !== 8) {
|
if (iv.length !== 8 && mode !== "ECB") {
|
||||||
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
||||||
|
|
||||||
DES uses an IV length of 8 bytes (64 bits).
|
DES uses an IV length of 8 bytes (64 bits).
|
||||||
|
|||||||
@@ -76,8 +76,8 @@ class Fork extends Operation {
|
|||||||
}
|
}
|
||||||
|
|
||||||
const recipe = new Recipe();
|
const recipe = new Recipe();
|
||||||
let output = "",
|
const outputs = [];
|
||||||
progress = 0;
|
let progress = 0;
|
||||||
|
|
||||||
state.forkOffset += state.progress + 1;
|
state.forkOffset += state.progress + 1;
|
||||||
|
|
||||||
@@ -104,10 +104,10 @@ class Fork extends Operation {
|
|||||||
}
|
}
|
||||||
progress = err.progress + 1;
|
progress = err.progress + 1;
|
||||||
}
|
}
|
||||||
output += await dish.get(outputType) + mergeDelim;
|
outputs.push(await dish.get(outputType));
|
||||||
}
|
}
|
||||||
|
|
||||||
state.dish.set(output, outputType);
|
state.dish.set(outputs.join(mergeDelim), outputType);
|
||||||
state.progress += progress;
|
state.progress += progress;
|
||||||
return state;
|
return state;
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ class TripleDESDecrypt extends Operation {
|
|||||||
Triple DES uses a key length of 24 bytes (192 bits).
|
Triple DES uses a key length of 24 bytes (192 bits).
|
||||||
DES uses a key length of 8 bytes (64 bits).`);
|
DES uses a key length of 8 bytes (64 bits).`);
|
||||||
}
|
}
|
||||||
if (iv.length !== 8) {
|
if (iv.length !== 8 && mode !== "ECB") {
|
||||||
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
||||||
|
|
||||||
Triple DES uses an IV length of 8 bytes (64 bits).
|
Triple DES uses an IV length of 8 bytes (64 bits).
|
||||||
|
|||||||
@@ -75,7 +75,7 @@ class TripleDESEncrypt extends Operation {
|
|||||||
Triple DES uses a key length of 24 bytes (192 bits).
|
Triple DES uses a key length of 24 bytes (192 bits).
|
||||||
DES uses a key length of 8 bytes (64 bits).`);
|
DES uses a key length of 8 bytes (64 bits).`);
|
||||||
}
|
}
|
||||||
if (iv.length !== 8) {
|
if (iv.length !== 8 && mode !== "ECB") {
|
||||||
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
throw new OperationError(`Invalid IV length: ${iv.length} bytes
|
||||||
|
|
||||||
Triple DES uses an IV length of 8 bytes (64 bits).
|
Triple DES uses an IV length of 8 bytes (64 bits).
|
||||||
|
|||||||
@@ -42,7 +42,7 @@ TestRegister.addTests([
|
|||||||
{
|
{
|
||||||
name: "Fork, Comment, Base64",
|
name: "Fork, Comment, Base64",
|
||||||
input: "cat\nsat\nmat",
|
input: "cat\nsat\nmat",
|
||||||
expectedOutput: "Y2F0\nc2F0\nbWF0\n",
|
expectedOutput: "Y2F0\nc2F0\nbWF0",
|
||||||
recipeConfig: [
|
recipeConfig: [
|
||||||
{
|
{
|
||||||
"op": "Fork",
|
"op": "Fork",
|
||||||
|
|||||||
@@ -57,7 +57,7 @@ TestRegister.addTests([
|
|||||||
{
|
{
|
||||||
name: "Fork, Conditional Jump, Encodings",
|
name: "Fork, Conditional Jump, Encodings",
|
||||||
input: "Some data with a 1 in it\nSome data with a 2 in it",
|
input: "Some data with a 1 in it\nSome data with a 2 in it",
|
||||||
expectedOutput: "U29tZSBkYXRhIHdpdGggYSAxIGluIGl0\n53 6f 6d 65 20 64 61 74 61 20 77 69 74 68 20 61 20 32 20 69 6e 20 69 74\n",
|
expectedOutput: "U29tZSBkYXRhIHdpdGggYSAxIGluIGl0\n53 6f 6d 65 20 64 61 74 61 20 77 69 74 68 20 61 20 32 20 69 6e 20 69 74",
|
||||||
recipeConfig: [
|
recipeConfig: [
|
||||||
{"op": "Fork", "args": ["\\n", "\\n", false]},
|
{"op": "Fork", "args": ["\\n", "\\n", false]},
|
||||||
{"op": "Conditional Jump", "args": ["1", false, "skipReturn", "10"]},
|
{"op": "Conditional Jump", "args": ["1", false, "skipReturn", "10"]},
|
||||||
|
|||||||
Reference in New Issue
Block a user