我正在运行具有提升的用户权限的winforms应用程序(模拟运行方式作为一个不同的域管理员帐户),但是我想启动一个子进程,打开一个网页浏览器当前登录的用户权限而不是提升的权限,而不必提示他们输入密码和登录信息,以便正确地与当前登录的用户权限握手NTLM。用登录用户凭据的C#启动过程
我已经试过类似:
// I have the USER NAME, this is not the issue
// I have the Domain, this is not the issue
// I need to grab the Password from the currently logged on user
// without prompting for it
System.Security.SecureString oPass = new System.Security.SecureString();
System.Diagnostics.Process.Start("IExplore.exe"
, this.oConfiguration.WrappersURL
, this.WindowsUserID
, oPass
, this.DomainName
);
..但我不太清楚如何抓住用户的密码。有关如何减少W7和XP兼容的登录用户权限的想法?
这是Web或Windows应用程序..?你有没有看过这个 'string userName = System.Security.Principal.WindowsIdentity.GetCurrent()。Name;' – MethodMan 2013-03-19 21:17:55
你将无法获得用户的密码 - 也就是说它不会被存储在任何地方......你能请澄清,如果“提升”是指“具有管理员权限的不同用户”或“同一管理员用户,但权限提高(由于UAC)” – 2013-03-19 21:28:38
应用程序作为具有管理权限的不同本地管理用户帐户运行,并且我想产生使用当前登录的用户帐户的过程。 – Dave 2013-03-20 15:50:45