{"record":{"id":"9b83c0ae66733b9e","repo":"moonD4rk/HackBrowserData","slug":"no-decryption-relevant-files-found-to-archive","errorCode":null,"errorMessage":"no decryption-relevant files found to archive","messagePattern":"no decryption-relevant files found to archive","errorType":"exception","errorClass":null,"httpStatus":null,"severity":"error","filePath":"browser/archive.go","lineNumber":62,"sourceCode":"\t\t\tif seen[entry] {\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tseen[entry] = true\n\n\t\t\tdst := filepath.Join(staging, key, filepath.FromSlash(src.LayoutRel))\n\t\t\tif err := os.MkdirAll(filepath.Dir(dst), 0o755); err != nil {\n\t\t\t\tlog.Warnf(\"archive: %s: %v\", entry, err)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tif err := session.Acquire(src.AbsPath, dst, src.IsDir); err != nil {\n\t\t\t\tlog.Warnf(\"archive: acquire %s: %v\", entry, err)\n\t\t\t\tcontinue\n\t\t\t}\n\t\t\tcount++\n\t\t}\n\t}\n\tif count == 0 {\n\t\treturn 0, fmt.Errorf(\"no decryption-relevant files found to archive\")\n\t}\n\tif err := fileutil.ZipDir(outPath, staging); err != nil {\n\t\treturn 0, fmt.Errorf(\"write archive %s: %w\", outPath, err)\n\t}\n\treturn count, nil\n}\n","sourceCodeStart":44,"sourceCodeEnd":69,"githubUrl":"https://github.com/moonD4rk/HackBrowserData/blob/0503d04d7a8d0379d060268a74f1b149e5a0aad5/browser/archive.go#L44-L69","documentation":"WriteArchive collects a browser profile's decryption-relevant files (Local State, Cookies DB, etc.) into a staging directory before zipping. If it matched zero eligible files, there is nothing to archive, so it errors instead of producing an empty zip. This indicates the profile path was wrong or the expected files were filtered out.","triggerScenarios":"Calling WriteArchive on a profile directory that contains none of the recognized decryption-relevant files (all candidates skipped/filtered), so count == 0.","commonSituations":"Pointing at an empty or freshly created profile directory, wrong profile path (typo or wrong profile number), a browser whose file layout doesn't match the filter list, or files already deleted by cleanup tooling.","solutions":["Verify the profile directory path points at a real profile containing Local State / Cookies and other expected files.","List the directory contents and compare against the file filter WriteArchive uses; adjust the path or filter.","Re-copy the browser profile (Chrome may delete files while running — copy from a closed browser).","If intentional, guard the call by checking for required files before invoking WriteArchive."],"exampleFix":"// before: points at browser root, not a profile\nWriteArchive(\"/Users/me/Library/Application Support/Google/Chrome\", out)\n// after: point at the specific profile\nWriteArchive(\"/Users/me/Library/Application Support/Google/Chrome/Default\", out)","handlingStrategy":"validation","validationCode":"entries, err := os.ReadDir(profileDir)\nif err != nil || len(entries) == 0 {\n    return fmt.Errorf(\"profile %q missing or empty\", profileDir)\n}","typeGuard":null,"tryCatchPattern":"n, err := browser.WriteArchive(profileDir, outPath)\nif err != nil && strings.Contains(err.Error(), \"no decryption-relevant files\") {\n    return fmt.Errorf(\"profile %q has no relevant files: %w\", profileDir, err)\n}","preventionTips":["Point WriteArchive at a concrete profile directory (e.g. .../Default), not the browser root.","Verify required files (Local State, Cookies) exist before archiving.","Close the browser before copying its profile so files aren't removed mid-copy."],"tags":["archive","file-not-found","browser-profile","zip"],"backgroundTag":"empty-result-set","analyzedSha":"0503d04d7a8d0379d060268a74f1b149e5a0aad5","analyzedAt":"2026-09-06T13:38:28.707Z","contentChangedAt":"2026-09-06T13:38:28.707Z","schemaVersion":2},"datasetVersion":"2026-09-14T05:17:10.506Z"}