<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:wfw="http://wellformedweb.org/CommentAPI/"
	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/"
	xmlns:slash="http://purl.org/rss/1.0/modules/slash/"
	>

<channel>
	<title>AD connector &#8211; Blog of Kliment Andreev &#8211; A place so I won&#039;t forget things</title>
	<atom:link href="https://blog.andreev.it/tag/ad-connector/feed/" rel="self" type="application/rss+xml" />
	<link>https://blog.andreev.it</link>
	<description></description>
	<lastBuildDate>Sat, 24 Oct 2020 13:31:54 +0000</lastBuildDate>
	<language>en-US</language>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	
	<item>
		<title>AWS: AD Connector &#8211; Use on-prem AD credentials to log to AWS</title>
		<link>https://blog.andreev.it/2017/09/113-aws-ad-connector-use-prem-ad-credentials-log-aws/</link>
					<comments>https://blog.andreev.it/2017/09/113-aws-ad-connector-use-prem-ad-credentials-log-aws/#comments</comments>
		
		<dc:creator><![CDATA[Kliment Andreev]]></dc:creator>
		<pubDate>Sun, 17 Sep 2017 13:49:36 +0000</pubDate>
				<category><![CDATA[AWS]]></category>
		<category><![CDATA[Cloud]]></category>
		<category><![CDATA[AD connector]]></category>
		<guid isPermaLink="false">http://blog.iandreev.com/?p=3209</guid>

					<description><![CDATA[In this post I&#8217;ll show you how to configure AD Connector, so you can&#8230;]]></description>
										<content:encoded><![CDATA[<div id="bsf_rt_marker"></div><p>In this post I&#8217;ll show you how to configure AD Connector, so you can use your on-prem AD users to log to the AWS Console. AD Connector can be used for other things as well. See the following <a href="http://docs.aws.amazon.com/directoryservice/latest/admin-guide/directory_ad_connector.html" target="_blank" rel="noopener noreferrer">link </a>for use cases. From the AWS documentation:</p>
<div style="border: 1px solid red; padding: 16px;">
<p style="text-align: center;"><i>AD Connector is a proxy service for connecting your on-premises Microsoft Active Directory to the AWS cloud without requiring complex directory synchronization or the cost and complexity of hosting a federation infrastructure.<br />
AD Connector forwards sign-in requests to your Active Directory domain controllers for authentication and provides the ability for applications to query the directory for data. After setup, your users can use their existing corporate credentials to log on to AWS applications, such as Amazon WorkSpaces, Amazon WorkDocs, or Amazon WorkMail. With the proper IAM permissions, they can also access the AWS Management Console and manage AWS resources such as Amazon EC2 instances or Amazon S3 buckets.When to use:<br />
Microsoft AD is your best choice if you have more than 5,000 users and need a trust relationship set up between an AWS hosted directory and your on-premises directories. For more information, see Microsoft Active Directory.</i></p>
</div>
<p>Before we begin, make sure that you have everything in place. Check the prerequisites from the following <a href="http://docs.aws.amazon.com/directoryservice/latest/admin-guide/prereq_connector.html" target="_blank" rel="noopener noreferrer">link</a>. There are quite conditions that you have to meet.<br />
The flow looks like this.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-01.png"><img fetchpriority="high" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-01.png" alt="" width="600" height="355" class="aligncenter size-full wp-image-7732" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-01.png 600w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-01-300x178.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-01-585x346.png 585w" sizes="(max-width: 600px) 100vw, 600px" /></a><br />
Also, I&#8217;ve followed this AWS <a href="http://docs.aws.amazon.com/directoryservice/latest/admin-guide/directory_ad_connector.html">link </a>to complete my AD Connector setup.</p>
<h1>AD setup</h1>
<p>Fire up the AD Users and Computers program on your computer on-prem and create a new AD group. It has to be <strong>Global </strong>and a <strong>Security </strong>group. Once created, right-click on your domain name on top and choose <strong>Delegate Control</strong>. Type the name of the group that you&#8217;ve just created and then on the <strong>Tasks to Delegate</strong> page select <strong>Create a custom task to delegate</strong>. Click on <strong>Only the following objects in the folder</strong>, and then select <strong>Computer objects</strong> and <strong>User objects</strong>. Click on <strong>Create selected objects in this folder</strong> and <strong>Delete selected objects in this folder</strong> at the bottom.</p>
<p><a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-02.png"><img decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-02.png" alt="" width="503" height="355" class="aligncenter size-full wp-image-7733" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-02.png 503w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-02-300x212.png 300w" sizes="(max-width: 503px) 100vw, 503px" /></a><br />
Click Next and on the following screen, click on <strong>General</strong> and <strong>Property Specific</strong> check marks and then click on <strong>Read </strong>and <strong>Write</strong>.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-03.png"><img decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-03.png" alt="" width="484" height="256" class="aligncenter size-full wp-image-7734" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-03.png 484w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-03-300x159.png 300w" sizes="(max-width: 484px) 100vw, 484px" /></a></p>
<p>Review the changes and click <strong>Finish</strong>.<br />
Now, create a user and add that user to the AD group that you&#8217;ve just created. This user will be responsible for the connection between the AD Connector and your on-prem AD. Make sure your user&#8217;s password does not expire.</p>
<h1>AWS pre-setup</h1>
<p>You will have to verify the connection between AWS and your on-prem. AWS documentation recommends that you build or use an existing Windows server, but you can also use some other OS to test the ports. All you have to do is to check if the following ports are open:</p>
<ul>
<li><strong>TCP: 53,88,135,389,445,3268,5722,938<br />
</strong></li>
<li><strong>UDP: 53,88,123,138,389,445</strong></li>
</ul>
<p>In my case, I had an existing Windows server that I had to join it to the domain. Then, I had to download a small program from this <a href="http://docs.aws.amazon.com/directoryservice/latest/admin-guide/samples/DirectoryServicePortTest.zip" target="_blank" rel="noopener noreferrer">link</a>. Unzip the archive and execute the .EXE file as the following command.</p>
<pre class="brush: bash; title: ; notranslate">
DirectoryServicePortTest.exe -d &lt;domain_name&gt; -ip &lt;server_IP_address&gt; -tcp &quot;53,88,135,389,445,3268,5722,9389&quot; -udp &quot;53,88,123,138,389,445&quot;
</pre>
<p>Replace your <strong>domain_name</strong> with your FQDN e.g. in my case it&#8217;s andreev.local and the <strong>server_IP_address</strong> with an IP of one of your domain controllers. This is the output of my test.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-04.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-04.png" alt="" width="973" height="439" class="aligncenter size-full wp-image-7735" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-04.png 973w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-04-300x135.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-04-768x347.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-04-585x264.png 585w" sizes="(max-width: 973px) 100vw, 973px" /></a><br />
Make sure all ports show as PASSED. In my case, port <strong>5722 (RPC, DFSR (SYSVOL))</strong> shows as failed, but that&#8217;s OK as long as your domain controller is 2012 and up.</p>
<h1>AWS AD Connector</h1>
<p>Go to your AWS console and look for <strong>Directory Services</strong>. Once there, scroll all the way to the bottom where you can see AD Connector. Do not use Microsoft AD, that&#8217;s something different.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-05.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-05.png" alt="" width="571" height="114" class="aligncenter size-full wp-image-7736" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-05.png 571w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-05-300x60.png 300w" sizes="(max-width: 571px) 100vw, 571px" /></a><br />
When you create the connector, you&#8217;ll have to enter these values. </p>
<p><a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-06.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-06.png" alt="" width="1045" height="553" class="aligncenter size-full wp-image-7737" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-06.png 1045w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-06-300x159.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-06-1024x542.png 1024w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-06-768x406.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-06-585x310.png 585w" sizes="(max-width: 1045px) 100vw, 1045px" /></a></p>
<p>In my case, my domain is andreev.local with NetBIOS name ANDREEV. The AD user that we created before and added it to that AWS AD group is called adconnector. Enter the IPs of the two domain controllers and choose the size (Small/Large).<br />
Finally, choose the VPC and two subnets in different availability zones (AZ). The default worked fine for me.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-07.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-07.png" alt="" width="1048" height="362" class="aligncenter size-full wp-image-7738" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-07.png 1048w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-07-300x104.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-07-1024x354.png 1024w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-07-768x265.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-07-585x202.png 585w" sizes="(max-width: 1048px) 100vw, 1048px" /></a></p>
<p>Click <strong>Next</strong>, review and click on <strong>Create</strong>. Wait for about 10 mins until the status turns from <strong>Pending </strong>to <strong>Active</strong>. The price of small AD Connector is about $288 a month which is quite expensive for me, so I&#8217;ve deleted the connector right after I finished my lab.<br />
This is how it will look like after 10 mins and if everything is OK. </p>
<p><a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-08.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-08.png" alt="" width="1126" height="212" class="aligncenter size-full wp-image-7739" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-08.png 1126w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-08-300x56.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-08-1024x193.png 1024w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-08-768x145.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-08-585x110.png 585w" sizes="(max-width: 1126px) 100vw, 1126px" /></a></p>
<h1>AWS Console use case</h1>
<p>As I said earlier, AD Connector can be use for many cases, but I&#8217;ll demonstrate the AWS Console access only and how to join a server to the domain. Click on the AD Connector ID and you&#8217;ll see this.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-09.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-09.png" alt="" width="1104" height="499" class="aligncenter size-full wp-image-7740" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-09.png 1104w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-09-300x136.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-09-1024x463.png 1024w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-09-768x347.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-09-585x264.png 585w" sizes="(max-width: 1104px) 100vw, 1104px" /></a><br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-10.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-10.png" alt="" width="1166" height="502" class="aligncenter size-full wp-image-7741" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-10.png 1166w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-10-300x129.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-10-1024x441.png 1024w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-10-768x331.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-10-585x252.png 585w" sizes="(max-width: 1166px) 100vw, 1166px" /></a> </p>
<p>All the way at the bottom, click on <strong>AWS Management Console</strong> and enable access. You&#8217;ll be prompted to enter an URL so that&#8217;s how you will access your AWS console. In my case, I chose <strong>andreev.awsapps.com</strong>. If you click on the <strong>AWS Management Console</strong> link again, it will prompt you to select a Role and assign some users.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-11.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-11.png" alt="" width="1008" height="549" class="aligncenter size-full wp-image-7742" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-11.png 1008w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-11-300x163.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-11-768x418.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-11-585x319.png 585w" sizes="(max-width: 1008px) 100vw, 1008px" /></a></p>
<p>Most likely, you don&#8217;t have any roles or AD users ready, so go ahead and create a new AD user or AD group that will have access to Glacier only. Then, open a new tab in your browser and log to your AWS console and go to IAM. Create a new Role. Choose Directory Services as shown. </p>
<p><a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-12.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-12.png" alt="" width="974" height="584" class="aligncenter size-full wp-image-7743" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-12.png 974w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-12-300x180.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-12-768x460.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-12-585x351.png 585w" sizes="(max-width: 974px) 100vw, 974px" /></a><br />
On the next screen, type <strong>glacier </strong>and select the first policy (<strong>AmazonGlacierFullAccess</strong>).<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-13.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-13.png" alt="" width="988" height="675" class="aligncenter size-full wp-image-7744" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-13.png 988w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-13-300x205.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-13-768x525.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-13-585x400.png 585w" sizes="(max-width: 988px) 100vw, 988px" /></a></p>
<p>Name the role and click <strong>Create</strong>. </p>
<p><a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-14.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-14.png" alt="" width="806" height="494" class="aligncenter size-full wp-image-7745" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-14.png 806w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-14-300x184.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-14-768x471.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-14-585x359.png 585w" sizes="(max-width: 806px) 100vw, 806px" /></a></p>
<p>Go back to the other tab with the AD Connector and click Refresh on the right so the new role shows up.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-15.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-15.png" alt="" width="1241" height="417" class="aligncenter size-full wp-image-7746" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-15.png 1241w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-15-300x101.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-15-1024x344.png 1024w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-15-768x258.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-15-1170x393.png 1170w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-15-585x197.png 585w" sizes="(max-width: 1241px) 100vw, 1241px" /></a><br />
Click on the newly created role, then click <strong>Add </strong>when this screen shows up.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-16.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-16.png" alt="" width="1255" height="312" class="aligncenter size-full wp-image-7747" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-16.png 1255w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-16-300x75.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-16-1024x255.png 1024w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-16-768x191.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-16-1170x291.png 1170w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-16-585x145.png 585w" sizes="(max-width: 1255px) 100vw, 1255px" /></a><br />
Start typing the AD user or group that you just created for Glacier access and click <strong>Add</strong>.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-17.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-17.png" alt="" width="1004" height="639" class="aligncenter size-full wp-image-7748" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-17.png 1004w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-17-300x191.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-17-768x489.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-17-585x372.png 585w" sizes="(max-width: 1004px) 100vw, 1004px" /></a></p>
<p>Now, you can open a new tab in your browser, go to your new AWS console access URL (e.g. andreev.awsapps.com/console) and log with your AD credentials. No need to type your domain name. Just use your AD account and password.<br />
Another useful case that you already have by configuring AD Connector is that when you provision a new Windows instance, you can automatically join it to the domain. Just select the domain name when it prompts for the other settings.<br />
<a href="https://blog.andreev.it/wp-content/uploads/2017/09/P091-18.png"><img loading="lazy" decoding="async" src="https://blog.andreev.it/wp-content/uploads/2017/09/P091-18.png" alt="" width="1001" height="640" class="aligncenter size-full wp-image-7749" srcset="https://blog.andreev.it/wp-content/uploads/2017/09/P091-18.png 1001w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-18-300x192.png 300w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-18-768x491.png 768w, https://blog.andreev.it/wp-content/uploads/2017/09/P091-18-585x374.png 585w" sizes="(max-width: 1001px) 100vw, 1001px" /></a></p>
]]></content:encoded>
					
					<wfw:commentRss>https://blog.andreev.it/2017/09/113-aws-ad-connector-use-prem-ad-credentials-log-aws/feed/</wfw:commentRss>
			<slash:comments>2</slash:comments>
		
		
			</item>
	</channel>
</rss>
