If you follow me on Linkedin, you will know that I joined Microsoft was an FTE in February of 2019. As a result of this I will no longer be posting new technical content here. I intend to keep the blog live as it still gains strong unique visitor figures.
Wednesday, 30 January 2019
You might run into some node-level trust issues if you are trying to configure an NLB cluster for the Web Application Proxy role.
The best practice from Microsoft states that any servers running the Web Application Proxy role should reside in a DMZ network and not be domain joined. This brings it's own set of issues as the nodes don't automatically trust each other.
Gone are the days of creating two local administrator accounts on two non-domain joined hosts with the same password and praying it "passes through" authentication requests. Although we are still going to do this, a few other steps must be completed for it to work.
If you are configuring an NLB cluster on none domain joined nodes, you will probably be faced with "Access Denied" when you attempt to add the second host to the already existent cluster. This is even if you have matching local administrator credentials on both machines. I'm led to believe this is due to later versions of Windows inspecting the local SID's of user accounts instead of the username string.
To resolve this do the following -
- Create a new DWORD entry for LocalAccountTokenFilterPolicy in the registry of both nodes, this disables certain parts of UAC. The registry path is HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\CurrentVersion\Policies\System and for clarity the new entry should be a DWORD set to decimal and the value of 1.
- Configure the Trusted Hosts store on each of the nodes and create an entry for each server on each node. All the info on this can be found here http://winintro.ru/windowspowershell2corehelp.en/html/f23b65e2-c608-485d-95f5-a8c20e00f1fc.htm
- Configure (from NLB Manager) Options > Credentials on both servers with the local admin account that has been created on each of the servers.
- Configure the NLB cluster using node IP's and not DNS names (even if you have DNS names configured with the hosts file, I've found IP's seem to work better in a none domain joined NLB cluster).
Tuesday, 22 January 2019
DirectAccess reports Error: there is no valid certificate to be used by IPsec which chains to the root/intermediate certificate configured to be used by IPsec in the DirectAccess configuration." when device-certificates are enabled
The amount of accurate documentation on how to implement device-certificate based authentication for Direct Access clients is extremely low. If you’re implementing Direct Access from scratch I would recommend getting it working with AD credentials only, then enable device-certificates once you are confident in the general config. I recently did just this, the Direct Access server and clients were functioning correctly. The next stage was to enable Computer Certificates from Step 2 – Remote Access Server.
In my lab I only have a single tier AD CS PKI setup, therefore I selected Use Computer Certificates but did not tick Use an Intermediate Certificate. This would be required if you had a two-tier AD CS PKI.
For clarity at this point you should choose the certificate that is that is issued by your Certificate Authority. It is unclear what else is required to make IPsec work correctly.
Once you do the above, and Group Policy refreshes you will start getting an error about IPsec not working.
“Error: there is no valid certificate to be used by IPsec which chains to the root/intermediate certificate configured to be used by IPsec in the DirectAccess configuration.”
“Causes: the certificate has not been installed or is not valid.”
“Resolution: please ensure that a valid certificate is present in the machine store and DA server is configured to use the corresponding root certificate.”
The reason for this error is that a suitable certificate is not installed on the Direct Access server, this might seem obvious. However, the configuration step from Direct Access Step 2 – Remote Access Server does not install a certificate to make IPsec work, it simply points the Direct Access configuration at the PKI to trust for device certificates.
With that said, you must configure a custom AD CS template with specific settings to make IPsec work for Direct Access, a certificate from this template then must be installed on all of the Direct Access servers.
To do this open up Certification Authority and click Certificate Templates.
Open Manage from Certificate Templates.
Find the default Certificate Template called RAS and IAS Server, right click it and select Duplicate Template.
On the General tab give your new template a descriptive name I also select Publish Certificate in Active Directory.
Click on the Security tab and add the context Domain Computers and grant the following permissions
Click the Extensions tab and click Application Policies, then Edit.
Click Add from the Edit Application Policies Extension window.
Enter a descriptive text string for the new Application Policy, do not make any alterations to the Object Identifier and click OK.
Do not forget to do a Certificate Template to Issue to ensure the new template is available for certificate enrolment.
The next step to fix “IPsec is not working properly.” is to enroll a certificate on each of the Direct Access servers using the new template. It should be installed under the Computer context under the Personal store on each of the Direct Access servers.
Once this certificate is installed do a gpupdate /force on each of the Direct Access servers, the IPsec errors should disappear.