Skip to content

Commit b99a76f

Browse files
authored
Merge branch 'master' into master
2 parents b153224 + 13f94a2 commit b99a76f

26 files changed

+4292
-67
lines changed

.github/workflows/master.yml

+1
Original file line numberDiff line numberDiff line change
@@ -19,6 +19,7 @@ jobs:
1919

2020
- name: Install
2121
run: |
22+
export DETECT_CHROMEDRIVER_VERSION=true
2223
npm install
2324
npm run setheapsize
2425

.github/workflows/pull_requests.yml

+1
Original file line numberDiff line numberDiff line change
@@ -18,6 +18,7 @@ jobs:
1818

1919
- name: Install
2020
run: |
21+
export DETECT_CHROMEDRIVER_VERSION=true
2122
npm install
2223
npm run setheapsize
2324

package-lock.json

+33-11
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

+3-2
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
{
22
"name": "cyberchef",
3-
"version": "10.19.2",
3+
"version": "10.19.4",
44
"description": "The Cyber Swiss Army Knife for encryption, encoding, compression and data analysis.",
55
"author": "n1474335 <[email protected]>",
66
"homepage": "https://gchq.github.io/CyberChef",
@@ -55,9 +55,10 @@
5555
"babel-plugin-dynamic-import-node": "^2.3.3",
5656
"babel-plugin-transform-builtin-extend": "1.1.2",
5757
"base64-loader": "^1.0.0",
58-
"chromedriver": "^127.0.2",
58+
"chromedriver": "^130.0.0",
5959
"cli-progress": "^3.12.0",
6060
"colors": "^1.4.0",
61+
"compression-webpack-plugin": "^11.1.0",
6162
"copy-webpack-plugin": "^12.0.2",
6263
"core-js": "^3.37.1",
6364
"css-loader": "7.1.2",

src/core/config/Categories.json

+5
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,7 @@
164164
"name": "Public Key",
165165
"ops": [
166166
"Parse X.509 certificate",
167+
"Parse X.509 CRL",
167168
"Parse ASN.1 hex string",
168169
"PEM to Hex",
169170
"Hex to PEM",
@@ -235,8 +236,12 @@
235236
"Parse IPv6 address",
236237
"IPv6 Transition Addresses",
237238
"Parse IPv4 header",
239+
"Strip IPv4 header",
238240
"Parse TCP",
241+
"Strip TCP header",
242+
"Parse TLS record",
239243
"Parse UDP",
244+
"Strip UDP header",
240245
"Parse SSH Host Key",
241246
"Parse URI",
242247
"URL Encode",

src/core/lib/Protocol.mjs

+3
Original file line numberDiff line numberDiff line change
@@ -26,6 +26,9 @@ export function objToTable(obj, nested=false) {
2626
</tr>`;
2727

2828
for (const key in obj) {
29+
if (typeof obj[key] === "function")
30+
continue;
31+
2932
html += `<tr><td style='word-wrap: break-word'>${key}</td>`;
3033
if (typeof obj[key] === "object")
3134
html += `<td style='padding: 0'>${objToTable(obj[key], true)}</td>`;

src/core/operations/AddLineNumbers.mjs

+9-2
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,13 @@ class AddLineNumbers extends Operation {
2222
this.description = "Adds line numbers to the output.";
2323
this.inputType = "string";
2424
this.outputType = "string";
25-
this.args = [];
25+
this.args = [
26+
{
27+
"name": "Offset",
28+
"type": "number",
29+
"value": 0
30+
}
31+
];
2632
}
2733

2834
/**
@@ -33,10 +39,11 @@ class AddLineNumbers extends Operation {
3339
run(input, args) {
3440
const lines = input.split("\n"),
3541
width = lines.length.toString().length;
42+
const offset = args[0] ? parseInt(args[0], 10) : 0;
3643
let output = "";
3744

3845
for (let n = 0; n < lines.length; n++) {
39-
output += (n+1).toString().padStart(width, " ") + " " + lines[n] + "\n";
46+
output += (n+1+offset).toString().padStart(width, " ") + " " + lines[n] + "\n";
4047
}
4148
return output.slice(0, output.length-1);
4249
}

src/core/operations/JWTSign.mjs

+8-2
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,11 @@ class JWTSign extends Operation {
3636
name: "Signing algorithm",
3737
type: "option",
3838
value: JWT_ALGORITHMS
39+
},
40+
{
41+
name: "Header",
42+
type: "text",
43+
value: "{}"
3944
}
4045
];
4146
}
@@ -46,11 +51,12 @@ class JWTSign extends Operation {
4651
* @returns {string}
4752
*/
4853
run(input, args) {
49-
const [key, algorithm] = args;
54+
const [key, algorithm, header] = args;
5055

5156
try {
5257
return jwt.sign(input, key, {
53-
algorithm: algorithm === "None" ? "none" : algorithm
58+
algorithm: algorithm === "None" ? "none" : algorithm,
59+
header: JSON.parse(header || "{}")
5460
});
5561
} catch (err) {
5662
throw new OperationError(`Error: Have you entered the key correctly? The key should be either the secret for HMAC algorithms or the PEM-encoded private key for RSA and ECDSA.

src/core/operations/JWTVerify.mjs

+1-1
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ class JWTVerify extends Operation {
2222

2323
this.name = "JWT Verify";
2424
this.module = "Crypto";
25-
this.description = "Verifies that a JSON Web Token is valid and has been signed with the provided secret / private key.<br><br>The key should be either the secret for HMAC algorithms or the PEM-encoded private key for RSA and ECDSA.";
25+
this.description = "Verifies that a JSON Web Token is valid and has been signed with the provided secret / private key.<br><br>The key should be either the secret for HMAC algorithms or the PEM-encoded public key for RSA and ECDSA.";
2626
this.infoURL = "https://wikipedia.org/wiki/JSON_Web_Token";
2727
this.inputType = "string";
2828
this.outputType = "JSON";

0 commit comments

Comments
 (0)