Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 1381526 - (CVE-2016-7798) CVE-2016-7798 ruby: IV Reuse in GCM Mode
CVE-2016-7798 ruby: IV Reuse in GCM Mode
Status: NEW
Product: Security Response
Classification: Other
Component: vulnerability (Show other bugs)
unspecified
All Linux
medium Severity medium
: ---
: ---
Assigned To: Red Hat Product Security
impact=moderate,public=20160919,repor...
: Security
Depends On: 1381527
Blocks: 1381528
  Show dependency treegraph
 
Reported: 2016-10-04 07:25 EDT by Andrej Nemec
Modified: 2018-06-29 18:15 EDT (History)
22 users (show)

See Also:
Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed:
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

  None (edit)
Description Andrej Nemec 2016-10-04 07:25:32 EDT
An IV reuse bug was discovered in Ruby's OpenSSL library when using
aes-gcm. When encrypting data with aes-*-gcm, if the IV is set before
setting the key, the cipher will default to using a static IV. This creates
a static nonce and since aes-gcm is a stream cipher, this can lead to known
cryptographic issues.

References:

http://seclists.org/oss-sec/2016/q3/562

Upstream bug:

https://github.com/ruby/openssl/issues/49

Upstream patch:

https://github.com/ruby/openssl/commit/8108e0a6db133f3375608303fdd2083eb5115062
Comment 1 Andrej Nemec 2016-10-04 07:26:13 EDT
Created ruby tracking bugs for this issue:

Affects: fedora-all [bug 1381527]
Comment 2 Huzaifa S. Sidhpurwala 2016-11-28 02:44:17 EST
Analysis:

As explained in https://github.com/ruby/openssl/issues/49#issuecomment-248171371
Calling cipher.key after calling cipher.iv zeros out the value of the iv, resulting in a possibly weak cryptographic operation. 


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

Note You need to log in before you can comment on or make changes to this bug.