7

I created default asp.net core application from defaut template. I chose Windows Authentication option during porcess of creation of new project (here is what i did). When i run app on issexpress, it works like a charm.

When i moved app onto local iis it works, but it does not get user info. I enabled windows authentication in windows features. But it shows me empty User.Identity.Name. I tried to add this lines to web.config

    <security>
        <authentication>
            <windowsAuthentication enabled="true" />
            <anonymousAuthentication enabled="false" />
        </authentication>
    </security>

Tried to turn on windows authentication from IIS Manager. I dont know what else can be wrong. What am i missing?

Tseng
  • 61,549
  • 15
  • 193
  • 205
F0rc0sigan
  • 676
  • 2
  • 11
  • 22
  • I'm having the same issue, tried the same things...still no success. Did you ever get this working? – J. Allen Dec 10 '16 at 22:16

2 Answers2

1

In web.config, did you put

<authentication mode="Windows" /> 

in system.web sector as well?

sgrsigma
  • 9
  • 2
1

I could resolve this issue. I turned on windows authentication feature on local iis and after that local authentication worked like a charm. Here is a good article how to do that.

F0rc0sigan
  • 676
  • 2
  • 11
  • 22