【发布时间】:2010-11-03 01:03:16
【问题描述】:
我正在使用 LogonUser win32 api:
token = LogonUser(...)
WindowsIdentity newId = new WindowsIdentity(token);
WindowsImpersonationContext impersonatedUser = newId.Impersonate();
但是,在此之后调用 WCF 服务时,我无法使用模拟身份。我认为这是因为 impersonatedUser.ImpersonationLevel 等于 Impersonation。
是这个原因吗? ImpersonationLevel.Identification 级别是我需要的吗? 怎么达到这样的水平?
【问题讨论】:
标签: c# winapi impersonation delegation