NGINX load balancer configuration with IIS authentication (Windows & anonymous authentication)

Please use this template for troubleshooting questions.

My issue:

My application is hosted in the IIS webserver and it is running on Windows and anonymous authentication. The application is hosted in the two nodes(server1 and server2) and NGINX is configured in Server3.

Now, with the NGINX, have configured the load balancer which point to two nodes.

In this case, when user runs the NGINX configured node3 portal user was getting the authentication screen. when user provided the authentication credentials it is not navigating to the application.

if user run the Individual application(let say server without NGINX) the with same user authentication it is working.

Solutions I’ve tried:

NGINX HTTP Load Balancing

Deployment environment:

Windows IIS

Hey @jayachandra21! Do you know if you are using ntlm for authentication by any chance? If so, it’s only available when using NGINX Plus. If not, could you share your NGINX config?

Hello @alessandro ,

Yes, using the Windows Authentication.

I have attached the NGINX config file.

NGINX Load Balacer Configuration.txt (3.7 KB)

Like I mentioned, the issue is likely due to ntlm authentication not being available in NGINX Open Source.

You could potentially disable authentication on the Windows side and enable some level of user authentication in NGINX (see Restricting Access with HTTP Basic Authentication | NGINX Documentation or Authentication Based on Subrequest Result | NGINX Documentation for examples).

Otherwise, you will likely need to use NGINX Plus and use ntlm auth (you can request a free trial for NGINX One –which includes NGINX Plus– here).

1 Like

This topic was automatically closed 30 days after the last reply. New replies are no longer allowed.