libadmin: Don't overflow volume name
authorSimon Wilkinson <sxw@your-file-system.com>
Sat, 2 Mar 2013 09:47:53 +0000 (09:47 +0000)
committerJeffrey Altman <jaltman@your-file-system.com>
Thu, 7 Mar 2013 15:53:10 +0000 (07:53 -0800)
commit79abe9d68ea041a2ea6261c6f7bb1f055a45bf0a
tree761792a97ea6bd067dc466166e403d564350451c
parent4f9ec8396d1c7f12f8fa264cea7c255ce62b7b8d
libadmin: Don't overflow volume name

The maximum volume name length in the VLDB RPCs is VL_MAXNAMELEN
(65), not 64 as used as a hardcoded value in vsprocs. Switch to
using the defined value, and also use strlcat to check that we
don't overflow this.

Caught by coverity (#985849)

Change-Id: Idde2cf8362bbd48538fafcd8c8d98e1f71cc15e1
Reviewed-on: http://gerrit.openafs.org/9353
Reviewed-by: Derrick Brashear <shadow@your-file-system.com>
Tested-by: BuildBot <buildbot@rampaginggeek.com>
Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
src/libadmin/vos/vsprocs.c