10. Using audit data into plugins for WAPT package compliance and for external services ¶
10.1. Displaying host audit data in the WAPT Console ¶
You can manage audit output and display the audit result if you activate the option in the View ‣ Display Preferences Tab.
Check the Show host audit data tab to see the tab Audit Data on each client.
10.1.1. Displaying encrypted data with a certificate in the audit data tab¶
With audit function, it is possible to encrypt sensitive data coming from remote hosts; it will be possible to read the encrypted sensitive with a certificate installed on the WAPT Administrator’s host.
This way, the WAPT Server may store sensitive inventory data without the WAPT Server becoming a sensitive asset.
This method is particularly useful for example for securely managing LAPS random passwords in WAPT.
In setup.py, you can use a function to encrypt data with a certificate.
If you have the private key matching the certificate that was used to encrypt the data, the data will be decrypted and it will appear in a readable form.
This code will encrypt the password 1234 with all certificates present on the host that is used to manage WAPT.
From the WAPT Console, you will see in the audit_data tab the crypted version and you can decipher the data with your private key associated to the public certificate that was used to encrypt the data.
WAPT Enterprise offers synchronization between the inventories of your hosts and GLPI ITSM Software.
The method automatically synchronizes changes on your IT infrastructure with the GLPI server.
WAPT can synchronize with GLPI 10 using the native JSON API. WAPT can synchronize with GLPI version 9.x using the FusionInventory plugin with XML format.
Download the tis-glpi-agent package from the WAPT store and add it as a dependency to your host packages. This ensures the agent is automatically installed and upgraded on all targeted machines.
Attention
GPLI on WAPT does not work with Kerberos authentification for GLPI.
If you use Kerberos for GLPI, exclude glpi/plugins/fusioninventory/ from the Nginx authentification.
Hint
If you experience issues with GLPI server not receiving parts of inventories, you can install the package tis-audit-glpi-inventory on clients.
In this way, you will get the official GLPI inventory.
Read the content of the usageandnotes file and follow the instructions provided to complete the configuration.
Warning
Installing the required dependencies for GLPI 9.x
In order to receive inventories on the GLPI server, the FusionInventory plugin will need to be installed
on the GLPI server. This is not required for GLPI 10 which has its own native JSON API.
10.2.4. Possible errors in reported inventory on the GLPI server¶
Inventories uploaded by the WAPT Server to the GLPI server may be incomplete or may have errors when compared to inventories uploaded directly by the FusionInventory agent deployed on hosts. One reason is that WAPT aims to report only the most important values.
If you feel that important items are missing or are reported in a wrong way, please report the issue to the Tranquil IT dev team.
To report the issue, you will need to send 2 .xml files.
First, install the FusionInventory agent on the computer on which you are observing a missing or wrongly reported inventory item.
Run the FusionInventory agent and extract the report into a .xml file.
WAPT Enterprise offers synchronization between the inventories of your hosts and Cyberwatch ISVM Software.
The method automatically synchronizes information about updates or installed softwares to Cyberwatch tool in order to scan and alert you about detected vulnerabilities.
Install and configure the WAPT Agent on the computer that will run the synchronization. The WAPTAgent
is installed by default on the WAPTServer, it just need to be configured.
To configure the WAPTAgent, please refer to the corresponding documentation.
Yu can have two packages :
if you have the Cyberwatch agent, you can import from Cyberwatch installing the package tis-cyberwatch-plugin-import-from-cyberwatch, it will give you information directly on your WAPT Console.
for agentless devices, you still can export to your Cyberwatch server information of you WAPT hosts installing the package tis-cyberwatch-plugin-export-to-cyberwatch-airgap, it will give you information to your Cyberwatch Console without Cyberwatch agent installed.
You need to configure an audit schedule on the agent
[global]...waptaudit_task_period=120m...
With the package, whichever you chose (you can oblviously choose both), it will create two ini files in your $WAPT_INSTALL_DIR/private (linux : /opt/wapt/private, windows : C:ProgramFiles(x86)waptprivate`).
Connect to the host and modify cyberwatch_api.ini and wapt_api.ini files.
WAPT can collect detailed hardware and software audit data from client machines using the audit_data plugin.
The collected data includes system information such as:
The collected data includes system information such as installed software, running services, disk usage, user accounts, network configuration, and more.
This data is stored in structured JSON format and displayed in the WAPT console using HTML templates.
By default, WAPT provides generic templates to visualize this data. However, these templates can be fully customized to match your needs.
Audit report customization lets you focus on data specific to your organization
Create dashboards or tables adapted to internal policies, Improve readability and ease of use for technical support teams, Generate better documentation for audits or compliance.
WAPT uses Mustache templates to render JSON data into structured HTML content inside the console.
And the values for the placeholders are provided in a JSON object (this object is called the rendering context – it holds the data passed to the template):
<divclass="system-info">
Hostname: PC123<br>
Operating System: Windows 10
</div>
This basic example shows how Mustache replaces each {{placeholder}} with the matching value from the JSON context. There is no logic, only substitution.
Use {{key}} to insert a single value from the rendering context into the template.
The value of the key hostname will be searched for in the current context (and if not found, in any parent context). When a value is found, the entire tag is replaced with the value, properly HTML-escaped to avoid injection.
This syntax allows you to display a block of content only if the value of the key exists and is considered “truthy” (not null, false, or empty). It’s commonly used to conditionally render a section, or to iterate over a list.
Example with an object
JSON context:
{"user":{"name":"Alice"}}
Template:
{{#user}}
<p>User: {{name}}</p>
{{/user}}
Rendered result:
<p>User: Alice</p>
If the user key was missing or null, nothing would be rendered.
Example with a list
If the value of the section is a list (array), the block is rendered once for each item, with the context set to the current item.
The inverse section {{^section}} is used to show a block only if the value is falsy – meaning it does not exist, is false, null, or an empty list. This is useful to display fallback messages or “no data” indicators.
JSON context:
{"has_battery":false}
Template:
{{^has_battery}}
<p>This device has no battery.</p>
{{/has_battery}}
Rendered result:
<p>This device has no battery.</p>
If “has_battery”: true, the block would not be rendered at all.
10.4.3.2.4. Comment –
{{! comment }}¶Mustache allows inline comments using {{! … }}. These comments are completely ignored during rendering and will not appear in the output HTML.
This is useful for leaving notes for template authors without affecting the output.
Template:
{{! This is a comment for developers }} <p>Hello</p>Rendered result: