Have you tried using these commands using certmgr: certmgr -add -all -c "File.p7b" -s -r localMachine Root
You can create a pakage with certmgr.exe and add the install commands with the p7b file as addition files or create a bat/powershell/vbs to install it and add additional files.
I did try your suggestion. LANDesk reports that it failed if I include certmgr.exe as an additional file. The push indicates Active and hangs if I do not include it. I checked the path on the test machine; the package pushes to the workstation, but will not install the certificate.
The Utility cannot find the Cert file, as it is located in C:\Program Files (x86)\LANDESK\LDClient\sdmcache\
If your software share has a folder structure it will be....
C:\Program Files (x86)\LANDESK\LDClient\sdmcache\Software\folder\folder
I have a mixed enviroment so I use Powershell to give me my path
Just be sure to add your your cert file as an additional file
$scriptPath = split-path -parent $MyInvocation.MyCommand.Definition
certmgr -add -all -c "$scriptPath\File.p7b" -s -r localMachine Root
EDIT: Add the utility as well. --- .\\certmgr -add -all -c "$scriptPath\File.p7b" -s -r localMachine Root
I know very little about Powershell. Am I able to user you script as is or does "$scriptPath = split-path -parent $MyInvocation.MyCommand.Definition" require modification?
Can this task be accomplished in a batch file or vbs script?
It uses Powershell.
Save the text file as .PS1
Be sure you placed the script, Cert file, and certmgr.exe all in the same shared location (Software Share)
$scriptPath = split-path -parent $MyInvocation.MyCommand.Definition -- No edit required. This will capture the path the script is running from
.\\certmgr -add -all -c "$scriptPath\File.p7b" -s -r localMachine Root -- Make sure File.p7b is the name of your cert
Windows 7/Server 2008 R2 come with PowerShell 2.0 installed, by default.
Also, you may need to specify an Admin Account in the "Accounts" section of the package. By default packages run LocalSystem
Not having certmgr.exe may be most of my problem. "Certmgr.exe" is not included with Windows 7; it has certmgr.msc. Microsoft does not make it easy to find. Does anyone have a link to download for it?
Here is a simple bat:
certmgr -add -all -c "%YOURFile%.p7b" -s -r localMachine Root
EXIT /B %ERRORLEVEL%
Just replace %YOURFile% with the actual name of the file, again make sure you have the certmgr.exe and the .p7b cert file added as additional files as well as the proper permissions as stated early.
The sdclient.exe /msg= will send the message of the errorlevel to the console so you can see the output from the script.
Does %~d0%~p0 return the running directory?
That is the Current Working Directory hence why I call it CWD.
IC, I read Crazy Witch Doctor, and assumed it was some kind of voodoo.
Very cool BTW, I will keep that string handy