Bug 1643089 (CVE-2018-16396) - CVE-2018-16396 ruby: Tainted flags are not propagated in Array#pack and String#unpack with some directives
Summary: CVE-2018-16396 ruby: Tainted flags are not propagated in Array#pack and Strin...
Keywords:
Status: CLOSED ERRATA
Alias: CVE-2018-16396
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1643091 1643092 1643631 1643633 1643635 1647502 1647503 1647504 1647505 1837062 1837063
Blocks: 1643090
TreeView+ depends on / blocked
 
Reported: 2018-10-25 13:37 UTC by Andrej Nemec
Modified: 2021-12-10 18:03 UTC (History)
27 users (show)

Fixed In Version:
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
Environment:
Last Closed: 2019-06-10 10:41:03 UTC
Embargoed:


Attachments (Terms of Use)


Links
System ID Private Priority Status Summary Last Updated
Red Hat Product Errata RHSA-2018:3729 0 None None None 2018-11-29 09:57:21 UTC
Red Hat Product Errata RHSA-2018:3730 0 None None None 2018-11-29 10:12:10 UTC
Red Hat Product Errata RHSA-2018:3731 0 None None None 2018-11-29 10:23:04 UTC
Red Hat Product Errata RHSA-2019:2028 0 None None None 2019-08-06 12:03:58 UTC
Red Hat Product Errata RHSA-2020:2769 0 None None None 2020-06-30 12:09:22 UTC
Red Hat Product Errata RHSA-2020:2839 0 None None None 2020-07-07 10:17:33 UTC

Description Andrej Nemec 2018-10-25 13:37:46 UTC
Array#pack method converts the receiver’s contents into a string with specified format. If the receiver contains some tainted objects, the returned string also should be tainted. String#unpack method which converts the receiver into an array also should propagate its tainted flag to the objects contained in the returned array. But, with B, b, H and h directives, the tainted flags are not propagated. So, if a script processes unreliable inputs by Array#pack and/or String#unpack with these directives and checks the reliability with tainted flags, the check might be wrong.

External References:

https://www.ruby-lang.org/en/news/2018/10/17/not-propagated-taint-flag-in-some-formats-of-pack-cve-2018-16396/

Comment 1 Andrej Nemec 2018-10-25 13:40:17 UTC
Created ruby tracking bugs for this issue:

Affects: fedora-all [bug 1643091]

Comment 8 Scott Gayou 2018-11-07 16:00:28 UTC
RHEL*/RHSCL affected.

Comment 9 Doran Moppert 2018-11-19 05:01:24 UTC
Statement:

Subscription Asset Manager is now in a reduced support phase receiving only Critical impact security fixes. This issue has been rated as having a security impact of Low, and is not currently planned to be addressed in future updates.

Red Hat Virtualization includes a vulnerable version of ruby, however the affected functionality is not used in Red Hat Virtualization or any of its dependencies. A future update may address this issue.

Comment 10 errata-xmlrpc 2018-11-29 09:57:09 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 6
  Red Hat Software Collections for Red Hat Enterprise Linux 7
  Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS

Via RHSA-2018:3729 https://access.redhat.com/errata/RHSA-2018:3729

Comment 11 errata-xmlrpc 2018-11-29 10:12:00 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 6
  Red Hat Software Collections for Red Hat Enterprise Linux 7
  Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS

Via RHSA-2018:3730 https://access.redhat.com/errata/RHSA-2018:3730

Comment 12 errata-xmlrpc 2018-11-29 10:22:53 UTC
This issue has been addressed in the following products:

  Red Hat Software Collections for Red Hat Enterprise Linux 7
  Red Hat Software Collections for Red Hat Enterprise Linux 7.4 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.5 EUS
  Red Hat Software Collections for Red Hat Enterprise Linux 7.6 EUS

Via RHSA-2018:3731 https://access.redhat.com/errata/RHSA-2018:3731

Comment 13 errata-xmlrpc 2019-08-06 12:03:57 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7

Via RHSA-2019:2028 https://access.redhat.com/errata/RHSA-2019:2028

Comment 16 errata-xmlrpc 2020-06-30 12:09:18 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7.4 Advanced Update Support
  Red Hat Enterprise Linux 7.4 Update Services for SAP Solutions
  Red Hat Enterprise Linux 7.4 Telco Extended Update Support

Via RHSA-2020:2769 https://access.redhat.com/errata/RHSA-2020:2769

Comment 17 errata-xmlrpc 2020-07-07 10:17:29 UTC
This issue has been addressed in the following products:

  Red Hat Enterprise Linux 7.6 Extended Update Support

Via RHSA-2020:2839 https://access.redhat.com/errata/RHSA-2020:2839


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