From: Barry Jaspan Date: Wed, 21 Aug 1996 18:12:49 +0000 (+0000) Subject: * kadmin.c: memset policy structures before passing them to X-Git-Tag: krb5-1.0-beta7~122 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=4a066e4bacfae3f0b80da568364881070a07dc91;p=krb5.git * kadmin.c: memset policy structures before passing them to kadm5_*_policy functions, so stack garbage >=2^32 doesn't end up in a long field and confuse xdr git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@8960 dc483132-0cff-0310-8789-dd5450dbe970 --- diff --git a/src/kadmin/cli/ChangeLog b/src/kadmin/cli/ChangeLog index 9f2f9aa82..3756de622 100644 --- a/src/kadmin/cli/ChangeLog +++ b/src/kadmin/cli/ChangeLog @@ -1,3 +1,9 @@ +Wed Aug 21 14:10:36 1996 Barry Jaspan + + * kadmin.c: memset policy structures before passing them to + kadm5_*_policy functions, so stack garbage >=2^32 doesn't end up + in a long field and confuse xdr + Mon Aug 19 12:11:27 1996 Barry Jaspan * kadmin.c: prints absolute 0 dates as "[never]", print mod date diff --git a/src/kadmin/cli/kadmin.c b/src/kadmin/cli/kadmin.c index 8012f7f8d..1a0d9b64e 100644 --- a/src/kadmin/cli/kadmin.c +++ b/src/kadmin/cli/kadmin.c @@ -1233,7 +1233,8 @@ void kadmin_addpol(argc, argv) krb5_error_code retval; long mask; kadm5_policy_ent_rec policy; - + + memset(&policy, 0, sizeof(policy)); if (kadmin_parse_policy_args(argc, argv, &policy, &mask, "add_policy")) { kadmin_addmodpol_usage("add_policy"); return; @@ -1257,7 +1258,8 @@ void kadmin_modpol(argc, argv) krb5_error_code retval; long mask; kadm5_policy_ent_rec policy; - + + memset(&policy, 0, sizeof(policy)); if (kadmin_parse_policy_args(argc, argv, &policy, &mask, "modify_policy")) { kadmin_addmodpol_usage("modify_policy");