+++ This bug was initially created as a clone of Bug #1633930 +++ Description of problem: As of now, glusterfs has an option to have '--enable-asan' during configure, which can be used to run the system with stricter memory check flags. There is a nightly job which runs with this flag @ https://build.gluster.org/job/asan/ Let us capture all the fixes which get in to the codebase as part of fixing ASan errors, using this bug! Version-Release number of selected component (if applicable): mainline How reproducible: Currently 100% Steps to Reproduce: 1. Run any regression tests after doing --enable-asan option!
REVIEW: https://review.gluster.org/21322 (mdcache: Fix asan reported potential heap buffer overflow) posted (#1) for review on release-5 by Shyamsundar Ranganathan
COMMIT: https://review.gluster.org/21322 committed in release-5 by "Shyamsundar Ranganathan" <srangana> with a commit message- mdcache: Fix asan reported potential heap buffer overflow The char pointer mdc_xattr_str in function mdc_xattr_list_populate is malloc'd and doing a strcat into a malloc'd region can overflow content allocated based on prior contents of the memory region. Added a NULL terimation to the malloc'd region to prevent the overflow, and treat it as an empty string. Change-Id: If0decab669551581230a8ede4c44c319ff04bac9 Updates: bz#1635373 Signed-off-by: ShyamsundarR <srangana> (cherry picked from commit d00a2a1b398346bbdc5ac9b3ba4b09fb1ce1e699)
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-5.0, please open a new bug report. glusterfs-5.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] https://lists.gluster.org/pipermail/announce/2018-October/000115.html [2] https://www.gluster.org/pipermail/gluster-users/