From 6d34f76f8692e43403a8bda51d057063b52f362a Mon Sep 17 00:00:00 2001 From: Stefan Metzmacher Date: Tue, 5 Dec 2006 11:08:53 +0000 Subject: r20039: things which need to be done for unbecoming a dc metze (This used to be commit 73f7e2d5b3b3ae767644b96ff9783642aac153d0) --- source4/torture/rpc/testjoin.c | 122 ++++++++++++++++++++++++++++++++++++++++- 1 file changed, 121 insertions(+), 1 deletion(-) (limited to 'source4/torture') diff --git a/source4/torture/rpc/testjoin.c b/source4/torture/rpc/testjoin.c index fa92f2e844..1102d8c55b 100644 --- a/source4/torture/rpc/testjoin.c +++ b/source4/torture/rpc/testjoin.c @@ -1010,7 +1010,7 @@ struct test_join_ads_dc *torture_join_domain_ads_dc(const char *machine_name, */ /* - * LDAP unbind in the 1st LDAP connection + * LDAP unbind on the 1st LDAP connection */ /* @@ -1062,6 +1062,126 @@ struct test_join_ads_dc *torture_join_domain_ads_dc(const char *machine_name, void torture_leave_domain_ads_dc(struct test_join_ads_dc *join) { +/* W2K3: */ + /* + * lookup DC: + * - using nbt name<1C> request and a samlogon mailslot request + * or + * - using a DNS SRV _ldap._tcp.dc._msdcs. request and a CLDAP netlogon request + */ + /* + * Open 1st LDAP connection to the DC using admin credentials + */ + + /* + * LDAP search 1st LDAP connection: + * + * Request: + * basedn: "" + * scope: base + * filter: (objectClass=*) + * attrs: defaultNamingContext + * configurationNamingContext + * Result: + * "" + * defaultNamingContext: + * configurationNamingContext:CN=Configuration, + */ + + /* + * LDAP search 1st LDAP connection: + * + * Request: + * basedn: + * scope: sub + * filter: (&(|(objectClass=user)(objectClass=computer))(sAMAccountName=)) + * attrs: distinguishedName + * userAccountControl + * Result: + * CN=,CN=Domain Controllers, + * distinguishedName: CN=,CN=Domain Controllers, + * userAccoountControl: 532480 <0x82000> + */ + + /* + * LDAP search 1st LDAP connection: + * + * Request: + * basedn: CN=,CN=Computers, + * scope: base + * filter: (objectClass=*) + * attrs: userAccountControl + * Result: + * CN=,CN=Computers, + * userAccoountControl: 532480 <0x82000> + */ + + /* + * LDAP modify 1st LDAP connection: + * + * Request (replace): + * CN=,CN=Computers, + * userAccoountControl: 4096 <0x1000> + * Result: + * + */ + + /* + * LDAP search 1st LDAP connection: + * + * Request: + * basedn: > + * scope: base + * filter: (objectClass=*) + * attrs: 1.1 + * Result: + * CN=Computers, + */ + + /* + * LDAP search 1st LDAP connection: + * + * Request: + * basedn: CN=Computers, + * scope: base + * filter: (objectClass=*) + * attrs: distinguishedName + * Result: + * CN=Computers, + * distinguishedName: CN=Computers, + */ + + /* + * LDAP modifyRDN 1st LDAP connection: + * + * Request: + * entry: CN=,CN=Domain Controllers, + * newrdn: CN= + * deleteoldrdn: TRUE + * newparent: CN=Computers, + * Result: + * + */ + + /* + * LDAP unbind on the 1st LDAP connection + */ + + /* + * Open 1st DRSUAPI connection to the DC using admin credentials + * DsBind with DRSUAPI_DS_BIND_GUID ("e24d201a-4fd6-11d1-a3da-0000f875ae0d") + */ + + /* + * DsRemoveDsServer to remove the + * CN=,CN=Servers,CN=,CN=Configuration, + * and CN=NTDS Settings,CN=,CN=Servers,CN=,CN=Configuration, + * on the 1st DRSUAPI connection + */ + + /* + * DsUnbind on the 1st DRSUAPI connection + */ if (join->join) { torture_leave_domain(join->join); -- cgit