What’s Vulnerable › Vulnerabilities
CVE-2022-42717
- Severity: high (CVSS 7.8 v3.1)
- Exploited in the wild: not listed in CISA KEV
- EPSS: 0.3% probability of exploitation in the next 30 days
- Public exploit or detection template: none known
- Published: 2022-10-11 · updated 2026-06-17
- Weakness: CWE-284
Description
An issue was discovered in Hashicorp Packer before 2.3.1. The recommended sudoers configuration for Vagrant on Linux is insecure. If the host has been configured according to this documentation, non-privileged users on the host can leverage a wildcard in the sudoers configuration to execute arbitrary commands as root.
Affected products
- HashiCorp Vagrant: before 2.3.1 — fixed in 2.3.1
How to fix
Upgrade to a fixed version: HashiCorp Vagrant 2.3.1. Check the vendor advisory for mitigations.
References
- https://discuss.hashicorp.com/t/hcsec-2022-23-vagrant-nfs-sudoers-configuration-allows-for-local-privilege-escalation/45423
- https://github.com/hashicorp/vagrant/pull/12910
- https://www.vagrantup.com/docs/synced-folders/nfs
- https://discuss.hashicorp.com/t/hcsec-2022-23-vagrant-nfs-sudoers-configuration-allows-for-local-privilege-escalation/45423
- https://github.com/hashicorp/vagrant/pull/12910
- https://www.vagrantup.com/docs/synced-folders/nfs
Get alerted when CVE-2022-42717 or the next vulnerability affects your stack