Carbon Black Install from the web

Where I work we heavily rely on autopkg & autopkgr to do the heavy lifting of our package management.

As a stop gap before going down the rabbit hole of a Hand Crafted autopkg recipe, I created a Carbon Black install Script.

I did this because Carbon Black throws some fun curveballs:

  • They Don’t give you a direct link to the latest package
  • They expect you to utilize the API to download the package
  • The URL is instance dependant

With that problem in mind I’ve created this which should work for what I want… Deploy the package upon DEP enrollment, let InfoSec manage the updates from there forth.

 

To set this up you’re going to need a few things:

  • Your Carbon Black Domain
  • Your API Key

You can find your API key by:

1.Clicking on your profile (this is on the left side)

2. Selecting API Token

3. Copy the token in the grey box.

  • The Group you wish to deploy from. By default you may only have one group. If you have only one you can skip this part.

You can find this by going to:

1.Administration -> Sensors

2. Selecting the group you wish to deploy from

3. Look at the URL for the number after #hosts/

eg. https://CBdomain.com/#hosts/2/?start=0&rows=10&uninstall=false&uninstalled=false

In the example above we’re using group 2.

Now that we’ve got all this info we’re going to configure the script above for our JSS.

  1. Logon to your JSS
  2. Click Management settings on the left.
  3. Select Computer management and click on scripts
  4. Click + to add a new script
  5. Give it a name. I’ve named it “Install Carbon Black from the web”
  6. Click the Script tab and copy and paste the above in there.
  7. Then Click Options
  8. Edit Parameter 4, 5 and 6 to show the following
  9. Click Save
  10. Click Done

Now we’re going to setup the Policy

  1. Create a new Policy
  2. Click Scripts
  3. Add the script
  4. Enter in your Domain, and api key. Group can be left blank if you don’t use it
  5. Set your scope
  6. Save and test

No Comments

Leave a Comment