Box Sync 4

donmontalvo
Esteemed Contributor III

Not sure why Box is distributing a drag-install app, when on first launch it prompt for admin rights, to install /Library/PrivilegedHelperTools/com.box.sync.bootstrapper. So we packaged that item to be distributed along with the drag-install app.

I sent a note to the developer asking them. Seems they would do better to distribute a proper PKG installer. I mean, what good is a drag-install app on a DMG if you have to authenticate the application on first launch. :)

Oh well, posting here in case this can help the next person who has to package/disribute Box Sync 4.

--
https://donmontalvo.com
20 REPLIES 20

kstrick
Contributor III

We tried that with our "Enterprise Support" folks, they gave us non-sensical responses....
Also, I broke Box Sync a couple of versions ago, because i put a .plist to block their automatic updates, and i used a standard, binary plist.... the fix was to convert the .plist to text based....
so a properly formatted binary plist crashed the whole program.

donmontalvo
Esteemed Contributor III

Curious if a defaults command would work, rather than pushing a *.plist (because cfprefsd)?

--
https://donmontalvo.com

kstrick
Contributor III

actually, i was using "default" in my postinstall script to do that, but i had to run a "plutil -convert xml1" after to fix it.

alexk
New Contributor III

i agree that it's weird that Box still deploys Box Sync in that way. i recently found bryson's script to install Box Sync from SS. i tried it out in our environment, and it has been working great. i commented out the last part to do a recon since we update inventory as one of the payloads in the SS policy. if you keep it in the script, then update the path to the jamf binary. thanks again @brysontyrrell !

https://github.com/jamfit/Box-Sync-4-Installer

Not applicable

kstrick , Could please help me out on disabling the auto updates for Box Sync 4 ? which plist file you are updating to block updates ?

kstrick
Contributor III

@kumarmudedla,
I have been using these two lines as part of my postinstall script--

/usr/bin/defaults write /Library/Preferences/com.box.sync.plist auto_update.enabled -bool False
/usr/bin/plutil -convert xml1 /Library/Preferences/com.box.sync.plist

I'm not 100% if current versions of Box Sync respect still respect the plist (I haven't seen it actually documented by them), but this has worked in the past.

I originally found that plist by reading @Bruienne 's article box-cutting-how-i-stumbled-onto-a-serious-security-flaw-in-box-sync-for-mac

Not applicable

@kstrick Thank you

lkrasno
Contributor II

@brysontyrrell looks like that link isn't so static :(

I'll retry with https://sites.box.com/sync4/

BrysonTyrrell
Contributor II

@lkrasno I noticed that just the other day too. I pulled the following link from Box's mass deployment page and have been using that now:

downloadurl="https://e3.boxcdn.net/box-installers/sync/Sync+4+External/Box%20Sync%20Installer.dmg"

I'll get the public repo updated shortly.

lkrasno
Contributor II

many thanks @brysontyrrell

jalcorn
Contributor II

Sweet

tcandela
Valued Contributor II

what i did was use the Packages application to create my Box Sync.pkg

1 using the Payload tab I selected Applications and added the Box Sync.app
2 using the Payload tab I select PrivilegedHelperTools and added both entries for com.box.sync.*

EdLuo
Contributor II

I'm trying to package Box Sync.App v.4.0.7724 with the bootstrapper file mentioned. Adding /Library/PrivilegedHelperTools/com.box.sync.bootstrapper no longer works in preventing the admin prompt. donmontalvo, have you tried the newer version?

chriscollins
Valued Contributor

@eddieluo You shouldn't need to copy that file to that folder. Instead, when your package dumps the Box Sync.app file in /Applications, run this command as a postflight:

/Applications/Box Sync.app/Contents/Resources/com.box.sync.bootstrapper --install

That is what the BOX Sync app is doing itself when it prompts the usr for authentication. It will copy the bootstrapper helper into the proper place and register it with the OS.

EdLuo
Contributor II

@chriscollins - I added your line into postinstall script and complied it as a PKG. It works great. Thank you!

rgranholm
Contributor

Would this impact an install of Box Edit at all?

After I installed it, my Box Edit seemed to break, not being recognized as having it installed at the site.

-r

donmontalvo
Esteemed Contributor III

@chriscollins nice, thanks for the heads up. @eddieluo we confirmed this works beautifully!

--
https://donmontalvo.com

jtaveras
New Contributor III

not sure if you still need help but this link helped me a lot
https://bryson3gps.wordpress.com/2013/05/01/box-edit-and-box-sync-via-self-service/
it installs box, and box edit, if its already installed, it removes it an re-installs it.
pretty neat

rgranholm
Contributor

Thanks, it does look useful, here's the big issue.

*NOTE: Box Edit is now an APP installer. It now installs two files into ~/Library/ApplicationSupport/Box/BoxEdit called Box Local Com Server.app and Box Edit.app These two files have to be activated by by the logged in local user in order for Box Edit to work.

That part makes things more complex and where I stumbled. I think with all this info I can make it work, but it's going to take some time.

EdLuo
Contributor II

@rgranholm Try this...

  1. Using Composer, capture install of Box Edit and strip out garbage files.
  2. Create and upload DMG from Composer to Casper Admin
  3. Create Policy to install Box Edit package crated from Composer
  4. Add to Policy, File and Processes, Execute Command user=ls -la /dev/console | cut -d " " -f 4; sudo -u $user open "/Users/$user/Library/Application Support/Box/Box Edit/Box Local Com Server.app"
  5. Add to Policy, Maintenance, Update Inventory

This is assuming that Box Edit is not currently installed. If it is installed, you may need to kill the Box Edit process first.