Bugzilla (bugzilla.redhat.com) will be under maintenance for infrastructure upgrades and will not be available on July 31st between 12:30 AM - 05:30 AM UTC. We appreciate your understanding and patience. You can follow status.redhat.com for details.
Bug 1490897 - GlusterD returns a bad memory pointer in glusterd_get_args_from_dict()
Summary: GlusterD returns a bad memory pointer in glusterd_get_args_from_dict()
Keywords:
Status: CLOSED CURRENTRELEASE
Alias: None
Product: GlusterFS
Classification: Community
Component: glusterd
Version: mainline
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Xavi Hernandez
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks: 1491166 1491178
TreeView+ depends on / blocked
 
Reported: 2017-09-12 12:44 UTC by Xavi Hernandez
Modified: 2017-12-08 17:40 UTC (History)
1 user (show)

Fixed In Version: glusterfs-3.13.0
Doc Type: If docs needed, set a value
Doc Text:
Clone Of:
: 1491166 1491178 (view as bug list)
Environment:
Last Closed: 2017-12-08 17:40:53 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:


Attachments (Terms of Use)

Description Xavi Hernandez 2017-09-12 12:44:02 UTC
Description of problem:

glusterd_get_args_from_dict() creates a new dict from unserialization of the data coming from getspec. From there it extracts 'brick_name' and stores the pointer to argument brick_name (a char **). Just before returning, dict is released, deallocating all related data, including the string pointer by brick_name.

Version-Release number of selected component (if applicable): mainline


How reproducible:


Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Worker Ant 2017-09-12 12:55:09 UTC
REVIEW: https://review.gluster.org/18263 (glusterd: fix invalid memory reference returned) posted (#1) for review on master by Xavier Hernandez (xhernandez@datalab.es)

Comment 2 Worker Ant 2017-09-12 13:03:47 UTC
REVIEW: https://review.gluster.org/18263 (glusterd: fix invalid memory reference returned) posted (#2) for review on master by Xavier Hernandez (xhernandez@datalab.es)

Comment 3 Worker Ant 2017-09-13 20:02:37 UTC
COMMIT: https://review.gluster.org/18263 committed in master by Jeff Darcy (jeff@pl.atyp.us) 
------
commit 2ec0dfe76780a8f82f4f6f8b7b3fdfd54203b616
Author: Xavier Hernandez <xhernandez@datalab.es>
Date:   Tue Sep 12 14:53:41 2017 +0200

    glusterd: fix invalid memory reference returned
    
    Change-Id: I0823c7b33060b48040c1d86ad346a5f6e15bc190
    BUG: 1490897
    Signed-off-by: Xavier Hernandez <xhernandez@datalab.es>
    Reviewed-on: https://review.gluster.org/18263
    Smoke: Gluster Build System <jenkins@build.gluster.org>
    CentOS-regression: Gluster Build System <jenkins@build.gluster.org>
    Reviewed-by: Jeff Darcy <jeff@pl.atyp.us>
    Reviewed-by: Gaurav Yadav <gyadav@redhat.com>

Comment 4 Shyamsundar 2017-12-08 17:40:53 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.13.0, please open a new bug report.

glusterfs-3.13.0 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] http://lists.gluster.org/pipermail/announce/2017-December/000087.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.