ruby: IV Reuse in GCM Mode
Published Jan 30, 2017
7.5
HIGHCVSS 3.1
EPSS 3.17%
Description
The openssl gem for Ruby uses the same initialization vector (IV) in GCM Mode (aes-*-gcm) when the IV is set before the key, which makes it easier for context-dependent attackers to bypass the encryption protection mechanism.
Affected products
No data.
Configuration 2
- 8.0
- 9.0
No data.
CloudForms Management Engine 5
rh-ruby22-ruby
Will not fix
CloudForms Management Engine 5
ruby-200-ruby
Will not fix
Red Hat Enterprise Linux 5
ruby
Will not fix
Red Hat Enterprise Linux 6
ruby
Will not fix
Red Hat Enterprise Linux 7
ruby
Will not fix
Red Hat Software Collections
rh-ruby22-ruby
Will not fix
Red Hat Software Collections
rh-ruby23-ruby
Will not fix
Red Hat Software Collections
ruby200-ruby
Will not fix
| Product | Package | State | Advisory |
|---|---|---|---|
| CloudForms Management Engine 5 | rh-ruby22-ruby | Will not fix | n/a |
| CloudForms Management Engine 5 | ruby-200-ruby | Will not fix | n/a |
| Red Hat Enterprise Linux 5 | ruby | Will not fix | n/a |
| Red Hat Enterprise Linux 6 | ruby | Will not fix | n/a |
| Red Hat Enterprise Linux 7 | ruby | Will not fix | n/a |
| Red Hat Software Collections | rh-ruby22-ruby | Will not fix | n/a |
| Red Hat Software Collections | rh-ruby23-ruby | Will not fix | n/a |
| Red Hat Software Collections | ruby200-ruby | Will not fix | n/a |
No package ranges for this CVE.
Remediation
Red Hat mitigation
A possible workaround to this flaw is, when using aes-256-gcm mode, always set the key first and then the iv. For example when setting random keys and iv use the following code segment: key = cipher.random_key iv = cipher.random_iv
Metrics
No CVSS v4.0 score for this CVE.
CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:N/A:N
CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:U/C:L/I:N/A:N
AV:N/AC:L/Au:N/C:P/I:N/A:N
This CVE is not in the KEV list.
No CISA SSVC assessment for this CVE yet.
Estimated probability of exploitation in the wild in the next 30 days (FIRST EPSS). As of Oct 1, 2026.
Score over time
2022–2026- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Percentile over time
- EPSS v2
- EPSS v3
- EPSS v4
- EPSS v5
Table of values (11 key points)
Flat stretches are collapsed; showing up to 120 newest points.
| Date | Score | Percentile | Model |
|---|---|---|---|
| Oct 1, 2026 | 3.17% (0.03167) | 87.56th | v5 (v2026.06.15) |
| Jun 15, 2026 | 3.17% (0.03167) | 86.31th | v5 (v2026.06.15) |
| Mar 17, 2025 | 0.15% (0.00147) | 32.53th | v4 (v2025.03.14) |
| Dec 12, 2024 | 0.38% (0.00383) | 73.90th | v3 (v2023.03.01) |
| Feb 8, 2024 | 0.38% (0.00383) | 72.31th | v3 (v2023.03.01) |
| Mar 28, 2023 | 0.38% (0.00383) | 68.81th | v3 (v2023.03.01) |
| Mar 7, 2023 | 0.41% (0.00413) | 69.94th | v3 (v2023.03.01) |
| Mar 6, 2023 | 1.18% (0.01183) | 61.76th | v2 (v2022.01.01) |
| Oct 19, 2022 | 1.18% (0.01183) | 60.79th | v2 (v2022.01.01) |
| Apr 1, 2022 | 1.18% (0.01183) | 58.77th | v2 (v2022.01.01) |
| Feb 4, 2022 | 1.18% (0.01183) | 35.15th | v2 (v2022.01.01) |
References (15)
- http://www.openwall.com/lists/oss-security/2016/09/19/9 mailing-listx_refsource_MLISTMailing ListThird Party Advisory
- http://www.openwall.com/lists/oss-security/2016/09/30/6 mailing-listx_refsource_MLISTMailing ListPatchThird Party Advisory
- http://www.openwall.com/lists/oss-security/2016/10/01/2 mailing-listx_refsource_MLISTMailing ListThird Party Advisory
- http://www.securityfocus.com/bid/93031 vdb-entryx_refsource_BIDThird Party AdvisoryVDB Entry
- https://access.redhat.com/security/cve/CVE-2016-7798 Vendor Advisory
- https://bugzilla.redhat.com/show_bug.cgi?id=1381526 Issue Tracking
- https://github.com/advisories/GHSA-6h88-qjpv-p32m Advisory
- https://github.com/ruby/openssl/commit/8108e0a6db133f3375608303fdd2083eb5115062 x_refsource_CONFIRMPatchThird Party Advisory
- https://github.com/ruby/openssl/issues/49 x_refsource_CONFIRMExploitThird Party Advisory
- https://github.com/rubysec/ruby-advisory-db/blob/master/gems/openssl/CVE-2016-7798.yml
- https://lists.debian.org/debian-lts-announce/2018/07/msg00012.html mailing-listx_refsource_MLISTMailing ListThird Party Advisory
- https://nvd.nist.gov/vuln/detail/CVE-2016-7798
- https://web.archive.org/web/20210121065227/https://www.securityfocus.com/bid/93031/info
- https://www.cve.org/CVERecord?id=CVE-2016-7798
- https://www.debian.org/security/2017/dsa-3966 vendor-advisoryx_refsource_DEBIANThird Party Advisory
Change history (0)
No recorded changes yet.