/build/static/layout/Breadcrumb_cap_w.png

Scripting Question


Bitlocker script

04/29/2014 9100 views

Here is my script, trying to write the bitlocker status to a file. The script runs and creates an empty file. I actually have 2 scripts that do the same thing on 64 bit laptops:

1. Launch %windir%\syswow64\cmd.exe with params /C c:manage-bde.exe -status >c:\cn.txt.

2. Launch C:\Windows\system32\cmd.exe with params /C manage-bde.exe -status >c:\cn.txt

Anyone have any advice?

 

4/30/14 -tried removing quotes on both scripts, still get an empty cn.txt file and "error creating process".

1 Comment   [ + ] Show comment

Comments

  • drop the one set of the double quotes in your parameters around manage-bde.exe -status > c:\cn.txt

    “C:\Windows\system32\cmd.exe” with params “/C manage-bde.exe -status >c:\cn.txt”
    • tried removing quotes on both scripts, still get an empty cn.txt file and "error creating process".


Community Chosen Answer

2

I see what you mean it works fine on 32 bit but not 64 bit machines.  Even tried as a custom software inventory and got same results.  The problem is the kace client is a 32bit application, so when it tries to run an .exe file under %Windir%/system32 it is automatically redirected to %Windir%/syswow64, and the manage-bde.exe file doesn't exist in this location.

I use the link below to hide the cmd window from showing but you can just use the line in the batch file as your parameters

http://www.itninja.com/blog/view/how-to-hide-running-a-batch-file-from-a-kscript-with-version-5-5

so as a custom software inventory for 64bit:

 

as a hidden script file:

create 2 files, invisible.vbs and bitlocker.bat and add them as dependancies

As a script that will flash the cmd window past the user:

 

 

 

 

Answered 05/08/2014 by: SMal.tmcc
Red Belt

  • Works great, thank you.

All Answers

0

https://www.itninja.com/blog/view/kace-sma-bitlocker

Answered 03/29/2019 by: Timokirch
3rd Degree Black Belt

This content is currently hidden from public view.
Reason: Removed by member request For more information, visit our FAQ's.

Don't be a Stranger!

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

Sign up! or login

View more:

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