<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
		>
<channel>
	<title>Comments on: Listing all domains in a forest</title>
	<atom:link href="http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/feed/" rel="self" type="application/rss+xml" />
	<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/</link>
	<description></description>
	<lastBuildDate>Wed, 21 Dec 2011 09:33:35 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.3.1</generator>
	<item>
		<title>By: Sergio</title>
		<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/comment-page-1/#comment-741</link>
		<dc:creator>Sergio</dc:creator>
		<pubDate>Fri, 09 Sep 2011 11:36:15 +0000</pubDate>
		<guid isPermaLink="false">http://www.highorbit.co.uk/?p=310#comment-741</guid>
		<description>Nice job!

Joining your vbscript with Remko job (http://www.remkoweijnen.nl/blog/2007/11/01/query-active-directory-from-excel/) I&#039;ve done this VBA function: http://serio72.altervista.org/blog/wp-content/uploads/2011/09/GetAdsPropGL.txt 

Tnx!</description>
		<content:encoded><![CDATA[<p>Nice job!</p>
<p>Joining your vbscript with Remko job (<a href="http://www.remkoweijnen.nl/blog/2007/11/01/query-active-directory-from-excel/" rel="nofollow">http://www.remkoweijnen.nl/blog/2007/11/01/query-active-directory-from-excel/</a>) I&#8217;ve done this VBA function: <a href="http://serio72.altervista.org/blog/wp-content/uploads/2011/09/GetAdsPropGL.txt" rel="nofollow">http://serio72.altervista.org/blog/wp-content/uploads/2011/09/GetAdsPropGL.txt</a> </p>
<p>Tnx!</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris</title>
		<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/comment-page-1/#comment-697</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Thu, 09 Jun 2011 18:03:22 +0000</pubDate>
		<guid isPermaLink="false">http://www.highorbit.co.uk/?p=310#comment-697</guid>
		<description>Remote connectivity requires a server to bind to as well. e.g.
[code lang=&quot;vb&quot;]
Dim RootDSE As New DirectoryEntry(&quot;LDAP://server.domain.com/rootDSE&quot;)
[/code]
All of the existing examples use Serverless Binding which, in turn, uses the DCLocator algorithm to locate servers.

Chris</description>
		<content:encoded><![CDATA[<p>Remote connectivity requires a server to bind to as well. e.g.</p>
<pre class="brush: vb; title: ; notranslate">
Dim RootDSE As New DirectoryEntry(&quot;LDAP://server.domain.com/rootDSE&quot;)
</pre>
<p>All of the existing examples use Serverless Binding which, in turn, uses the DCLocator algorithm to locate servers.</p>
<p>Chris</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Jet</title>
		<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/comment-page-1/#comment-692</link>
		<dc:creator>Jet</dc:creator>
		<pubDate>Tue, 31 May 2011 07:08:14 +0000</pubDate>
		<guid isPermaLink="false">http://www.highorbit.co.uk/?p=310#comment-692</guid>
		<description>Hello!
I know this is a bit old, but i&#039;ll try my luck... since few days ago i&#039;m trying to connect remotely to my ad with no luck. All what i&#039;d found works fine if run my vb.net app whithin the LAN, when i need to do it from outside it just doesn&#039;t work at all.  No matter what or how i set in the path it doesn&#039;t work.
Can some one please help me with the right sintax to connect to a remote ad?
Thanks a lot.
Jet</description>
		<content:encoded><![CDATA[<p>Hello!<br />
I know this is a bit old, but i&#8217;ll try my luck&#8230; since few days ago i&#8217;m trying to connect remotely to my ad with no luck. All what i&#8217;d found works fine if run my vb.net app whithin the LAN, when i need to do it from outside it just doesn&#8217;t work at all.  No matter what or how i set in the path it doesn&#8217;t work.<br />
Can some one please help me with the right sintax to connect to a remote ad?<br />
Thanks a lot.<br />
Jet</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Chris</title>
		<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/comment-page-1/#comment-342</link>
		<dc:creator>Chris</dc:creator>
		<pubDate>Fri, 02 Jul 2010 10:46:17 +0000</pubDate>
		<guid isPermaLink="false">http://www.highorbit.co.uk/?p=310#comment-342</guid>
		<description>Thanks! Fixed the example.

Chris</description>
		<content:encoded><![CDATA[<p>Thanks! Fixed the example.</p>
<p>Chris</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Ian Walker</title>
		<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/comment-page-1/#comment-341</link>
		<dc:creator>Ian Walker</dc:creator>
		<pubDate>Fri, 02 Jul 2010 10:43:53 +0000</pubDate>
		<guid isPermaLink="false">http://www.highorbit.co.uk/?p=310#comment-341</guid>
		<description>In the VBScript code, the query on line 12 will fail with a &quot;Table does not exist&quot; error unless &quot;LDAP&quot; is in upper case.

Otherwise, thanks for this, saved me an hour writing it from scratch.</description>
		<content:encoded><![CDATA[<p>In the VBScript code, the query on line 12 will fail with a &#8220;Table does not exist&#8221; error unless &#8220;LDAP&#8221; is in upper case.</p>
<p>Otherwise, thanks for this, saved me an hour writing it from scratch.</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Daniel Wernle</title>
		<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/comment-page-1/#comment-15</link>
		<dc:creator>Daniel Wernle</dc:creator>
		<pubDate>Mon, 24 Nov 2008 13:46:52 +0000</pubDate>
		<guid isPermaLink="false">http://www.highorbit.co.uk/?p=310#comment-15</guid>
		<description>A slightly different way to do it is over a search of the trusted Domains. needed it some time ago to search on different domains in a forrest and fill up objects with the &quot;Domain\\Username&quot; notation ...
[code lang=&quot;csharp&quot;]
///
/// Gets All Trusted Domains in the Domain Forrest
///
public Dictionary GetDomains()
{
    SearchResultCollection srCollection;
    DirectoryEntry deRoot = new DirectoryEntry(@&quot;LDAP://eu.infineon.com:389/DC=infineon,DC=com&quot;);
            DirectorySearcher deSearcher = new DirectorySearcher(deRoot);
            deSearcher.Filter = (&quot;(objectClass=trustedDomain)&quot;);
            deSearcher.PageSize = 1000;
            deSearcher.SearchScope = SearchScope.Subtree;
            srCollection = deSearcher.FindAll();

            //ArrayList DomainList = new ArrayList();
            Dictionary DomainList = new Dictionary();

            foreach (SearchResult se in srCollection)
            {
                string currentDomainName = se.GetDirectoryEntry().Name.ToString();
                string currentNomainFlatName = se.GetDirectoryEntry().Properties[&quot;flatname&quot;].Value.ToString();
                currentDomainName = currentDomainName.Replace(&quot;.&quot;, &quot;,DC=&quot;);
                currentDomainName = currentDomainName.Replace(&quot;CN&quot;, &quot;DC&quot;);
                DomainList.Add(currentDomainName,currentNomainFlatName);
            }

            return DomainList;
        }
[/code]
nice article, thx</description>
		<content:encoded><![CDATA[<p>A slightly different way to do it is over a search of the trusted Domains. needed it some time ago to search on different domains in a forrest and fill up objects with the &#8220;Domain\\Username&#8221; notation &#8230;</p>
<pre class="brush: csharp; title: ; notranslate">
///
/// Gets All Trusted Domains in the Domain Forrest
///
public Dictionary GetDomains()
{
    SearchResultCollection srCollection;
    DirectoryEntry deRoot = new DirectoryEntry(@&quot;LDAP://eu.infineon.com:389/DC=infineon,DC=com&quot;);
            DirectorySearcher deSearcher = new DirectorySearcher(deRoot);
            deSearcher.Filter = (&quot;(objectClass=trustedDomain)&quot;);
            deSearcher.PageSize = 1000;
            deSearcher.SearchScope = SearchScope.Subtree;
            srCollection = deSearcher.FindAll();

            //ArrayList DomainList = new ArrayList();
            Dictionary DomainList = new Dictionary();

            foreach (SearchResult se in srCollection)
            {
                string currentDomainName = se.GetDirectoryEntry().Name.ToString();
                string currentNomainFlatName = se.GetDirectoryEntry().Properties[&quot;flatname&quot;].Value.ToString();
                currentDomainName = currentDomainName.Replace(&quot;.&quot;, &quot;,DC=&quot;);
                currentDomainName = currentDomainName.Replace(&quot;CN&quot;, &quot;DC&quot;);
                DomainList.Add(currentDomainName,currentNomainFlatName);
            }

            return DomainList;
        }
</pre>
<p>nice article, thx</p>
]]></content:encoded>
	</item>
	<item>
		<title>By: Oleg</title>
		<link>http://www.indented.co.uk/index.php/2008/10/21/listing-all-domains-in-a-forest/comment-page-1/#comment-16</link>
		<dc:creator>Oleg</dc:creator>
		<pubDate>Sun, 09 Nov 2008 08:24:12 +0000</pubDate>
		<guid isPermaLink="false">http://www.highorbit.co.uk/?p=310#comment-16</guid>
		<description>Hi, thank you for the scripts.
I tried PS and c# codes. They retrieve only one domain in my environment.
But I have 6 domains, if I open my Network Places-&gt;Microsoft Windows Networks I see them.
Also, I can retrieve 6 items when I use this code
[code lang=&quot;csharp&quot;]
DirectoryEntry rootEntry = new DirectoryEntry(&quot;WinNT:&quot;);
foreach (DirectoryEntry child in rootEntry.Children)
{
   listBox1.Items.Add(child.Name);
}
[/code]
But I&#039;d like ot use LDAP because of WinNT is legacy provider.
Thanks.</description>
		<content:encoded><![CDATA[<p>Hi, thank you for the scripts.<br />
I tried PS and c# codes. They retrieve only one domain in my environment.<br />
But I have 6 domains, if I open my Network Places-&gt;Microsoft Windows Networks I see them.<br />
Also, I can retrieve 6 items when I use this code</p>
<pre class="brush: csharp; title: ; notranslate">
DirectoryEntry rootEntry = new DirectoryEntry(&quot;WinNT:&quot;);
foreach (DirectoryEntry child in rootEntry.Children)
{
   listBox1.Items.Add(child.Name);
}
</pre>
<p>But I&#8217;d like ot use LDAP because of WinNT is legacy provider.<br />
Thanks.</p>
]]></content:encoded>
	</item>
</channel>
</rss>

