Class Impersonation
- Namespace
- Dynamicweb.Security
- Assembly
- Dynamicweb.Security.dll
Provides methods to impersonate the authenticated identity under the code should be executed.
public class Impersonation : IDisposable
- Inheritance
-
Impersonation
- Implements
- Inherited Members
Properties
DomainName
Gets domain name
public static string DomainName { get; }
Property Value
- string
- String value
Success
Gets value indicating whether impersonation succeeded.
public bool Success { get; }
Property Value
Methods
Dispose()
public void Dispose()
Dispose(bool)
Disposes unmanaged resources.
protected virtual void Dispose(bool disposing)
Parameters
disposing
bool
HostingImpersonateCredentials()
Provides hosting impersonation credentials
public static ImpersonationCredentials HostingImpersonateCredentials()
Returns
- ImpersonationCredentials
- ImpersonationCredentials object instnace
Impersonate(string, string)
Performs impersonation using specified user-name and password.
public bool Impersonate(string userName, string password)
Parameters
Returns
Impersonate(string, string, string)
Performs impersonation using specified user-name and password.
public bool Impersonate(string userName, string password, string domain)
Parameters
Returns
ImpersonateByCredentials(ImpersonationCredentials)
Performs impersonation using specified credentials.
public static Impersonation ImpersonateByCredentials(ImpersonationCredentials credentials)
Parameters
credentials
ImpersonationCredentials- Credentials to use.
Returns
ImpersonateByFormRequest()
Performs impersonation using credentials parsed from the current POST request.
public static Impersonation ImpersonateByFormRequest()
Returns
ImpersonateEnd()
Terminates current impersonation.
public void ImpersonateEnd()