mirror of
https://github.com/gchq/CyberChef.git
synced 2025-04-20 23:06:16 -04:00
ESM: Added Hex ops and created a Hex library.
This commit is contained in:
parent
0011e9caa8
commit
eeb1d0a891
18 changed files with 391 additions and 196 deletions
|
@ -3,6 +3,7 @@ import removeEXIF from "../vendor/remove-exif.js";
|
|||
import Utils from "../Utils.js";
|
||||
import FileType from "./FileType.js";
|
||||
import {fromBase64, toBase64} from "../lib/Base64";
|
||||
import {fromHex} from "../lib/Hex";
|
||||
|
||||
|
||||
/**
|
||||
|
@ -92,7 +93,7 @@ const Image = {
|
|||
// Convert input to raw bytes
|
||||
switch (inputFormat) {
|
||||
case "Hex":
|
||||
input = Utils.fromHex(input);
|
||||
input = fromHex(input);
|
||||
break;
|
||||
case "Base64":
|
||||
// Don't trust the Base64 entered by the user.
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue