diff --git a/net-mgmt/zabbix-agent/Makefile b/net-mgmt/zabbix-agent/Makefile
index 521a2a13f..571461e96 100644
--- a/net-mgmt/zabbix-agent/Makefile
+++ b/net-mgmt/zabbix-agent/Makefile
@@ -1,5 +1,5 @@
PLUGIN_NAME= zabbix-agent
-PLUGIN_VERSION= 1.6
+PLUGIN_VERSION= 1.7
PLUGIN_COMMENT= Zabbix monitoring agent
PLUGIN_DEPENDS= zabbix4-agent
PLUGIN_MAINTAINER= opnsense@moov.de
diff --git a/net-mgmt/zabbix-agent/src/opnsense/mvc/app/controllers/OPNsense/ZabbixAgent/forms/settings.xml b/net-mgmt/zabbix-agent/src/opnsense/mvc/app/controllers/OPNsense/ZabbixAgent/forms/settings.xml
index fb6c1b5b5..7e0423a80 100644
--- a/net-mgmt/zabbix-agent/src/opnsense/mvc/app/controllers/OPNsense/ZabbixAgent/forms/settings.xml
+++ b/net-mgmt/zabbix-agent/src/opnsense/mvc/app/controllers/OPNsense/ZabbixAgent/forms/settings.xml
@@ -132,5 +132,26 @@
checkbox
+
+ zabbixagent.settings.features.encryption
+
+ checkbox
+ Enable PSK based encryption for communicating with the Zabbix server
+ true
+
+
+ zabbixagent.settings.features.encryptionidentity
+
+ text
+ >The PSK identity configured must match on agent and server
+ true
+
+
+ zabbixagent.settings.features.encryptionpsk
+
+ text
+ The PSK configured on the Zabbix server
+ true
+
diff --git a/net-mgmt/zabbix-agent/src/opnsense/mvc/app/models/OPNsense/ZabbixAgent/ZabbixAgent.xml b/net-mgmt/zabbix-agent/src/opnsense/mvc/app/models/OPNsense/ZabbixAgent/ZabbixAgent.xml
index ac4743576..aebf63777 100644
--- a/net-mgmt/zabbix-agent/src/opnsense/mvc/app/models/OPNsense/ZabbixAgent/ZabbixAgent.xml
+++ b/net-mgmt/zabbix-agent/src/opnsense/mvc/app/models/OPNsense/ZabbixAgent/ZabbixAgent.xml
@@ -1,6 +1,6 @@
//OPNsense/ZabbixAgent
- 1.2.2
+ 1.2.3
Zabbix monitoring agent
@@ -132,6 +132,20 @@
0
Y
+
+ 0
+ Y
+
+
+
+ N
+ /^.{1,128}$/
+ Should be a string between 1 and 128 characters.
+
+
+
+ N
+
diff --git a/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/+TARGETS b/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/+TARGETS
index b32508ca0..459ee772f 100644
--- a/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/+TARGETS
+++ b/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/+TARGETS
@@ -1,3 +1,4 @@
zabbix_agentd.conf:/usr/local/etc/zabbix_agentd.conf
rc.conf.d:/etc/rc.conf.d/zabbix_agentd
sudo_rules:/usr/local/etc/sudoers.d/opnsense_zabbix_agent
+zabbix_agent.psk:/usr/local/etc/zabbix_agent.psk
diff --git a/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/zabbix_agent.psk b/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/zabbix_agent.psk
new file mode 100644
index 000000000..31bb4cdbd
--- /dev/null
+++ b/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/zabbix_agent.psk
@@ -0,0 +1,5 @@
+{% if helpers.exists('OPNsense.ZabbixAgent.settings.features.encryption') and OPNsense.ZabbixAgent.settings.features.encryption != '' %}
+{% if helpers.exists('OPNsense.ZabbixAgent.settings.features.encryptionpsk') and OPNsense.ZabbixAgent.settings.features.encryptionpsk != '' %}
+{{ OPNsense.ZabbixAgent.settings.features.encryptionpsk }}
+{% endif %}
+{% endif %}
diff --git a/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/zabbix_agentd.conf b/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/zabbix_agentd.conf
index 9074bb106..9a258e07a 100644
--- a/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/zabbix_agentd.conf
+++ b/net-mgmt/zabbix-agent/src/opnsense/service/templates/OPNsense/ZabbixAgent/zabbix_agentd.conf
@@ -38,6 +38,17 @@ BufferSend={{OPNsense.ZabbixAgent.settings.tuning.bufferSend}}
BufferSize={{OPNsense.ZabbixAgent.settings.tuning.bufferSize}}
MaxLinesPerSecond={{OPNsense.ZabbixAgent.settings.tuning.maxLinesPerSecond}}
+{% if OPNsense.ZabbixAgent.settings.features.encryption == '1' %}
+{% if OPNsense.ZabbixAgent.settings.features.encryptionidentity != '' %}
+{% if OPNsense.ZabbixAgent.settings.features.encryptionpsk != '' %}
+TLSAccept=psk
+TLSConnect=psk
+TLSPSKFile=/usr/local/etc/zabbix_agent.psk
+TLSPSKIdentity={{ OPNsense.ZabbixAgent.settings.features.encryptionidentity }}
+{% endif %}
+{% endif %}
+{% endif %}
+
############ ADVANCED PARAMETERS #################
{% if helpers.exists('OPNsense.ZabbixAgent.aliases') %}