1

I defined a WebApi which takes the credetianls from the browser, it works. After deploying it I have to edit the Authentication on the server from Anonymouns to Windows. I tried to add <authentication mode="Windows"/> to the Web.Config.Release but it doesn't change... Why? Suggestions?

Emaborsa
  • 2,360
  • 4
  • 28
  • 50

1 Answers1

5

The .Release.Config file is not a .Config file as such - it's a file that describes how to transform the default Web.Config file into a new Web.Config file for release.

So, you don't simply add nodes to it - you need to specify the modifications you want to make using the defined syntax for this - see https://msdn.microsoft.com/library/dd465318(v=vs.100).aspx

In your case, you probably want something like:

...
<system.web>
    <authentication mode="Windows" xdt:Transform="SetAttributes" />
</system.web>
...
Gary McGill
  • 26,400
  • 25
  • 118
  • 202