Bug 1625660 - CVE-2018-10904 glusterfs: Unsanitized file names in debug/io-stats translator can allow remote attackers to execute arbitrary code
Summary: CVE-2018-10904 glusterfs: Unsanitized file names in debug/io-stats translator...
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: io-stats
Version: 3.12
Hardware: Unspecified
OS: Unspecified
high
high
Target Milestone: ---
Assignee: bugs@gluster.org
QA Contact:
URL:
Whiteboard:
Depends On: 1625103 1625106
Blocks: CVE-2018-10904
TreeView+ depends on / blocked
 
Reported: 2018-09-05 13:13 UTC by Amar Tumballi
Modified: 2018-09-14 08:30 UTC (History)
10 users (show)

Fixed In Version: glusterfs-3.12.14
Doc Type: Release Note
Doc Text:
Clone Of: 1625106
Environment:
Last Closed: 2018-09-14 08:30:35 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Amar Tumballi 2018-09-05 13:13:42 UTC
+++ This bug was initially created as a clone of Bug #1625106 +++

+++ This bug was initially created as a clone of Bug #1625103 +++


This is an automatically created tracking bug!  It was created to ensure
that one or more security vulnerabilities are fixed in affected versions
of fedora-all.

For comments that are specific to the vulnerability please use bugs filed
against the "Security Response" product referenced in the "Blocks" field.

For more information see:
http://fedoraproject.org/wiki/Security/TrackingBugs

When submitting as an update, use the fedpkg template provided in the next
comment(s).  This will include the bug IDs of this tracking bug as well as
the relevant top-level CVE bugs.

Please also mention the CVE IDs being fixed in the RPM changelog and the
fedpkg commit message.

NOTE: this issue affects multiple supported versions of Fedora. While only
one tracking bug has been filed, please correct all affected versions at
the same time.  If you need to fix the versions independent of each other,
you may clone this bug as appropriate.

--- Additional comment from Siddharth Sharma on 2018-09-04 02:33:29 EDT ---

Use the following template to for the 'fedpkg update' request to submit an
update for this issue as it contains the top-level parent bug(s) as well as
this tracking bug.  This will ensure that all associated bugs get updated
when new packages are pushed to stable.

=====

# bugfix, security, enhancement, newpackage (required)
type=security

# testing, stable
request=testing

# Bug numbers: 1234,9876
bugs=1601298,1625103

# Description of your update
notes=Security fix for [PUT CVEs HERE]

# Enable request automation based on the stable/unstable karma thresholds
autokarma=True
stable_karma=3
unstable_karma=-3

# Automatically close bugs when this marked as stable
close_bugs=True

# Suggest that users restart after update
suggest_reboot=False

======

Additionally, you may opt to use the bodhi web interface to submit updates:

https://bodhi.fedoraproject.org/updates/new

--- Additional comment from Worker Ant on 2018-09-04 02:45:05 EDT ---

REVIEW: https://review.gluster.org/21072 (io-stats: allow only relative path for dumping io-stats info) posted (#1) for review on master by Amar Tumballi

--- Additional comment from Worker Ant on 2018-09-05 05:25:31 EDT ---

COMMIT: https://review.gluster.org/21072 committed in master by "Amar Tumballi" <amarts> with a commit message- io-stats: dump io-stats info in /var/run/gluster

It wouldn't make sense to allow iostats file to be written in
*any* directory. While the formating makes sure we try to append
io-stats-name for the file, so overwriting existing file is slim,
but in any case it makes sense to restrict dumping to one directory.

Below are the sample commands, and files created for the corresponding
values:

 $ setfattr -n trusted.io-stats-dump -v file-for-dump $M0

In this case, the file would be in /var/run/gluster/file-for-dump

 $ setfattr -n trusted.io-stats-dump -v /dir1/dir2/file-for-dump $M0

In this case, then the dump file is in /var/run/gluster/dir1-dir2-file-for-dump

Note that the value passed for this virtual xattr would be treated as a
file, and even if the value has '/' in it, it would be changed to '-'
for sanity.

Fixes: bz#1625106

Change-Id: Id9ae6a40a190b8937c51662e6e1c2a0f6c86a0e0
Signed-off-by: Amar Tumballi <amarts>

Comment 1 Worker Ant 2018-09-05 13:17:51 UTC
REVIEW: https://review.gluster.org/21101 (io-stats: dump io-stats info in /var/run/gluster) posted (#1) for review on release-3.12 by Amar Tumballi

Comment 2 Worker Ant 2018-09-06 15:55:19 UTC
COMMIT: https://review.gluster.org/21101 committed in release-3.12 by "jiffin tony Thottan" <jthottan> with a commit message- io-stats: dump io-stats info in /var/run/gluster

It wouldn't make sense to allow iostats file to be written in
*any* directory. While the formating makes sure we try to append
io-stats-name for the file, so overwriting existing file is slim,
but in any case it makes sense to restrict dumping to one directory.

Below are the sample commands, and files created for the corresponding
values:

 $ setfattr -n trusted.io-stats-dump -v file-for-dump $M0

In this case, the file would be in /var/run/gluster/file-for-dump

 $ setfattr -n trusted.io-stats-dump -v /dir1/dir2/file-for-dump $M0

In this case, then the dump file is in /var/run/gluster/dir1-dir2-file-for-dump

Note that the value passed for this virtual xattr would be treated as a
file, and even if the value has '/' in it, it would be changed to '-'
for sanity.

BUG: 1625660

Change-Id: Id9ae6a40a190b8937c51662e6e1c2a0f6c86a0e0
Signed-off-by: Amar Tumballi <amarts>

Comment 3 Jiffin 2018-09-14 08:30:35 UTC
This bug is getting closed because a release has been made available that should address the reported issue. In case the problem is still not fixed with glusterfs-3.12.14, please open a new bug report.

glusterfs-3.12.14 has been announced on the Gluster mailinglists [1], packages for several distributions should become available in the near future. Keep an eye on the Gluster Users mailinglist [2] and the update infrastructure for your distribution.

[1] https://lists.gluster.org/pipermail/announce/2018-September/000112.html
[2] https://www.gluster.org/pipermail/gluster-users/


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