Description
AnythingLLM is an application that turns pieces of content into context that any LLM can use as references during chatting. In 1.11.1 and earlier, The ImportedPlugin.importCommunityItemFromUrl() function in server/utils/agents/imported.js downloads a ZIP file from a community hub URL and extracts it using AdmZip.extractAllTo() without validating file paths within the archive. This enables a Zip Slip path traversal attack that can lead to arbitrary code execution.
Problem types
CWE-22: Improper Limitation of a Pathname to a Restricted Directory ('Path Traversal')
CWE-94: Improper Control of Generation of Code ('Code Injection')
Product status
References
github.com/...ng-llm/security/advisories/GHSA-rh66-4w74-cf4m
github.com/...ommit/6a492f038da195a5c9a239d5ca2e9f2151c25f8c