Hi All,
Can anyone explain me what is Impersonation. I have went through some of the articles in google . But did'nt get axactly what is that ... when to use that...etc
I got the article wer its written like this ..
By default, ASP.NET executes in the security context of a restricted user account on the local machine. Sometimes you need to access network resources such as a file on a shared drive, which requires additional permissions. One way to overcome this restriction is to use impersonation. With impersonation, ASP.NET can execute the request using the identity of the client who is making the request, or ASP.NET can impersonate a specific account you specify in web.config.
I think u got it clearly but may b I m a tubelight .. not gettin it ..
"By default, ASP.NET executes in the security context of a restricted user account on the local machine."
"Sometimes you need to access network resources such as a file on a shared drive, which requires additional permissions"...
what these lines exactly mean...
If possible ...plz explain..
Tnx and Regards
s_raj0205
kalyan BandarupalliPosted Jan 2, 2008, 5:39 AM
Hi
By default asp.net application run under localuser a/c means all code that execute will configured to local a/c. u may not have permissions to access the registry, active directory accessing, write information in event log,accessing the shared drive, etc.....
In order to access some restricted sources u should impersonate as any other user a/c who is having the full permissions on those resources.
For Eg: You may required to validate a username and password against the users in the active directory, at that point u need to impersonate as ADMINITRATOR. so u can mention his a/c details in web.config. this is called impersonation.
hope you understand the difference