diff options
author | Greg Hudson <ghudson@mit.edu> | 2009-09-22 16:46:06 +0000 |
---|---|---|
committer | Greg Hudson <ghudson@mit.edu> | 2009-09-22 16:46:06 +0000 |
commit | 3cd5f112cd2890c9647527335fbfb26d008c4ce0 (patch) | |
tree | b3f00239745996023700b06f80f152ad8c216e07 /src/kadmin | |
parent | f07bca9fc94a5cf2e3c0f58226c7973a4b86b7a9 (diff) | |
download | krb5-3cd5f112cd2890c9647527335fbfb26d008c4ce0.tar.gz krb5-3cd5f112cd2890c9647527335fbfb26d008c4ce0.tar.xz krb5-3cd5f112cd2890c9647527335fbfb26d008c4ce0.zip |
Fix a braino in r22782: we don't use strcpy even safely; use strlcpy
instead.
git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@22783 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/kadmin')
-rw-r--r-- | src/kadmin/cli/kadmin.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/kadmin/cli/kadmin.c b/src/kadmin/cli/kadmin.c index d4bb2bfdef..6f8c04b8e0 100644 --- a/src/kadmin/cli/kadmin.c +++ b/src/kadmin/cli/kadmin.c @@ -1174,7 +1174,7 @@ prepare_dummy_password(char *buf, size_t sz) size_t i; /* Must try to pass any password policy in place, and be valid UTF-8. */ - strcpy(buf, "6F a["); + strlcpy(buf, "6F a[", sz); for (i = strlen(buf); i < sz - 1; i++) buf[i] = 'a' + (i % 26); buf[sz - 1] = '\0'; |