How to change user credentials of windows service from command line?
相关问题
- Why does a windows service, hosting an NserviceBus
- softlinks atime and mtime modification
- Get unexpanded argument from bash command line
- Include and Execute EXE in C# Command Line App
- Batch - Set variables in for loop
相关文章
- XCopy or MOVE do not work when a WCF Service runs
- Compile and build with single command line Java (L
- Problem installing windows service
- How to update command line output?
- Can't start Tomcat as Windows Service
- How to execute another python script from your scr
- Python file keyword argument?
- Interactively merge files tracked with git and unt
See Shortcut Setting Log-On Credentials for Windows Services » jonathanmalek.com.
@MattT points out that on Windows Server 2008R2, you also have to add
type= own
.I simply called WMI from powershell to do this.
Don't forget to restart the service afterwards:
For more fun with WMI and services, see Win32_Service Class
Using WMI results in non-encrypted communication between your machine and the machine you are changing the service credentials on. So your new password can be sniffed quite easily. You just have to parse the WMI blob send over the network. By now I found no really secure way to change a service accounts password remotely with a tool.