0

I am using angular-cli to run the angular2 project.

I am using NTLM on backend side but angular2 is not able to authenticate but same thing worked using anuglar1.

Request Headers

Accept:application/json, text/plain, */*
Accept-Encoding:gzip, deflate, sdch, br
Accept-Language:en-US,en;q=0.8
Cache-Control:max-age=0
Connection:keep-alive
Host:myhost.com
Origin:http://localhost:4200
Referer:http://localhost:4200/
User-Agent:Mozilla/5.0 (Windows NT 6.1; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/54.0.2840.71 Safari/537.36

Response headers

Access-Control-Allow-Credentials:true
Access-Control-Allow-Origin:http://localhost:4200
Cache-Control:no-cache
Content-Length:61
Content-Type:application/json; charset=utf-8
Date:Sat, 12 Nov 2016 18:09:38 GMT
Expires:-1
Pragma:no-cache
Server:Microsoft-IIS/7.5
WWW-Authenticate:NTLM
WWW-Authenticate:Negotiate
X-AspNet-Version:4.0.30319
X-Powered-By:ASP.NET
Rohit
  • 2,987
  • 3
  • 25
  • 50
  • What is the same thing? Angular2 by itself doesn't know anything about NTLM authentication. That's a function off the back-end that Angular communicates with. Do you have a service of some sort that tries to call something to authenticate? – Ben Richards Nov 11 '16 at 20:04
  • I have two application one with angular1 and other with angular2 and backend same for both. NTLM is working with angular1 but not working with angular2 and using the same url for authentication. – Rohit Nov 12 '16 at 17:55
  • So there must be a difference between how your Angular 2 is calling the URL to authenticate. Can you share the code you are using for both? – Ben Richards Nov 12 '16 at 17:58
  • When requesting sending using angular1 response headers are different but request headers are same. – Rohit Nov 12 '16 at 18:19
  • Yeah, that doesn't really help much. I'm sorry, I can't help you with the limited information you provided. – Ben Richards Nov 12 '16 at 19:29

0 Answers0