summaryrefslogtreecommitdiffstats
path: root/cli
diff options
context:
space:
mode:
authorMilind Changire <mchangir@redhat.com>2015-09-22 18:30:22 +0530
committerNiels de Vos <ndevos@redhat.com>2015-11-09 04:07:54 -0800
commit8356e4281c2953a7f35bf0b4bce194b0c678b6a5 (patch)
tree9383541b3d2a3c8117dd91be0edb4d81f17b790f /cli
parent9380b1d1fb74cd73d306a1a501e4b7b982c1a76e (diff)
gfapi: xattr key length check to avoid brick crash
Added check to test if xattr key length > max allowed for OS distribution and return: EINVAL if xattr name pointer is NULL or 0 length ENAMETOOLONG if xattr name length > max allowed for distribution Function exit path for invalid input is via label "out:" for mandatory __GLFS_EXIT_FS. Typically the VFS does this in the kernel for us. But since we are bypassing the VFS by providing the libgfapi to talk directly to the brick process, we need to add such checks. Change-Id: I610a8440871200ae4640351902b752777a3ec0c2 BUG: 1272926 Signed-off-by: Milind Changire <mchangir@redhat.com> Reviewed-on: http://review.gluster.org/12207 Tested-by: Gluster Build System <jenkins@build.gluster.com> Reviewed-by: Niels de Vos <ndevos@redhat.com> Tested-by: NetBSD Build System <jenkins@build.gluster.org> (cherry picked from commit 47d8d2fc9c88c95dfcae2c5c06e6eb3b1ce03a92) Reviewed-on: http://review.gluster.org/12387 Reviewed-by: Kaleb KEITHLEY <kkeithle@redhat.com>
Diffstat (limited to 'cli')
0 files changed, 0 insertions, 0 deletions