Swiss Army Knife App Mac

Swiss Army Knife App Mac

Previously I have written a few posts around using DEPNotify, which is still a great tool with loads of uses if you put your mind to it. However there is now a new challenger in the user display arena, Octory, and I’ve been exploring its uses for a while now.

Apr 23, 2020  Parallels toolbox is a Swiss Army Knife for your Mac. You’ve probably heard of Parallels Desktop, the Mac app that lets you run Windows on your Mac as a virtual machine (without rebooting). Jul 06, 2020  Shortmoji is the Swiss Army Knife keyboard that iOS never had. Will find that this tweak is a lot more flexible thanks to an extensive preference pane that gets added to the Settings app after installation: Here, you can. How to filter your data in Apple Numbers on Mac. Jailbreak News.

disclaimer: I don’t work for the authors or get anything for this, I just like what it can do.

There is one codebase for Octory but more features if you license the Pro version. One of those is a built in helper to run things as root because Octory runs as the user, in the same way as DEPNotify.

But what if you want to do some root process from an Octory user GUI?

A bit of background?

I had an idea of building a tool to elevate a user to admin for a set time and in my first version I used Octory for the user GUI but ran the controlling script from Jamf Self Service, meaning that the script was already running as root and this launched Octory as the user using a sudo user switch;

So when the user responded to the question on the form Octory wrote its output file and the rest of the process ran as root, which is pretty much the way many other processes work.

Swiss Army Knife App Mac

Then someone asked me, “how does it work if they are offline?”… well of course it doesn’t really so time to rethink and write V2.

V2 time

So how could I get a constantly running user level process to run a root level action?

Firstly I switched Octory to Menubar mode, so it could be launched at login by a LaunchAgent, which runs it as user level.

A LaunchDaemon has been configured that monitors for the Octory output file, which is confusingly called Input in the settings.

This LaunchDaemon is configured to:

  • set to always keep running, Keepalive.
  • monitors for the file creation, PathState.
  • Runs the script, ProgramArguments.


This script can then tidy up the trigger file, kill Octory then relaunch it, as shown previously, or not depending on your needs.

Swiss Knife App

So it’s really simple to make the free version of Octory run a process as root based on user input to its many available interaction types.