Vulnerability · Published May 3, 2022 · Assigned by openssl

CVE-2022-1292The c_rehash script allows command injection

Critical 9.8

In plain English

A critical-severity OS command injection in OpenSSL from OpenSSL. Proof-of-concept exploit code is public. The chance it is exploited in the next 30 days is estimated at 82.6% (higher than 99.7% of all known vulnerabilities). Ready-made attack tooling exists: public proof-of-concept code. Fixed versions are available - upgrade the affected package.

Severity (CVSS 3.1)9.8Critical
Exploit odds (30 days)82.6%top 0.3% of all CVEs
Exploited in the wildNo reportsCISA SSVC: poc
Attack tooling1Public PoC

Official description

The c_rehash script does not properly sanitise shell metacharacters to prevent command injection. This script is distributed by some operating systems in a manner where it is automatically executed. On such operating systems, an attacker could execute arbitrary commands with the privileges of the script. Use of the c_rehash script is considered obsolete and should be replaced by the OpenSSL rehash command line tool. Fixed in OpenSSL 3.0.3 (Affected 3.0.0,3.0.1,3.0.2). Fixed in OpenSSL 1.1.1o (Affected 1.1.1-1.1.1n). Fixed in OpenSSL 1.0.2ze (Affected 1.0.2-1.0.2zd).

Affected packages & fixed versions

EcosystemPackageFixed inAdvisory
AlmaLinux:8openssl1:1.1.1k-7.el8_6ALSA-2022:5818
AlmaLinux:9openssl1:3.0.1-41.el9_0ALSA-2022:6224
AlmaLinux:8openssl-devel1:1.1.1k-7.el8_6ALSA-2022:5818
AlmaLinux:9openssl-devel1:3.0.1-41.el9_0ALSA-2022:6224
AlmaLinux:8openssl-libs1:1.1.1k-7.el8_6ALSA-2022:5818
AlmaLinux:9openssl-libs1:3.0.1-41.el9_0ALSA-2022:6224
AlmaLinux:8openssl-perl1:1.1.1k-7.el8_6ALSA-2022:5818
AlmaLinux:9openssl-perl1:3.0.1-41.el9_0ALSA-2022:6224
Alpine:v3.20openssl0ALPINE-CVE-2022-1292
Alpine:v3.21openssl0ALPINE-CVE-2022-1292
Alpine:v3.22openssl0ALPINE-CVE-2022-1292
Alpine:v3.23openssl0ALPINE-CVE-2022-1292
Alpine:v3.24openssl0ALPINE-CVE-2022-1292
Debian:12openssl1.1.1o-1DEBIAN-CVE-2022-1292
Debian:13openssl1.1.1o-1DEBIAN-CVE-2022-1292
Debian:14openssl1.1.1o-1DEBIAN-CVE-2022-1292
Rocky Linux:8openssl1:1.1.1k-7.el8_6RLSA-2022:5818
Ubuntu:22.04:LTSedk22022.02-3ubuntu0.22.04.3USN-7060-1
Ubuntu:22.04:LTSnodejs12.22.9~dfsg-1ubuntu3.1USN-6457-1
Ubuntu:22.04:LTSnodejs12.22.9~dfsg-1ubuntu3.1UBUNTU-CVE-2022-1292
Ubuntu:22.04:LTSopenssl3.0.2-0ubuntu1.1USN-5402-1
Ubuntu:22.04:LTSopenssl3.0.2-0ubuntu1.1UBUNTU-CVE-2022-1292

Affected products (as reported)

VendorProductVersions
OpenSSL OpenSSL Fixed in OpenSSL 3.0.3 (Affected 3.0.0,3.0.1,3.0.2)Fixed in OpenSSL 1.1.1o (Affected 1.1.1-1.1.1n)Fixed in OpenSSL 1.0.2ze (Affected 1.0.2-1.0.2zd)

Weakness: CWE-78 · Vector: CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H

References