From 504b51535dac5180659732657a5cb2e7817b4a13 Mon Sep 17 00:00:00 2001 From: michael Date: Mon, 17 Jun 2013 19:21:30 +0000 Subject: - tools/mkpasswd.c: replace another sprintf() with snprintf() git-svn-id: svn://svn.ircd-hybrid.org/svnroot/ircd-hybrid/branches/8.1.x@2264 82007160-df01-0410-b94d-b575c5fd34c7 --- tools/mkpasswd.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'tools') diff --git a/tools/mkpasswd.c b/tools/mkpasswd.c index 81eb95a..9c40dc6 100644 --- a/tools/mkpasswd.c +++ b/tools/mkpasswd.c @@ -254,7 +254,8 @@ make_ext_salt(int rounds) { static char salt[10]; - sprintf(salt, "_%s", int_to_base64(rounds)); + snprintf(salt, sizeof(salt), "_%s", int_to_base64(rounds)); + generate_random_salt(&salt[5], 4); salt[9] = '\0'; -- cgit