From e4202a9fe70785a0a5b47c90df696a880294d310 Mon Sep 17 00:00:00 2001 From: Andrew Bartlett Date: Sat, 15 Feb 2003 00:29:21 +0000 Subject: Antti Andreimann has done some changes to enable users w/o full administrative access on computer accounts to join a computer into AD domain. The patch and detailed changelog is available at: http://www.itcollege.ee/~aandreim/samba This is a list of changes in general: 1. When creating machine account do not fail if SD cannot be changed. setting SD is not mandatory and join will work perfectly without it. 2. Implement KPASSWD CHANGEPW protocol for changing trust password so machine account does not need to have reset password right for itself. 3. Command line utilities no longer interfere with user's existing kerberos ticket cache. 4. Command line utilities can do kerberos authentication even if username is specified (-U). Initial TGT will be requested in this case. I've modified the patch to share the kinit code, rather than copying it, and updated it to current CVS. The other change included in the original patch (local realms) has been left out for now. Andrew Bartlett (This used to be commit ce52f1c2ed4d3ddafe8ae6258c90b90fa434fe43) --- source3/torture/locktest.c | 5 ++++- source3/torture/torture.c | 4 +++- 2 files changed, 7 insertions(+), 2 deletions(-) (limited to 'source3/torture') diff --git a/source3/torture/locktest.c b/source3/torture/locktest.c index 5f9a63802b..63b9590dd6 100644 --- a/source3/torture/locktest.c +++ b/source3/torture/locktest.c @@ -24,6 +24,7 @@ static fstring password[2]; static fstring username[2]; +static int got_user; static int got_pass; static BOOL use_kerberos; static int numops = 1000; @@ -602,13 +603,13 @@ static void usage(void) case 'k': #ifdef HAVE_KRB5 use_kerberos = True; - got_pass = True; #else d_printf("No kerberos support compiled in\n"); exit(1); #endif break; case 'U': + got_user = 1; if (got_pass == 2) { d_printf("Max of 2 usernames\n"); exit(1); @@ -663,6 +664,8 @@ static void usage(void) } } + if(use_kerberos && !got_user) got_pass = True; + argc -= optind; argv += optind; diff --git a/source3/torture/torture.c b/source3/torture/torture.c index 56b8da768e..97e864de96 100644 --- a/source3/torture/torture.c +++ b/source3/torture/torture.c @@ -4082,6 +4082,7 @@ static void usage(void) { int opt, i; char *p; + int gotuser = 0; int gotpass = 0; extern char *optarg; extern int optind; @@ -4167,13 +4168,13 @@ static void usage(void) case 'k': #ifdef HAVE_KRB5 use_kerberos = True; - gotpass = True; #else d_printf("No kerberos support compiled in\n"); exit(1); #endif break; case 'U': + gotuser = 1; fstrcpy(username,optarg); p = strchr_m(username,'%'); if (p) { @@ -4188,6 +4189,7 @@ static void usage(void) } } + if(use_kerberos && !gotuser) gotpass = True; while (!gotpass) { p = getpass("Password:"); -- cgit