Technical impact
The vulnerability resides in the machine-learning /predict endpoint of Immich, which accepts an options object from callers without validating security-sensitive parameters. An unauthenticated attacker who can reach the service can set the cache_dir field to an arbitrary writable filesystem path. The ML component then downloads models to that location and, when a model fails to load, uses shutil.rmtree() to clear the cache. As a result the attacker can cause the application to write files to any writable directory and recursively delete a directory they specify, leading to data loss or corruption. The flaw is a combination of uncontrolled path traversal (CWE‑22) and the use of a dangerous delete operation (CWE‑73).
Affected Systems
All installations of Immich prior to version 3.3.0 are affected. The vulnerability arises in the immich-app:immich component running the machine-learning service. Any deployment that exposes the /predict endpoint without authentication, such as on a public server or within an untrusted network, is vulnerable.
Risk and Exploitability
The CVSS score of 6.5 indicates moderate severity. EPSS is not available and the vulnerability is not listed in CISA's KEV catalog, but the attack requires only network access to the service and does not need credentials. An attacker could make the application overwrite files in writable directories or delete an entire subtree. The damage is bounded to data integrity and availability, with no possibility of arbitrary code execution because the model name is filtered. However, the ability to delete user media or configuration files can disrupt service operations and lead to significant business impact.