summaryrefslogtreecommitdiffstats
path: root/authenticator-freeswitch-vmail.lua
diff options
context:
space:
mode:
Diffstat (limited to 'authenticator-freeswitch-vmail.lua')
-rw-r--r--authenticator-freeswitch-vmail.lua17
1 files changed, 10 insertions, 7 deletions
diff --git a/authenticator-freeswitch-vmail.lua b/authenticator-freeswitch-vmail.lua
index 423121d..14c3f2f 100644
--- a/authenticator-freeswitch-vmail.lua
+++ b/authenticator-freeswitch-vmail.lua
@@ -1,25 +1,26 @@
-- Copy of authenticator-plaintext, plus added authentication from voicemail DB
-module (..., package.seeall)
+local mymodule = {}
+authenticator = require("authenticator")
md5 = require("md5")
-list_fields = function(self, tabl)
+mymodule.list_fields = function(self, tabl)
return nil
end
-read_field = function(self, tabl, field)
+mymodule.read_field = function(self, tabl, field)
return nil
end
-delete_field = function(self, tabl, field)
+mymodule.delete_field = function(self, tabl, field)
return false
end
-write_entry = function(self, tabl, field, id, entry)
+mymodule.write_entry = function(self, tabl, field, id, entry)
return false
end
-read_entry = function(self, tabl, field, id)
+mymodule.read_entry = function(self, tabl, field, id)
local result
if tabl == authenticator.usertable and field == "" then
-- authenticator is reading one user
@@ -33,6 +34,8 @@ read_entry = function(self, tabl, field, id)
return result
end
-delete_entry = function (self, tabl, field, id)
+mymodule.delete_entry = function (self, tabl, field, id)
return false
end
+
+return mymodule