6

So I recently figured out that IIS will use C:\Windows\System32\config\systemprofile as it's "user" directory for folders like AppData in certain situations.

Now, I'm trying to understand why this is and what purpose that directory serves. I've heard that it's used as a "template" for new users, but I'm pretty sure that's what C:\Users\Default User is for. Beyond that, it maybe seems like a "user" directory for the SYSTEM user.. But why would IIS run under SYSTEM?

Can anyone enlighten me as to what this directory does?

  • @Ramhound if you run IIS with a local user identity that has administrator abilities, it'll have this behavior. If you run IIS with a local user identity that doesn't have administrator abilities, it'll use the C:\Users\username folder – Earlz May 22 '13 at 14:45
  • the iissvcs (W3SVC) process is run as part of a svcHost process. unless you are using IISExpress. Keep in mind, W3WP processes are differant and run under the Application pool identity, however it is configured. – Frank Thomas May 22 '13 at 14:52
7

Appdata is used for per user configuration and data stores, to achieve a degree of user isolation. The system profile is not a template, it is the profile directory for the system user account, which is the user running the root IIS process host instance (note w3wp processes are run under the identity associated with an app pool not the root IIS process, and are not run from within a service host process).

check out this example using PSEXEC to login as system. just as %appdata% resolves to the logged in users ~\AppData\ directory, so to does it work for the System account:

    Windows PowerShell
    Copyright (C) 2009 Microsoft Corporation. All rights reserved.

    PS C:\Windows\system32> psexec -s \\localhost cmd

    PsExec v1.98 - Execute processes remotely
    Copyright (C) 2001-2010 Mark Russinovich
    Sysinternals - www.sysinternals.com


    Microsoft Windows [Version 6.1.7601]
    Copyright (c) 2009 Microsoft Corporation.  All rights reserved.

    C:\Windows\system32>whoami
    nt authority\system

    C:\Windows\system32>cd %appdata%

    C:\Windows\System32\config\systemprofile\AppData\Roaming>
| improve this answer | |

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.