diff --git a/lib/krb5/init_creds_pw.c b/lib/krb5/init_creds_pw.c index 4e378a333..e0301c176 100644 --- a/lib/krb5/init_creds_pw.c +++ b/lib/krb5/init_creds_pw.c @@ -246,7 +246,7 @@ init_cred (krb5_context context, if (options->flags & KRB5_GET_INIT_CREDS_OPT_TKT_LIFE) tmp = options->tkt_life; else - tmp = 10 * 60 * 60; + tmp = KRB5_TKT_LIFETIME_DEFAULT; cred->times.endtime = now + tmp; if ((options->flags & KRB5_GET_INIT_CREDS_OPT_RENEW_LIFE) && diff --git a/lib/krb5/krb5_locl.h b/lib/krb5/krb5_locl.h index 59fe38669..53549d291 100644 --- a/lib/krb5/krb5_locl.h +++ b/lib/krb5/krb5_locl.h @@ -356,6 +356,10 @@ typedef struct krb5_context_data { #define KRB5_FALLBACK_DEFAULT TRUE #endif +#ifndef KRB5_TKT_LIFETIME_DEFAULT +# define KRB5_TKT_LIFETIME_DEFAULT (10 * 60 * 60) /* 10 hours */ +#endif + #ifdef PKINIT struct krb5_pk_identity {