Ensure that kadm5_chpass_principal_3() does not reference pol or hist
when the principal has a policy reference but the policy does not
exist. (Both structures are zeroed in this case, so the resulting
checks are pointless but have defined and harmless behavior.)
goto done;
kdb->pw_expiration = 0;
- if ((adb.aux_attributes & KADM5_POLICY)) {
- /* the policy was loaded before */
-
+ if (have_pol) {
ret = check_pw_reuse(handle->context, hist_keyblocks,
kdb->n_key_data, kdb->key_data,
1, &hist);