From 8aa6f3460bc0b1a5cf29b6958f508735b5e82999 Mon Sep 17 00:00:00 2001
From: Sumit Bose <sbose@redhat.com>
Date: Thu, 27 Nov 2014 13:42:19 +0100
Subject: [PATCH 120/128] krb5: do not fail if checking the old ccache failed
https://fedorahosted.org/sssd/ticket/2510
Reviewed-by: Jakub Hrozek <jhrozek@redhat.com>
---
Makefile.am | 1 +
src/providers/krb5/krb5_child.c | 7 +++++--
2 files changed, 6 insertions(+), 2 deletions(-)
diff --git a/Makefile.am b/Makefile.am
index 56a562c761d39ff5f54bc034ede563c40bf21ef8..130c647e51d3554b2b0f69e83f17b38f1366eb3b 100644
--- a/Makefile.am
+++ b/Makefile.am
@@ -2505,6 +2505,7 @@ krb5_child_SOURCES = \
src/util/signal.c \
src/util/strtonum.c \
src/util/become_user.c \
+ src/util/util_errors.c \
src/sss_client/common.c \
$(NULL)
krb5_child_CFLAGS = \
diff --git a/src/providers/krb5/krb5_child.c b/src/providers/krb5/krb5_child.c
index 94cd34e433cf6a197860d233fbf9ca30cd3eb535..d828dd550251d70851edcdc6b1eda6f5c051baf2 100644
--- a/src/providers/krb5/krb5_child.c
+++ b/src/providers/krb5/krb5_child.c
@@ -34,6 +34,7 @@
#include "util/user_info_msg.h"
#include "util/child_common.h"
#include "util/find_uid.h"
+#include "src/util/util_errors.h"
#include "providers/dp_backend.h"
#include "providers/krb5/krb5_auth.h"
#include "providers/krb5/krb5_utils.h"
@@ -2039,8 +2040,10 @@ static int k5c_ccache_setup(struct krb5_req *kr, uint32_t offline)
ret = k5c_check_old_ccache(kr);
if (ret != 0) {
- DEBUG(SSSDBG_OP_FAILURE, "Cannot check old ccache\n");
- return ret;
+ DEBUG(SSSDBG_CRIT_FAILURE, "Cannot check old ccache [%s]: [%d][%s]. " \
+ "Assuming old cache is invalid " \
+ "and not used.\n",
+ kr->old_ccname, ret, sss_strerror(ret));
}
/* Pre-creating the ccache must be done as root, otherwise we can't mkdir
--
1.9.3