Bug 1111031 - CHANGELOG_FILL_HTIME_DIR macro fills buffer without size limits
Summary: CHANGELOG_FILL_HTIME_DIR macro fills buffer without size limits
Keywords:
Status: CLOSED EOL
Alias: None
Product: GlusterFS
Classification: Community
Component: core
Version: 3.5.0
Hardware: Unspecified
OS: Unspecified
unspecified
unspecified
Target Milestone: ---
Assignee: Keith Schincke
QA Contact:
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2014-06-19 05:52 UTC by Keith Schincke
Modified: 2016-06-17 16:23 UTC (History)
1 user (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2016-06-17 16:23:25 UTC
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Embargoed:


Attachments (Terms of Use)

Description Keith Schincke 2014-06-19 05:52:30 UTC
Description of problem:
The changelog-misc.h:CHANGELOG_FILE_HTIME_DIR macro fills a destination buffer with data without any bounds checking. A strcpy and strcat are used to append "/htime"  to the changelog_dir path. 

Recommend updating the marco to take the length of the destination buffer as the third parameter and use snprintf to fill the buffer. 

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

How reproducible:
100%

Steps to Reproduce:
1.
2.
3.

Actual results:


Expected results:


Additional info:

Comment 1 Anand Avati 2014-06-19 06:03:42 UTC
REVIEW: http://review.gluster.org/8108 (Update CHANGELOG_FILE_HTIME_DIR macro to use buffer size) posted (#1) for review on master by Keith Schincke (kschinck)

Comment 2 Mike McCune 2016-03-28 22:53:35 UTC
This bug was accidentally moved from POST to MODIFIED via an error in automation, please see mmccune with any questions

Comment 3 Niels de Vos 2016-06-17 16:23:25 UTC
This bug is getting closed because the 3.5 is marked End-Of-Life. There will be no further updates to this version. Please open a new bug against a version that still receives bugfixes if you are still facing this issue in a more current release.


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