summaryrefslogtreecommitdiff
path: root/source3/utils/net.c
diff options
context:
space:
mode:
authorJim McDonough <jmcd@samba.org>2002-01-25 22:07:46 +0000
committerJim McDonough <jmcd@samba.org>2002-01-25 22:07:46 +0000
commitde260eadf956cae8aeaebc2a84f46a57c0671741 (patch)
treee501595e49162ed81b27bad864a58df29c5a84e4 /source3/utils/net.c
parent9d8ed7220fed8a3b7ff9d45b9c5902c3255956ac (diff)
downloadsamba-de260eadf956cae8aeaebc2a84f46a57c0671741.tar.gz
samba-de260eadf956cae8aeaebc2a84f46a57c0671741.tar.bz2
samba-de260eadf956cae8aeaebc2a84f46a57c0671741.zip
Enable net ads commands to use existing tickets if the user doesn't specify a username on the commandline. Also don't continue past the kinit if a password is entered and fails because existing tickets would be used, which may not be desired if the username was specified.
(This used to be commit 7e5d7dfa834c0161460bde8a2f0d4824c0a0d1fe)
Diffstat (limited to 'source3/utils/net.c')
-rw-r--r--source3/utils/net.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/source3/utils/net.c b/source3/utils/net.c
index 89eb9211ca..81968e6f84 100644
--- a/source3/utils/net.c
+++ b/source3/utils/net.c
@@ -61,6 +61,7 @@ char *opt_requester_name = NULL;
char *opt_host = NULL;
char *opt_password = NULL;
char *opt_user_name = NULL;
+BOOL opt_user_specified = False;
char *opt_workgroup = NULL;
int opt_long_list_entries = 0;
int opt_reboot = 0;
@@ -394,6 +395,7 @@ static struct functable net_func[] = {
opt_have_ip = True;
break;
case 'U':
+ opt_user_specified = True;
opt_user_name = strdup(opt_user_name);
p = strchr(opt_user_name,'%');
if (p) {