svn commit: samba r10803 - in branches/SAMBA_4_0/source/torture/rpc: .

abartlet at samba.org abartlet at samba.org
Fri Oct 7 06:25:46 GMT 2005


Author: abartlet
Date: 2005-10-07 06:25:45 +0000 (Fri, 07 Oct 2005)
New Revision: 10803

WebSVN: http://websvn.samba.org/cgi-bin/viewcvs.cgi?view=rev&root=samba&rev=10803

Log:
Remove a duplicate krbtgt test, and add a test looking for the
'support account'.  This shows that we need to be searching on
displayName, and probably CN too.

Andrew Bartlett

Modified:
   branches/SAMBA_4_0/source/torture/rpc/drsuapi.c


Changeset:
Modified: branches/SAMBA_4_0/source/torture/rpc/drsuapi.c
===================================================================
--- branches/SAMBA_4_0/source/torture/rpc/drsuapi.c	2005-10-07 04:54:41 UTC (rev 10802)
+++ branches/SAMBA_4_0/source/torture/rpc/drsuapi.c	2005-10-07 06:25:45 UTC (rev 10803)
@@ -526,9 +526,9 @@
 		return False;
 	}
 
-	r.in.req.req1.format_offered	= DRSUAPI_DS_NAME_FORMAT_SERVICE_PRINCIPAL;
-	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_FQDN_1779;
-	names[0].str = talloc_asprintf(mem_ctx, "krbtgt/%s", dns_domain);
+	r.in.req.req1.format_offered	= DRSUAPI_DS_NAME_FORMAT_FQDN_1779;
+	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_CANONICAL;
+	names[0].str = FQDN_1779_name;
 
 	printf("testing DsCrackNames with name '%s' desired format:%d\n",
 			names[0].str, r.in.req.req1.format_desired);
@@ -544,7 +544,7 @@
 	} else if (!W_ERROR_IS_OK(r.out.result)) {
 		printf("DsCrackNames failed - %s\n", win_errstr(r.out.result));
 		ret = False;
-	} else if (r.out.ctr.ctr1->array[0].status != DRSUAPI_DS_NAME_STATUS_DOMAIN_ONLY) {
+	} else if (r.out.ctr.ctr1->array[0].status != DRSUAPI_DS_NAME_STATUS_OK) {
 		printf("DsCrackNames failed on name - %d\n", r.out.ctr.ctr1->array[0].status);
 		ret = False;
 	}
@@ -553,9 +553,7 @@
 		return ret;
 	}
 
-	r.in.req.req1.format_offered	= DRSUAPI_DS_NAME_FORMAT_FQDN_1779;
-	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_CANONICAL;
-	names[0].str = FQDN_1779_name;
+	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_DISPLAY;
 
 	printf("testing DsCrackNames with name '%s' desired format:%d\n",
 			names[0].str, r.in.req.req1.format_desired);
@@ -580,7 +578,7 @@
 		return ret;
 	}
 
-	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_DISPLAY;
+	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_GUID;
 
 	printf("testing DsCrackNames with name '%s' desired format:%d\n",
 			names[0].str, r.in.req.req1.format_desired);
@@ -605,9 +603,11 @@
 		return ret;
 	}
 
-	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_GUID;
+	r.in.req.req1.format_offered	= DRSUAPI_DS_NAME_FORMAT_DISPLAY;
+	r.in.req.req1.format_desired	= DRSUAPI_DS_NAME_FORMAT_FQDN_1779;
+	names[0].str = "CN=Microsoft Corporation,L=Redmond,S=Washington,C=US";
 
-	printf("testing DsCrackNames with name '%s' desired format:%d\n",
+	printf("testing DsCrackNames with DISPAY NAME '%s' desired format:%d\n",
 			names[0].str, r.in.req.req1.format_desired);
 
 	status = dcerpc_drsuapi_DsCrackNames(p, mem_ctx, &r);



More information about the samba-cvs mailing list