mirror of
https://github.com/morluto/rea
synced 2026-10-26 14:25:49 -04:00
fix(il2cpp): refuse a seed path under a non-directory as caller input (#6271)
Co-authored-by: Abelo9996 <Abelo9996@users.noreply.github.com>
This commit is contained in:
@@ -69,6 +69,13 @@ export class Il2cppGhidraSeedWriter implements Il2cppSeedWriterPort {
|
||||
} catch (cause) {
|
||||
if (cause instanceof Error && "code" in cause && cause.code === "ENOENT")
|
||||
return ok(undefined);
|
||||
if (cause instanceof Error && "code" in cause && cause.code === "ENOTDIR")
|
||||
return err(
|
||||
invalid(
|
||||
"ghidra_seeds",
|
||||
`--ghidra-seeds ${output.path} has a parent path component that is not a directory; choose an output path inside an existing directory.`,
|
||||
),
|
||||
);
|
||||
return err(
|
||||
new EvidenceFileError("write", "io", { path: output.path, cause }),
|
||||
);
|
||||
|
||||
Reference in New Issue
Block a user