continue if {(size of it = 342528 AND sha1 of it = “ee47505ebfb2790b9da8a20ed70e67158e9753d0”) of file “RunAsCurrentUser-2.0.3.1.exe” of folder “__Download”}
Everything works fine except on the last line I get a Thread Execution failed. The files are present (both RunAsCurrentUser.exe and the BSWP.VBS) so where am I going wrong?
Completed continue if {(size of it = 342528 AND sha1 of it = “ee47505ebfb2790b9da8a20ed70e67158e9753d0”) of file “RunAsCurrentUser-2.0.3.1.exe” of folder “__Download”}
Completed continue if {(size of it = 296 AND sha1 of it = “043b4e80bee1b41772ff9801931901f602224a9b”) of file “BSWP.VBS.vbs.tmp” of folder “__Download”}
Command succeeded (evaluated true) continue if {(size of it = 342528 AND sha1 of it = “ee47505ebfb2790b9da8a20ed70e67158e9753d0”) of file “RunAsCurrentUser-2.0.3.1.exe” of folder “__Download”}
Command succeeded (evaluated true) continue if {(size of it = 296 AND sha1 of it = “043b4e80bee1b41772ff9801931901f602224a9b”) of file “BSWP.VBS.vbs.tmp” of folder “__Download”}
CScript doesn’t understand the path to the VBS file. Try:
waithidden RunAsCurrentUser.exe --w cscript.exe “{pathname of client folder of current site & “__Download\BSWP.vbs”}”
If that fails, the user may not have rights to read from the BigFix directory, move the vbs file to a location the user has access to and provide the full path to the vbs file.
Don’t know if you caught it, but I forgot the __Download before RunAsCurrentUser.exe, not sure if that is what is causing your error or not.
waithidden __Download\RunAsCurrentUser.exe --w cscript.exe “{pathname of client folder of current site & “__Download\BSWP.vbs”}”
You can also try:
waithidden __Download\RunAsCurrentUser.exe --w “{pathname of system folder & “\cscript.exe”}” “{pathname of client folder of current site & “__Download\BSWP.vbs”}”
continue if {(size of it = 296 AND sha1 of it = “043b4e80bee1b41772ff9801931901f602224a9b”) of file “BSWP.VBS.vbs.tmp” of folder “__Download”}
extract BSWP.VBS.vbs.tmp
waithidden __Download\RunAsCurrentUser.exe --w “{pathname of system folder & “\cscript.exe”}” “{pathname of client folder of current site & “__Download\BSWP.vbs”}”
Looks to me like you’re trying to call “RunAsCurrentUser.exe” but it doesn’t exist because the downloaded executable is actually named “RunAsCurrentUser-2.0.3.1.exe”.
I’d suggest using this prefetch command instead, which will automatically rename it to RunAsCurrentUser.exe for you:
Try to copy/move the script outside “BES Client” folder and run again. The “current users” might not have the right to access “BES Client” folder if they are not in Administrator user group.