GHSA-w4f8-fxq2-j35v Possible privilege escalation via bash completion script
Local attackers can escalate privileges by crafting malicious mountpoint paths that trigger command injection in the fscrypt bash completion script.
- Exploited in the wild
- Not known
- Login needed
- Any signed-in user
- Attackable
- Local or same network only
- Victim action needed
- A user has to click or open something
- Fix
- Available
What is GHSA-w4f8-fxq2-j35v?
GHSA-w4f8-fxq2-j35v is a command injection vulnerability in github.com/google/fscrypt, published on 1 Mar 2022. It can only be exploited from the same machine or local network, and only if a user opens a file or follows a link.
Official description
The bash completion script for fscrypt through v0.3.2 allows injection of commands via crafted mountpoint paths, allowing privilege escalation under a specific set of circumstances. A local user who has control over mountpoint paths could potentially escalate their privileges if they create a malicious mountpoint path and if the system administrator happens to be using the fscrypt bash completion script to complete mountpoint paths. We recommend upgrading to v0.3.3 or above.
For more details, see CVE-2022-25328.
Which versions are affected by GHSA-w4f8-fxq2-j35v?
2 open source packages ship an affected version, including github.com/google/fscrypt.
| Package | Affected | Fixed in |
|---|---|---|
github.com/google/fscrypt Go | All versions | 0.3.3 |
github.com/google/fscrypt Go | All versions | 0.3.3 |
How do I fix GHSA-w4f8-fxq2-j35v?
Upgrade github.com/google/fscrypt to 0.3.3 or later.
Upgrade, and pass arguments to programs as a list instead of through a shell. More about Command injection.
Is GHSA-w4f8-fxq2-j35v being exploited?
There is no known exploitation of GHSA-w4f8-fxq2-j35v in the wild and no public exploit code.