-
Change Request
-
Resolution: Duplicate
-
Major
-
None
-
None
-
None
-
php 5.2.12
First. we need alter table (example for psql)
ALTER TABLE scripts add isbase64 smallint default 0;
ALTER TABLE scripts add isfile smallint default 0;
ALTER TABLE scripts add ctype varchar(255) default 0;
ALTER TABLE scripts add filename varchar(255) default 0;
Then update affect files:
include/scripts.inc.php
include/locales/en_gb.inc.php
/scripts.php
/sysmaps.php
/scripts_exec_file.php
After this in Administration->scripts we will be able configure script for outputted it as file. And if output will be base64 encoding data, configure that will be decoded in php web interface. Also filename and content-type available.
For example we can configure script as /usr/bin/ssh -i /home/zabbix/.ssh/id_rsa root@
{HOST.CONN}"(ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; ps aux; )| bzip2 | base64" and as output get correct bzip file