summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--snort-controller.lua13
-rw-r--r--snort-details-html.lsp1
-rw-r--r--snort-model.lua10
l---------snort-startstop-html.lsp1
4 files changed, 9 insertions, 16 deletions
diff --git a/snort-controller.lua b/snort-controller.lua
index 828e10f..1ee4a63 100644
--- a/snort-controller.lua
+++ b/snort-controller.lua
@@ -1,14 +1,5 @@
module (..., package.seeall)
--- Load libraries
-require("controllerfunctions")
-
--- ################################################################################
--- LOCAL FUNCTIONS
-
--- ################################################################################
--- PUBLIC FUNCTIONS
-
default_action = "status"
function status(self)
@@ -20,10 +11,10 @@ function details(self)
end
function startstop(self)
- return controllerfunctions.handle_startstop(self, self.model.startstop_service, self.clientdata)
+ return self.handle_form(self, self.model.get_startstop, self.model.startstop_service, self.clientdata)
end
function expert(self)
- return controllerfunctions.handle_form(self, self.model.get_filedetails, self.model.update_filedetails, self.clientdata, "Save", "Edit Configuration", "Configuration Set")
+ return self.handle_form(self, self.model.get_filedetails, self.model.update_filedetails, self.clientdata, "Save", "Edit Configuration", "Configuration Set")
end
diff --git a/snort-details-html.lsp b/snort-details-html.lsp
index 075ddbf..879041d 100644
--- a/snort-details-html.lsp
+++ b/snort-details-html.lsp
@@ -1,5 +1,4 @@
<% local data, viewlibrary = ...
-require("viewfunctions")
%>
<% viewlibrary.dispatch_component("status") %>
diff --git a/snort-model.lua b/snort-model.lua
index 2e54202..2c3a980 100644
--- a/snort-model.lua
+++ b/snort-model.lua
@@ -3,7 +3,7 @@ module (..., package.seeall)
-- Load libraries
require("modelfunctions")
-require("fs")
+fs = require("acf.fs")
-- Set variables
local packagename = "snort"
@@ -21,8 +21,12 @@ function getstatus()
return modelfunctions.getstatus(processname, packagename, "Snort Status")
end
-function startstop_service(action)
- return modelfunctions.startstop_service(processname, action)
+function get_startstop(clientdata)
+ return modelfunctions.get_startstop(processname)
+end
+
+function startstop_service(startstop, action)
+ return modelfunctions.startstop_service(startstop, action)
end
function read_alert()
diff --git a/snort-startstop-html.lsp b/snort-startstop-html.lsp
deleted file mode 120000
index 0ea2627..0000000
--- a/snort-startstop-html.lsp
+++ /dev/null
@@ -1 +0,0 @@
-../startstop-html.lsp \ No newline at end of file