impacket icon indicating copy to clipboard operation
impacket copied to clipboard

Unable to change Service type to SERVICE_INTERACTIVE_PROCESS

Open haxpak opened this issue 5 years ago • 1 comments

Configuration

impacket version: v0.9.22.dev1+20200629.145357.5d4ad6cc Python version: 2.7.18 Target OS: Windows 10 1803

Debug Output With Command String

proxychains ./services.py -debug -hashes aad3b435b51404eeaad3b435b51404ee:<MY HASH> MYDOMAIN/[email protected] change -name <Service_NAME> -service_type 256
ProxyChains-3.1 (http://proxychains.sf.net)
Impacket v0.9.22.dev1+20200629.145357.5d4ad6cc - Copyright 2020 SecureAuth Corporation

[+] Impacket Library Installation Path: /usr/local/lib/python2.7/dist-packages/impacket-0.9.22.dev1+20200629.145357.5d4ad6cc-py2.7.egg/impacket
[+] StringBinding ncacn_np:192.168.10.10[\pipe\svcctl]
|S-chain|-<>-ip:PORT-<><>-192.168.10.10:445-<><>-OK
[*] Changing service config for WindowsTaskHostManagement
Traceback (most recent call last):
  File "./services.py", line 357, in <module>
    services.run(remoteName, options.target_ip)
  File "./services.py", line 61, in run
    self.doStuff(rpctransport)
  File "./services.py", line 229, in doStuff
    NULL, NULL, NULL, 0, start_name, password, 0, display)
  File "/usr/local/lib/python2.7/dist-packages/impacket-0.9.22.dev1+20200629.145357.5d4ad6cc-py2.7.egg/impacket/dcerpc/v5/scmr.py", line 1240, in hRChangeServiceConfigW
    return dce.request(changeServiceConfig)
  File "/usr/local/lib/python2.7/dist-packages/impacket-0.9.22.dev1+20200629.145357.5d4ad6cc-py2.7.egg/impacket/dcerpc/v5/rpcrt.py", line 878, in request
    raise exception
DCERPCSessionError: SCMR SessionError: code: 0x57 - ERROR_INVALID_PARAMETER - The parameter is incorrect.
[-] SCMR SessionError: code: 0x57 - ERROR_INVALID_PARAMETER - The parameter is incorrect.
  • I am able to create the service, start and stop it.
  • I need my service to interact with the Desktop for certain functions, however this is the only part where I am stuck

haxpak avatar Jul 07 '20 16:07 haxpak

same issue here but using python3

ghost-ng avatar Jul 22 '22 02:07 ghost-ng