Tanium Good Governance: Content Promotion Workflow

Tanium is a powerful tool for managing endpoints across enterprises. With this power comes responsibility: it is a sensible policy to thoroughly test and review content before it is placed into a production environment. What follows is a set of recommended practices on how to develop content for use in a production environment, and to make sure that only approved content is added and ultimately run in that environment.

Workflow Steps

  • Develop the content in a development environment

  • Request promotion of content to a higher environment (QAT, Production,etc.) 

  • Review promotion request

  • Sign approved content

  • Import approved content 

Throughout this process, production environment stability and security are maintained through role separation. Two roles are addressed in this workflow: Content developer and Tanium Administrator. It is important to note that best practice is to have these roles occupied by two different people, to allow for proper review and approval cycles. 

Create content in a development environment

In this article, content refers to sensors or packages that are executed on endpoints. These should be developed by the content developer in an isolated environment with limited access to content sets and computer groups. The DEV environment will necessarily be smaller than your production environment, but it should consist of a mix of machines and operating systems similar to that which is found in your production environment. Do not place production servers in the test environment; any machines within the test environment should expect and be able to handle downtime as a result of content testing.

Specific guidance on how to write code or content for Tanium is beyond the scope of this document. However, below are a good set of practices to follow when you are creating content for Tanium: 

  1. Develop your code with the production environment in mind. For example, if your code accesses network resources, what will be the effect of hundreds or thousands of machines accessing that resource at once? It’s also important to understand that the code will be running as SYSTEM, potentially in a 32 bit context. 

  2. Make sure it works as expected, every time. Test not just the expected cases, but unusual cases as well. For example, what happens if an endpoint runs your code multiple times in rapid succession? What if it can't access a resource that it expects, like a file or the registry - does it fail gracefully? Be sure to include actionable error messages.  Some coding languages support the use of exception handling - is your code utilizing this functionality? 

  3. Start testing on one machine and then add a few more machines to the test group.  

  • Does it still run as expected on all of the test machines?

  • How long does it take to run? If your content is a sensor, check Sensor Execution Time. Is it completing in less than 1 second?

Add more machines to the test group and continue to evaluate the results. Something that runs in an expected way on one machine may produce different results on other machines. 

  1. Document your code. What is it expected to do, how does it accomplish the task, what limitations should be placed on it? Note whether it can be targeted to All Computers, or should be targeted to a smaller subset. For sensors, document an expected execution time. For packages, test for and document any recommendations for "Distribute over" values. Add descriptions of the content where relevant.

  2. Have a peer review and test the code. The peer should verify the results and execution times.

  3. For Sensors, consider the max data age and unique strings. Set the max data age so that the code is not evaluated more than necessary. In general, try to limit the uniqueness of strings that a sensor can return. If the sensor will return unique data, you can set the max string age or number of strings that Tanium will preserve, which will conserve RAM and disk space on the Tanium server.

Once you and your peers are satisfied that the code is ready to move into production, export the content in preparation for the next step.

Note:

For additional best practices for authoring sensors, see this article: 8 Best Practices for writing Sensors

Request promotion of content to production

When testing is complete, the Content Developer should request that the Tanium Administrator place the content into the Tanium production environment. The request should contain the following:

  • Purpose/requestors of the content (why existing content does not meet the needs of the business)

  • Testing scope and results

  • The exported XML file

  • Any necessary targeting limits

  • Proposed targeting, which may be different from the targeting limits

  • Content visibility - what content set the content should be added to, with a view towards who should have access to run this content

Review promotion request

The Tanium Administrator should review the request, the testing results, and the content limitations. The administrator may want to test the content themselves in the DEV environment before approving.

Once the Tanium Administrator is satisfied with the content, the content can be signed and imported.

Sign approved content

The Tanium Console supports importing content such as sensors and packages as XML files. However, content to be imported into the Tanium Server requires a digital signature. This means that only approved content can be added to the Tanium production environment. 

Strict key management allows for only approved individuals, such as the Tanium Administrator, to sign content for importing into the production environment.

Import approved content

Once the content has been signed the Tanium Administrator can import the content into the production environment. Only the Tanium Administrator should have the right to import content.  The content should be added to the appropriate content set, limiting access and scope through RBAC. 

Continue to Curate

Continue to review existing content and ensure it is required for your environment and runs with optimal performance. There are several Tanium tools you can use to check the runtime and health of sensors. In addition, it is good practice to periodically review code to ensure its necessity (i.e. Tanium did not create content for this purpose or the original reason for developing the content no longer exists).