Initial work to merge alert and notification endpoints

This commit is contained in:
Simone Mainardi 2020-05-14 11:04:57 +02:00
parent 8cb1bc7a34
commit 9f6c6cb315
4 changed files with 28 additions and 50 deletions

View file

@ -2,7 +2,18 @@
-- (C) 2017-20 - ntop.org
--
local email = {}
local email = {
conf_params = {
{ param_name = "smtp_server", param_type = "text", regex="[a-zA-Z0-9][a-zA-Z0-9-]{1,61}[a-zA-Z0-9](?:\\.[a-zA-Z]{2,})+" },
{ param_name = "email_sender", param_type = "email" },
{ param_name = "smtp_username", param_type = "text", optional = true },
{ param_name = "smtp_password", param_type = "password", optional = true },
},
recipient_params = {
{ param_name = "email_recipient", param_type = "email" },
{ param_name = "cc", param_type = "email", optional = true },
}
}
local json = require("dkjson")
local alert_utils = require "alert_utils"