From e5291963a148c34582d90f2aa269e4a2214f9f6f Mon Sep 17 00:00:00 2001 From: Alexander Bokovoy Date: Mon, 17 Feb 2020 13:58:51 +0200 Subject: [PATCH] kdb: make sure audit_as_req callback signature change is preserved audit_as_req() callback has changed its signature with MIT krb5 commit 20991d55efbe1f987c1dbc1065f2d58c8f34031b in 2017, we should preserve the change for any newer DAL versions. Otherwise audit_as_req() callback would reference wrong data and we might crash. Fixes: https://pagure.io/freeipa/issue/8200 Signed-off-by: Alexander Bokovoy Reviewed-By: Christian Heimes --- daemons/ipa-kdb/ipa_kdb.h | 2 +- daemons/ipa-kdb/ipa_kdb_audit_as.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/daemons/ipa-kdb/ipa_kdb.h b/daemons/ipa-kdb/ipa_kdb.h index 7519f26e2..ae37a5a03 100644 --- a/daemons/ipa-kdb/ipa_kdb.h +++ b/daemons/ipa-kdb/ipa_kdb.h @@ -345,7 +345,7 @@ krb5_error_code ipadb_check_allowed_to_delegate(krb5_context kcontext, void ipadb_audit_as_req(krb5_context kcontext, krb5_kdc_req *request, -#if (KRB5_KDB_DAL_MAJOR_VERSION == 7) +#if (KRB5_KDB_DAL_MAJOR_VERSION >= 7) const krb5_address *local_addr, const krb5_address *remote_addr, #endif diff --git a/daemons/ipa-kdb/ipa_kdb_audit_as.c b/daemons/ipa-kdb/ipa_kdb_audit_as.c index 77748a75d..a60bc82b6 100644 --- a/daemons/ipa-kdb/ipa_kdb_audit_as.c +++ b/daemons/ipa-kdb/ipa_kdb_audit_as.c @@ -25,7 +25,7 @@ void ipadb_audit_as_req(krb5_context kcontext, krb5_kdc_req *request, -#if (KRB5_KDB_DAL_MAJOR_VERSION == 7) +#if (KRB5_KDB_DAL_MAJOR_VERSION >= 7) const krb5_address *local_addr, const krb5_address *remote_addr, #endif