Recently I tried to configure Dynamics NAV 2015 OData web services. After the initial configuration i was unable to authenticate with the OData URL – The Credentials prompt just kept popping up time after time. The message i received was:
The server is asking for your username and password
The server reports that it is from digest
It seems that the reason for this issue (Although not documented in NAV requirements) is because I was working on a WORKGROUP server that was not a part of an Active Directory domain, and although Dynamics NAV is supported in a WORKGROUP environment – It seems that OData web services need an Active Directory environment – as they rely on Digest authentication.
In my case – adding the server to a domain or promoting it to a DC – solved the issue!
As i said – i did not find any detailed specifications for this in the Dynamics NAV requirements or technet – I relied on other sources regarding Digest authentication and it solved my issue – If you are having the exact same problem – this might be the solution.
I have stumbled upon this issue while configuring a Dynamics NAV 2015 Load Balanced solution combined with Forms Authentication.
In this scenario you will randomly get this error while browsing the NAV Web Client:
“A script error has occurred, and the content cannot be displayed. Refresh the page or open a new browser window”
At the same time you will find an ASP.NET warning in the event log on one of the front servers saying:
“An error occurred processing a web or script resource request. The resource identifier failed to decrypt”
So what’s going on here?
Turns out that in order to work with forms authentication with NLB you need to configure Identical Machine Keys on both IIS servers that host your Dynamics NAV Web Client:
1. Go to IIS on your first server and go to Machine Keys:
2. Remove the check-box from both “Automatically Generate at runtime” options and then click Generate Keys.
3. Hit apply and copy both keys to notepad.
4. Go to IIS on your second server and paste the keys generated on the first server to the machine keys respectively.
5. Hit apply and do an IISRESET on both servers
A new video tutorial is available on my YouTube channel – this time a step-by-step installation guide for Microsoft Dynamics NAV 2015 with SQL 2014 – Check it out:
This is a very straight-forward guide that explains how to setup a working environment with the Demo Cronus Database from Microsoft – You can use this for your Tests, Development & Presentation servers – and the installation process is also relevant for a small Production Environment. I hope you find this useful – If so – don’t forget to subscribe 🙂