Version of file in MacOS

Please help me with a relevance to output the tanium version installed in MAC devices
1.
Q: version of regapp "/Library/Tanium/TaniumClient/TaniumClient.app"
E: Singular expression refers to nonexistent object.
T: 54851

Q: version of regapp "TaniumClient.app"
E: Singular expression refers to nonexistent object.
T: 24177

Q: version of application "/Library/Tanium/TaniumClient/TaniumClient"
E: Singular expression refers to nonexistent object.
T: 168173

Q: version of component "/Library/Tanium/TaniumClient/TaniumClient"
E: The operator “component” is not defined.

Q: version of file “TaniumClient” of folder "/Library/Tanium/TaniumClient"
E: Singular expression refers to nonexistent object.
T: 10111

Q: versions of file "/Library/Tanium/TaniumClient/TaniumClient"
T: 52448

Q: version of file "/Library/Tanium/TaniumClient/TaniumClient"
E: Singular expression refers to nonexistent object.
T: 42579

expected value should be
cd /Library/Tanium/TaniumClient
./TaniumClient -v
7.4.4.1250

From https://developer.bigfix.com/relevance/reference/file.html#version-of-file-version , I don’t think that Mac files have version metadata that we can query. Perhaps @jgstew can offer some help?

macOS application version information typically comes from the info.plist file that is included in the folder structure of the app bundle of the application. (.app)

Unfortunately an actual macOS binary program (as with any *nix programs as well) don’t include an inspect-able program header like Windows .exe files… For programs like this, you’ll need some other source of the version information. Perhaps use a task to run a script to output the version of this program to a file to pick up with relevance later.

The last example you posted was by running the executable program for the CLI. It calls the Tanium Client settings that are written to an SQLite database.

The version can be extracted using the sqllite table inspectors from: https://developer.bigfix.com/relevance/reference/sqlite-table.html

1 Like