Hi all.
I am trying to add some custom php scripts to the Zabbix UI (For example, I wish to be able to upload an artifact (Java ear/war file) to the Zabbix server directly, so that I can later manipulate it via Zabbix remote-agent calls etc.), and was looking for a simple way to integrate the authentication of these into the existing Zabbix mechanism?
For instance, if I have a file called say uploadFile.php (See below) and I dump this directly to my /var/www/html/zabbix directory, I can then hit this URL directly via say https://zbxserver.domainname.com/uploadFile.php. This all works fine, but is obviously outside of the Zabbix user management system and as such anyone can access this page without auth in place. What I'd like to be able to do is tie it into the existing RBAC system that Zabbix maintains. i.e. if I'm already logged into Zabbix as a Zabbix Administrator (Or indeed a user from a particular user group) then I'd like to be able to access this page. Otherwise, I should get the standard auth error message
"You are not logged in.
You must login to view this page.
If you think this message is wrong, please consult your administrators about getting the necessary permissions."
Any ideas on how best to implement something like this?
Thanks in advance,
M
I am trying to add some custom php scripts to the Zabbix UI (For example, I wish to be able to upload an artifact (Java ear/war file) to the Zabbix server directly, so that I can later manipulate it via Zabbix remote-agent calls etc.), and was looking for a simple way to integrate the authentication of these into the existing Zabbix mechanism?
For instance, if I have a file called say uploadFile.php (See below) and I dump this directly to my /var/www/html/zabbix directory, I can then hit this URL directly via say https://zbxserver.domainname.com/uploadFile.php. This all works fine, but is obviously outside of the Zabbix user management system and as such anyone can access this page without auth in place. What I'd like to be able to do is tie it into the existing RBAC system that Zabbix maintains. i.e. if I'm already logged into Zabbix as a Zabbix Administrator (Or indeed a user from a particular user group) then I'd like to be able to access this page. Otherwise, I should get the standard auth error message
"You are not logged in.
You must login to view this page.
If you think this message is wrong, please consult your administrators about getting the necessary permissions."
Any ideas on how best to implement something like this?
Thanks in advance,
M