English 中文(简体)
Ant exec作为视窗的不同用户
原标题:Ant exec as different user on Windows
  • 时间:2012-05-04 18:36:59
  •  标签:
  • windows
  • ant

我愿作为另一个用户在Windows/strong>上进行迫害。 我想引用PsExec,在同一机器上运行,用用户名和密码通过。 是否有更好的办法这样做? 迄今为止,我发现的答案是 running到赖特/Unix。

感谢。

最佳回答

您可使用runas util toî an executable as a differentuser。

允许用户使用不同于用户现行标识所提供的不同许可的具体工具和方案。

问题回答

在Windows 7之前的窗口版本中,你应当能够简单地点击可执行和选择“Run As”。 然后,你可以从现有用户的下游名单中挑选用户。 在Windows 7中,这一选择被“作为署长的Run”方案所取代。

From the windows pages at Microsoft:

http://windows.microsoft.com/en-us/windows-vista/What-happened-to-the-Run-as-command”rel=“nofollow”>http://windows.microsoft.com/en-us/windows-vista/What-happened-to-the-Run-as-command

如果你被贴上标准用户的标签,你也可以使用Run作为管理人作为另一个用户管理方案,即使用户没有管理账户。 为此,点击Run作为管理人,然后选定用户账户。 如果你要作为管理人管理,那么,如果你想作为另一个用户管理一个方案,那么你就必须在Prompt窗口上打上跑道。





相关问题
Why running a service as Local System is bad on windows?

I am trying to find out the difference between difference service account types. I tumbled upon this question. The answer was because it has powerful access to local resources, and Network Service ...

Programmatically detect Windows cluster configuration?

Does anyone know how to programatically detect that a Windows server is part of a cluster? Further, is it possible to detect that the server is the active or passive node? [Edit] And detect it from ...

get file icon for Outlook appointment (.msg)

I ve read Get File Icon used by Shell and the other similar posts - and already use SHFileInfo to get the associated icon for any given extension, and that works great. However, Outlook uses ".msg" ...

Identifying idle state on a windows machine

I know about the GetLastInputInfo method but that would only give me the duration since last user input - keyboard or mouse. If a user input was last received 10 minutes ago, that wouldn t mean the ...

Terminating a thread gracefully not using TerminateThread()

My application creates a thread and that runs in the background all the time. I can only terminate the thread manually, not from within the thread callback function. At the moment I am using ...