mirror_corosync/lib
Jan Friesse f286388275 cmap: Fix strncpy warning in cmap_iter_next
cmap_iter_next in contrast of it's icmap counterpart copies key name
into user preallocated space. In the worst case, key name may be
CMAP_KEYNAME_MAXLEN, so cmap_iter_next then need CMAP_KEYNAME_MAXLEN +
additional byte to store zero. strncpy was copying only
CMAP_KEYNAME_MAXLEN characters so there was possibility of unterminated
string.

Patch solves this by using memcpy and always add trailing zero.
Documentation was improved suggesting minimum size of keyname buffer to
be CMAP_KEYNAME_MAXLEN + 1.

Also sam and quorumtool were using too short buffer so they are fixed too.

Signed-off-by: Jan Friesse <jfriesse@redhat.com>
Reviewed-by: Christine Caulfield <ccaulfie@redhat.com>
2018-08-13 09:00:41 +02:00
..
cfg.c totemsrp: Revert totemsrp_get_ifaces() changes 2017-11-30 16:59:05 +01:00
cmap.c cmap: Fix strncpy warning in cmap_iter_next 2018-08-13 09:00:41 +02:00
cpg.c cpg: Handle fragmented message sending interrupt 2018-04-11 18:40:07 +02:00
libcfg.versions libqb: change ipc -> qb_ipc 2011-08-09 10:37:14 +10:00
libcfg.verso CFG: Remove ring-reenable code 2017-08-03 14:32:02 +02:00
libcmap.versions Add user library to use cmap service 2011-12-15 09:19:17 +01:00
libcmap.verso Add user library to use cmap service 2011-12-15 09:19:17 +01:00
libcpg.versions libqb: change ipc -> qb_ipc 2011-08-09 10:37:14 +10:00
libcpg.verso CPG model_initialize and ringid + members callback 2010-04-20 12:40:48 +00:00
libquorum.versions libqb: change ipc -> qb_ipc 2011-08-09 10:37:14 +10:00
libquorum.verso quorum: bump soname for libquorum to reflect API change 2012-01-10 15:48:07 +01:00
libsam.versions SAM implementation merge 2009-12-07 17:06:53 +00:00
libsam.verso SAM Confdb integration 2010-09-27 07:34:21 +00:00
libvotequorum.versions votequorum: drop votequorum_qdevice_getinfo and collapse data into getinfo 2012-08-07 11:07:17 +02:00
libvotequorum.verso libvotequorum: Bump version 2016-11-07 17:40:00 +01:00
Makefile.am Added checks for "--as-needed" and "--version-script" linker flags. 2013-04-03 12:30:51 +02:00
quorum.c Add header files when needed 2012-09-03 09:34:31 +02:00
sam.c cmap: Fix strncpy warning in cmap_iter_next 2018-08-13 09:00:41 +02:00
util.h Update copyright dates in util directory 2012-02-13 17:05:04 -07:00
votequorum.c votequorum: Fix up quorum/nodelist callbacks 2016-06-28 13:58:39 +02:00