mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-21 15:26:16 -04:00
Replaced hexToByteArray with fromHex and byteArrayToHex with toHex. Switched displayFilesAsHTML operation to use template strings and introduced markup formatting method.
This commit is contained in:
parent
2400de337b
commit
c460c2bf6b
5 changed files with 62 additions and 99 deletions
|
@ -283,7 +283,7 @@ const IP = {
|
|||
baIp.push(decimal & 255);
|
||||
break;
|
||||
case "Hex":
|
||||
baIp = Utils.hexToByteArray(lines[i]);
|
||||
baIp = Utils.fromHex(lines[i]);
|
||||
break;
|
||||
default:
|
||||
throw "Unsupported input IP format";
|
||||
|
@ -516,7 +516,7 @@ const IP = {
|
|||
"<tr><td>Destination IP address</td><td>" + IP._ipv4ToStr(dstIP) + "</td></tr>";
|
||||
|
||||
if (ihl > 5) {
|
||||
output += "<tr><td>Options</td><td>" + Utils.byteArrayToHex(options) + "</td></tr>";
|
||||
output += "<tr><td>Options</td><td>" + Utils.toHex(options) + "</td></tr>";
|
||||
}
|
||||
|
||||
return output + "</table>";
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue