PlexTrac offers a variety of templates that play a role in various aspects of the creation, generation, and export of a report. These templates encompass findings layout templates, findings templates, and style guides.
Plextrac looks for three templates when exporting a report: A report template (required), an export template (required), and a findings layout.
Report Templates: Contains all the custom narratives and custom fields specific to a given report and ensures that custom narratives and custom fields are automatically populated when generating a report.
Export Templates: Incorporates the selected template. This file must have been previously uploaded to the PlexTrac instance to leverage a self-serve template. A default template is used when exporting a report if no template is explicitly associated, so ensure the proper template is assigned.
Layout Templates: Encompasses all the finding custom fields utilized within a particular PlexTrac Report. Correct setup of this layout ensures the seamless application of custom fields to report findings upon their creation within PlexTrac.
A Jinja template likely uses report custom fields, narrative sections, and findings custom fields. Exporting this data from PlexTrac depends on adequately setting up this data from the appropriate template. Click the links on this page to visit product documentation for more information and instructions on setting up and exporting templates.
To understand how these templates are employed within the platform, a typical use case showing the process from end-to-end for using a report export template is provided.
Step 1: Download a report export template from this section, such as the ISO 27001 template.
Step 2: Log in to PlexTrac as an admin, go to the Admin Dashboard, and click Templates under "Customization."
Step 3: Click the Export templates tab.
Step 4: Click New export template.
Step 5: Drag the ISO 27001 template file to the box provided or click the box in the modal to find the file to upload on the computer.
Step 6: Select a style guide to apply, if applicable.
Step 7: Click Upload.
Step 8: Click the Report Templates tab.
Step 9: Click New report template.
Step 10: Enter a template name and select the ISO 27001 template from the pulldown menu.
Step 11: Click Create.
Visit the Creating a Report page for more information on creating custom fields and adding a narrative section. Visit the Editing a Report page for information on editing fields and narrative sections of existing reports.
Step 12: Go to the Reports module and find the report to export. Click the row.
Step 13: Click the Details tab.
Step 14: In the "Report Template" field, select the template created earlier in Step 10, and then choose a template for "Findings Layout." Click Save.
Step 15: Click Export and select Word.
Custom fields within a report are indispensable tools for enhancing the report's tags and personalization. These fields are commonly integrated into the cover page, allowing for the inclusion of dynamic information such as author names or specific data points relevant to the report's audience.
The user must access the Set Up code area to incorporate custom fields into a pre-built report export template. This coding section holds the blueprint for the report's layout and content, enabling users to define data sources, set display properties, and establish conditional logic for the custom fields.
Visit the Creating a Report page for more information on creating custom fields.
Report custom fields are exclusively utilized on the cover pages. Remove the Jinja calls from their cover page within the template if not needed.
The following custom fields are pre-defined in the Set Up code section of a pre-built report export template.
To retrieve the values of a report's custom fields, one must follow a specific two-step procedure and insert two lines of code within the Set Up Code section for each custom field.
Firstly, the user passes the label of the field as an argument to the function set_report_field_variable
. This function is responsible for storing the value of the custom field. Secondly, the user creates a variable in the format ss.<my_label_name>
and assigns it the value stored in "ss.report_field_value" using the command {{p set ss.my_label_name = ss.report_field_value }}
.
Step 1: Navigate to the "REPORT CUSTOM FIELD SETUP" code section, found at the end of the Set Up code of the report export template.
Step 2: Place the cursor after the last set of highlighted text.
Step 3: Click Enter to create a new line for entering code.
Step 4: Insert the label of the custom field into the function "set_report_field_variable" with this syntax:{{p set_report_field_variable("FooBar")}}
. This action stores the value of the custom field in the global variable ss.report_field_value
.
Step 5: Click Enter and insert the second line: {{p set ss.my_label_name = ss.report_field_value }}
, which creates the variable and assigns it the value of ss.report_field_value
with a single command.
{{p set_report_field_variable(“Lead Penetration Tester”)}}
{{p set ss.lead_pentester = ss.report_field_value }}
{{p set_report_field_variable(“Version”)}}
{{p set ss.version = ss.report_field_value }}
Once the custom field value has been retrieved, it can be displayed using the display command and the variable name. It is important to note that this data type is compatible with static text.
{{ ss.<my_variable_name>}}
Team Lead: {{ ss.team_lead }}
Team Lead Title: {{ ss.team_lead_title }}
Custom Field Label | Jinja Reference |
---|---|
Author
{{ ss.author }}
Author Title
{{ ss.author_title }}
Author Email
{{ ss.author_email }}
Author Phone
{{ ss.author_phone }}
Company Name
{{ ss.company_name }}
Company Address
{{ ss.company_address }}