Hello guys!
My nagios command:
$USER1 $ / heck_snmp_storage -H $ HOSTADDRESS $ -C $ ARG1 $ -m $ ARG2 $ -w $ ARG3 $ -c $ ARG4 $
In the service settings, my variable $ ARG2 $ = '^ C:'
When I command save in NagiosQL, the variable $ ARG2 $ is saved like this:" '^C:'".
This causes error in ~ service checks.
I ask you how to get around this problem?
Thanks
Last edit: Benedito Ramos 2018-05-08
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
In 3.4.0 I have improved the security by using php filters for data fields. So, something could be not optimal yet. I have slightely modified the filter now with "FILTER_FLAG_NO_ENCODE_QUOTES" for the argument fields. I hope this will help you.
Martin,
I'm having this same problem on Free Variables on Hosts and Services. Including a single or double quote in the Variable Value field, it's converted to ASCII. I have updated my prepend_content.php file and also tried reinstalling 3.4.0 with no luck.
If you would like to refer to this comment somewhere else in this project, copy and paste the following link:
Hello guys!
My nagios command:
$USER1 $ / heck_snmp_storage -H $ HOSTADDRESS $ -C $ ARG1 $ -m $ ARG2 $ -w $ ARG3 $ -c $ ARG4 $
In the service settings, my variable $ ARG2 $ = '^ C:'
When I command save in NagiosQL, the variable $ ARG2 $ is saved like this:" '^C:'".
This causes error in ~ service checks.
I ask you how to get around this problem?
Thanks
Last edit: Benedito Ramos 2018-05-08
Hello Benedito
In 3.4.0 I have improved the security by using php filters for data fields. So, something could be not optimal yet. I have slightely modified the filter now with "FILTER_FLAG_NO_ENCODE_QUOTES" for the argument fields. I hope this will help you.
Simply download version 3.4.0 from here again (which is updated) or download the single file functions/prepend_content.php from https://gitlab.com/wizonet/nagiosql/tree/3.4.0 and try.
Hello, Martin.
I replaced the file "prepend_content.php" as you instructed and the problem was solved. :)
Thanks for the quick response.
Diramos
Martin,
I'm having this same problem on Free Variables on Hosts and Services. Including a single or double quote in the Variable Value field, it's converted to ASCII. I have updated my prepend_content.php file and also tried reinstalling 3.4.0 with no luck.
This case (free variables) will be fixed in version 3.4.1