Privilege Escalation Vulnerability in fscrypt Package
Summary
CVE-2018-6558: The pam_fscrypt module in fscrypt before 0.2.4 may incorrectly restore primary and supplementary group IDs to the values associated with the root user, which allows attackers to gain privileges via a successful login thr... Affects fscrypt across 3 version ranges.
< 0.2.4-1
< 315f9b042237200174a1fb99427f74027e191d66
< 3022c1603d968c22f147b4a2c49c4637dd1be91b
Fixed in 0.2.4-1. How to fix ↓
Check if this vulnerability affects your application
Upload a manifest or SBOM and we'll show whether you're affected, plus every other risky package in the same scan.
No signup required · Results in about 60 seconds
Background
The fscrypt package is a tool for managing filesystem encryption on Linux systems. It provides a way to encrypt files and directories, enhancing data security. However, it has been found to have a vulnerability in the pam_fscrypt module that may lead to privilege escalation, allowing unauthorized users to gain elevated access.
Vulnerability Detail
The pam_fscrypt module in fscrypt versions prior to 0.2.4 contains a flaw that may incorrectly restore primary and supplementary group IDs to those associated with the root user. This vulnerability can be exploited by attackers who successfully log in through applications that utilize Linux-PAM, potentially granting them unauthorized privileges. The issue arises from improper handling of user group IDs, which can lead to significant security risks.
How To Fix
Minimum fixed version
0.2.4-1
This is the first release that contains the fix.
sudo apt-get install --only-upgrade fscrypt
Tip — Not sure which version your app runs? Vulert can match this fix to it. Scan free →
Workaround
As a temporary workaround, ensure that applications using Linux-PAM do not allow unauthorized access to users who should not have elevated privileges. Additionally, consider restricting access to the fscrypt module until the package can be updated.
Conclusion
The fscrypt package has a critical vulnerability that can lead to privilege escalation if not addressed. Users are strongly advised to update to the latest version to mitigate risks. Utilizing tools like Vulert can help in monitoring and managing vulnerabilities effectively.
See every vulnerability recorded for fscrypt →
FAQ
The CVSS score for this vulnerability is 6.5, indicating a medium severity level.
You can use the Vulert playground at Vulert Scanner to check if your application is affected by this vulnerability without requiring any signup.
If exploited, this vulnerability can allow unauthorized users to gain elevated privileges, potentially leading to data breaches or system compromise.
Yes, Vulert can monitor and alert you in real-time for open-source vulnerabilities in your software by using a manifest file like package-lock.json.
If an immediate update is not possible, implement access controls to limit user permissions and monitor system logs for any unauthorized access attempts.
References
Related vulnerabilities
Recent vulnerabilities recorded for fscrypt.