/build/static/layout/Breadcrumb_cap_w.png

How to make .vbs to execute on target machine?

Attached is a picture of what I have written. The .vbs makes it to the target machine and I even see the brief popup of the cscript cmd window. If I enter cscript "C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\203\Uninstall_FCS.vbs" on the cmd prompt of the target machine, it works properly. I have tried with and without quotes around the filepath.

What am I missing to make KACE invoke the .vbs?

The .vbs is this script to uninstall MS Forefront: http://gallery.technet.microsoft.com/scriptcenter/ccd81060-292d-4470-afb2-ddb65bf71ce4#content

Note: I hardcoded the directory because I noticed the Activity log showing this. Note the double slash at KACE\\kbots

Launching program: 'C:\windows\System32\cscript.exe' '"C:\ProgramData\Dell\KACE\\kbots_cache\packages\kbots\203\Uninstall_FCS.vbs' wait='false'"

Pasted below the image is the Run Now status.

 

Output Log

Running as: SYSTEM
Launched Process: cscript.exe

Activity Log

Launching program: 'C:\windows\System32\cscript.exe' '"C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\203\Uninstall_FCS.vbs"' wait='false'

Debug Log

Running kbot: runkbot 203 1384548613r17
Validating kbot xml
Kbot xml C:\ProgramData\Dell\KACE\kbots_cache\203-1384548613r17_expanded.xml, Validation Success
Kbot Config Info - Start
id=203 name=Uninstall Forefront version=1384548613r17 type=policy
execute disconnected=false logged_off=false
execute events
Kbot Config Info - Finish
runkbot    ----- launching [path='C:\windows\System32' program='cscript.exe' parms='"C:\ProgramData\Dell\KACE\kbots_cache\packages\kbots\203\Uninstall_FCS.vbs"' wait='false'] -----
runkbot    ----- completed [exitCode=0] -----

1 Comment   [ + ] Show comment
  • Try zipping the vbs and a bat file up as your payload. Within your bat call the vbs using the full path. Perhaps that will work. - Jbr32 11 years ago

Answers (2)

Answer Summary:
Posted by: vmann 11 years ago
Blue Belt
1

The solution was to use an Online Shell Script with this special call for cscript.

%SystemRoot%\Sysnative\cscript.exe Uninstall_FCS.vbs

Issue was related to 64 bit vs 32 bit registry lookups,

http://www.kace.com/support/resources/kb/article/how-to-import-reg-file-into-64-bit-registry

Posted by: jknox 11 years ago
Red Belt
1

Check it against this: http://www.kace.com/support/resources/kb/article/how-to-call-a-visual-basic-script

I agree with Jbr, try zipping the files up together directly.

Don't be a Stranger!

Sign up today to participate, stay informed, earn points and establish a reputation for yourself!

Sign up! or login

Share

 
This website uses cookies. By continuing to use this site and/or clicking the "Accept" button you are providing consent Quest Software and its affiliates do NOT sell the Personal Data you provide to us either when you register on our websites or when you do business with us. For more information about our Privacy Policy and our data protection efforts, please visit GDPR-HQ