mirror of
https://github.com/gchq/CyberChef
synced 2026-01-03 17:13:53 +00:00
File scan now uses bytesMatch() instead of signatureMatches(), reducing call stack size
This commit is contained in:
@@ -133,7 +133,7 @@ export function scanForFileTypes(buf) {
|
||||
sigs.forEach(sig => {
|
||||
let pos = 0;
|
||||
while ((pos = locatePotentialSig(buf, sig, pos)) >= 0) {
|
||||
if (signatureMatches(sig, buf, pos)) {
|
||||
if (bytesMatch(sig, buf, pos)) {
|
||||
foundFiles.push({
|
||||
offset: pos,
|
||||
fileDetails: filetype
|
||||
|
||||
Reference in New Issue
Block a user