Posted on: 6/23/2013 2:05:47 PM | Views : 811

I am troubleshooting an issue in ASP.NET 2.0 application (that has been working on many different servers for years successfully). The problem is that without using Impersonation I cannot give the application full access rights to a certain folder. 
It all seems to stem from the fact that the application – when not using Impersonation – runs under a user name which is the Server Name.  The function Environment.UserName  returns the server name (e.g. “PHSGSMGGAGG$”).  In all my previous working with ASP.NET 2.0 appication the Environment.UserName would always return NETWORK SERVICE.  And it was easy to set this user – NETWORK SERVICE – to any folder.  So my question is, where is it in the .NET 2.0 environment that the server name (e.g. “PHSGSMGGAGG$”) is set to Environment.UserName?  And how can I change it to the customary  NETWORK SERVICE?
...

Go to the complete details ...