From 286b215bd829075f04576b65d55993fdc8e11b47 Mon Sep 17 00:00:00 2001 From: Greg Hudson Date: Mon, 31 Oct 2011 16:43:40 +0000 Subject: Make krb5_check_clockskew public Rename krb5int_check_clockskew to krb5_check_clockskew and make it public, in order to give kdcpreauth plugins a way to check timestamps against the configured clock skew. ticket: 6996 target_version: 1.10 tags: pullup git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@25424 dc483132-0cff-0310-8789-dd5450dbe970 --- src/include/k5-int.h | 1 - src/include/krb5/krb5.hin | 15 +++++++++++++++ 2 files changed, 15 insertions(+), 1 deletion(-) (limited to 'src/include') diff --git a/src/include/k5-int.h b/src/include/k5-int.h index 92cbe87f5..fec4a7f80 100644 --- a/src/include/k5-int.h +++ b/src/include/k5-int.h @@ -2693,7 +2693,6 @@ krb5_error_code krb5_set_debugging_time(krb5_context, krb5_timestamp, krb5_error_code krb5_use_natural_time(krb5_context); krb5_error_code krb5_set_time_offsets(krb5_context, krb5_timestamp, krb5_int32); -krb5_error_code krb5int_check_clockskew(krb5_context, krb5_timestamp); /* * The realm iterator functions */ diff --git a/src/include/krb5/krb5.hin b/src/include/krb5/krb5.hin index 28f83d5ae..5f667cee2 100644 --- a/src/include/krb5/krb5.hin +++ b/src/include/krb5/krb5.hin @@ -4749,6 +4749,21 @@ krb5_us_timeofday(krb5_context context, krb5_error_code KRB5_CALLCONV krb5_timeofday(krb5_context context, register krb5_timestamp *timeret); +/** + * Check if a timestamp is within the allowed clock skew of the current time. + * + * @param [in] context Library context + * @param [in] date Timestamp to check + * + * This function checks if @a date is close enough to the current time + * according to the configured allowable clock skew. + * + * @retval 0 Success + * @retval KRB5KRB_AP_ERR_SKEW @a date is not within allowable clock skew + */ +krb5_error_code KRB5_CALLCONV +krb5_check_clockskew(krb5_context context, krb5_timestamp date); + /** * Return all interface addresses for this host. * -- cgit