Skip to content

Commit

Permalink
Fix KCM client time offset propagation
Browse files Browse the repository at this point in the history
An inverted status check in get_kdc_offset() would cause querying the
offset time from the ccache to always fail (silently) on KCM.  Fix the
status check so that KCM can properly handle desync.

(cherry picked from commit 323abb6)

ticket: 8826
version_fixed: 1.17.1
  • Loading branch information
frozencemetery authored and greghudson committed Dec 9, 2019
1 parent ec12007 commit 3a32b06
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/lib/krb5/ccache/cc_kcm.c
Original file line number Diff line number Diff line change
Expand Up @@ -583,7 +583,7 @@ get_kdc_offset(krb5_context context, krb5_ccache cache)
if (cache_call(context, cache, &req, FALSE) != 0)
goto cleanup;
time_offset = k5_input_get_uint32_be(&req.reply);
if (!req.reply.status)
if (req.reply.status)
goto cleanup;
context->os_context.time_offset = time_offset;
context->os_context.usec_offset = 0;
Expand Down

0 comments on commit 3a32b06

Please sign in to comment.