1

I have an application with multiple areas. I have no problem navigating to any of them once logged in.

I've added a new 'Reports' area, now when I navigate to that area I get an 'Authentication Required' pop up appear which I think is something to do with Windows authentication which isn't being used in the application.

I'm using <authentication mode="None" /> in web.config.

This only happens when the site is live and not local (which makes sense if it's a windows authentication issue).

All controllers in the areas use the same custom authentication attribute, any ideas why I wouldn't be able to navigate to this new area even though going to others is absolutely fine, any ideas what i'm missing? I don't remember having to do anything in other areas to allow access.

Thanks.

Jammer
  • 2,330
  • 11
  • 48
  • 77

2 Answers2

2

I found the issue. The URL that was causing the issue was

www.domain.co.uk/reports

I remembered a while ago I was doing some testing using SSRS and setup the Report Manager URL as localhost/reports. This must have been causing the issue as once I had changed the Report Manager URL I could access the URL I was having issues with as expected.

Jammer
  • 2,330
  • 11
  • 48
  • 77
0

That setting in your web.config should be working.

It could be that it's not overriding the settings in the applicationhost.config file as it should.

To test this out navigate to the "\IISExpress\config\applicationhost.config" file and set <windowsAuthentication enabled="false" />

Other things you can try.

Remove forms authentication - sites often default to this.

<system.webServer>
 <modules runAllManagedModulesForAllRequests="true>
    <remove name="FormsAuthentication />
 </modules>
</system.webServer>

Disable security for that path.

 <location path="secureddir/newform.aspx">
    <system.web>
      <authorization>
        <allow users="*"/>
      </authorization>
    </system.web>
  </location> 
CountZero
  • 6,171
  • 3
  • 46
  • 59