Skip to content

Conversation

@omercier
Copy link
Contributor

@omercier omercier commented Jan 21, 2026

Description

How to use this plugin:

  • Use the discovery mode to get the applications names and IDs
  • Use the --application-id=<ID> option to specify the application you want to monitor
  • If you want the metrics to be calculated for a specific location, use the list-locations mode to get the locations names and IDs
  • Use the --location-id=<ID> option to narrow the field of data to a specific location

If you have an IT license, just use the host discovery provider and then the service discovery rule to get set.

Refs: CTOR-1961

Type of change

  • Patch fixing an issue (non-breaking change)
  • New functionality (non-breaking change)
  • Functionality enhancement or optimization (non-breaking change)
  • Breaking change (patch or feature) that might cause side effects breaking part of the Software

Checklist

  • I have followed the coding style guidelines provided by Centreon
  • I have commented my code, especially hard-to-understand areas of the PR.
  • I have rebased my development branch on the base branch (develop).
  • In case of a new plugin, I have created the new packaging directory accordingly.
  • I have implemented automated tests related to my commits.
    • Data used for automated tests are anonymized.
  • I have reviewed all the help messages in all the .pm files I have modified.
    • All sentences begin with a capital letter.
    • All sentences end with a period.
    • I am able to understand all the help messages, if not, exchange with the PO or TW to rewrite them.
  • After having created the PR, I will make sure that all the tests provided in this PR have run and passed.

@github-actions
Copy link

Logo
Checkmarx One – Scan Summary & Details0d22d9f7-a4f1-402e-b78c-05de7cfef933

New Issues (1)

Checkmarx found the following issues in this Pull Request

# Severity Issue Source File / Package Checkmarx Insight
1 MEDIUM Use_of_Broken_or_Risky_Cryptographic_Algorithm /src/apps/monitoring/zscaler/zdx/api/custom/api.pm: 74
detailsIn , the application protects sensitive data using a cryptographic algorithm, md5_hex, that is considered weak or even trivially broken, in /src/a...
Attack Vector

@omercier omercier marked this pull request as ready for review January 21, 2026 11:18
@omercier omercier requested review from a team as code owners January 21, 2026 11:18
Comment on lines +2 to +4
"dependencies": [
"libjson-perl"
]
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

appears to be useless

Comment on lines +3 to +4
"perl(DateTime)",
"perl(JSON)"
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

appears to be useless

Comment on lines +27 to +28
use DateTime;
use JSON::XS;
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

appears to be useless

foreach my $met (@$metrics) {
$data->{$met->{metric}} = -1; # -1 means no value has been recorded
LOOP_VALUES:
while ( my $dp = pop(@{$met->{datapoints}}) ) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I find this more readable, but it's just my opinion

Suggested change
while ( my $dp = pop(@{$met->{datapoints}}) ) {
foreach my $dp (reverse @{$met->{datapoints}}) {


foreach (qw(key_id key_secret)) {
$self->{output}->option_exit(short_msg => "Mandatory option '$_' is missing.") if ($self->{$_} eq '');
$self->{output}->option_exit(short_msg => "Option '$_' contains illegal characters '$1'") if ($self->{$_} =~ /([\b\f\n\r\t\"\\]+)/);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The display of the illegal character will probably not work correctly

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants