ASP.Net Impersonation

From: Mark Miller (mark_no_s_p_am__at_maxpreps.com)
Date: 12/30/04

  • Next message: Mark Miller: "Re: Redirect not working"
    Date: Thu, 30 Dec 2004 10:35:05 -0800
    
    

    I am trying to understand Impersonation in the ASP.Net context. Here's what
    I DO understand:
    -Using Windows Authentication with impersonation="true" means that the
    aspnet_wp will try and access the resource with the authenticated user's
    credentials (token). If access is denied I get an IIS access denied message.
    -I can set NTFS permissions on a file/folder and control access w/o using
    code simply by assigning rights by user or group.
    -setting impersonation="false" still authorizes the user using NTFS
    permissions, but instead it is the aspnet_wp account that accesses the file
    and checks the permissions. Then if access is denied ASP.Net throws an
    exception.
    Here's what I DON'T understand:
    -What's the difference then between Windows Authentication with
    impersonation turned on, and windows impersonation turned off? Other than
    where the authorization takes place (ie. aspnet_wp or NTFS).
    -When would I want to use one over the other?

    Thanks in advance,
    Mark Miller


  • Next message: Mark Miller: "Re: Redirect not working"

    Relevant Pages

    • Re: VS.NET 2005 and the "allowDefinition=MachineToApplication" error
      ... Your description of impersonation is great. ... If you want to use the default configured account, eliminate that entry, or configure it as: ... The easiest way to assign correct permissions to all required directories is to run: ... I re-started IIS and tried to access my ASPX page again -- same ...
      (microsoft.public.dotnet.framework.aspnet)
    • Re: Cant Write File on Hosted Server...
      ... Authentication for write permissions can be a tricky thing in a hosted ... I would guess that the hosting provider denies write at some point in the ... impersonation is unlikely to help as you have found. ...
      (microsoft.public.dotnet.general)
    • Re: Fileupload - authorization to directories through code?
      ... You should not be able to set permissions programmatically with asp.net. ... I would think that would be a security risk. ... The FTP user that you log into. ... good tutorial on asp.net user impersonation and understand all of the ...
      (microsoft.public.dotnet.framework.aspnet)
    • Re: Question about Permissions
      ... > thread that would have the permissions matching what ... The topic in question is called "Client ... Impersonation" and is quite broad. ... impersonate the client as the operating system knows full well who is at the ...
      (microsoft.public.win32.programmer.kernel)
    • Re: NTFS + Impersonation + Asp.Net
      ... I set impersonation to true in machine.config. ... I must be sure that he can't RevertToSelf and use the asp.net account. ... > permissions because you still have to give permissions to ... as a test I set NTFS file permisions to refuse ...
      (microsoft.public.dotnet.framework.aspnet.security)