add change-defaults
git-svn-id: svn://svn.h5l.se/heimdal/trunk/heimdal@24934 ec53bebd-3082-4978-b11e-865c3cabbd6b
This commit is contained in:
@@ -62,6 +62,7 @@ char *renew_life = NULL;
|
||||
char *server_str = NULL;
|
||||
char *cred_cache = NULL;
|
||||
char *start_str = NULL;
|
||||
static int switch_cache_flags = 1;
|
||||
struct getarg_strings etype_str;
|
||||
int use_keytab = 0;
|
||||
char *keytab_str = NULL;
|
||||
@@ -187,6 +188,9 @@ static struct getargs args[] = {
|
||||
NP_("NTLM domain", ""), "domain" },
|
||||
#endif
|
||||
|
||||
{ "change-default", 0, arg_negative_flag, &switch_cache_flags,
|
||||
NP_("switch the default cache to the new credentials cache", "") },
|
||||
|
||||
{ "ok-as-delegate", 0, arg_flag, &ok_as_delegate_flag,
|
||||
NP_("honor ok-as-delegate on tickets", "") },
|
||||
|
||||
@@ -642,6 +646,9 @@ get_new_tickets(krb5_context context,
|
||||
if (ret)
|
||||
krb5_err (context, 1, ret, "krb5_cc_move");
|
||||
|
||||
if (switch_cache_flags)
|
||||
krb5_cc_switch(context, ccache);
|
||||
|
||||
#ifndef NO_NTLM
|
||||
if (ntlm_domain && ntlmkey.data)
|
||||
store_ntlmkey(context, ccache, ntlm_domain, &ntlmkey);
|
||||
|
Reference in New Issue
Block a user