How do I remotely obtain a system's network shares and connections?

Posted by Mick on Stack Overflow See other posts from Stack Overflow or by Mick
Published on 2010-04-23T16:48:59Z Indexed on 2010/04/23 16:53 UTC
Read the original article Hit count: 219

Filed under:
|
|

I'm looking for a way to obtain information similar to the following console applications, remotely:

  • net use
  • net share
  • netstat -ano

However, I need to be able to do this without running a 3rd party application on the system. This effectively rules out using psexec to execute the command remotely, because psexec would then be installed as a service.

I should add that I have administrative credentials on the remote system. I've considered using WMI's remote execution ability, but that requires me to write output to a file and then retrieve it. It's possible, but I'd like to know if anyone has a better way.

I am using Delphi 2010.

© Stack Overflow or respective owner

Related posts about delphi

Related posts about wmi