aboutsummaryrefslogtreecommitdiffstats
path: root/util/dependencies.lua
diff options
context:
space:
mode:
Diffstat (limited to 'util/dependencies.lua')
-rw-r--r--util/dependencies.lua18
1 files changed, 17 insertions, 1 deletions
diff --git a/util/dependencies.lua b/util/dependencies.lua
index 109a3332..ea19d9a8 100644
--- a/util/dependencies.lua
+++ b/util/dependencies.lua
@@ -49,6 +49,14 @@ package.preload["util.ztact"] = function ()
end;
function check_dependencies()
+ if _VERSION ~= "Lua 5.1" then
+ print "***********************************"
+ print("Unsupported Lua version: ".._VERSION);
+ print("Only Lua 5.1 is supported.");
+ print "***********************************"
+ return false;
+ end
+
local fatal;
local lxp = softreq "lxp"
@@ -140,7 +148,15 @@ function log_warnings()
if not pcall(lxp.new, { StartDoctypeDecl = false }) then
log("error", "The version of LuaExpat on your system leaves Prosody "
.."vulnerable to denial-of-service attacks. You should upgrade to "
- .."LuaExpat 1.1.1 or higher as soon as possible. See "
+ .."LuaExpat 1.3.0 or higher as soon as possible. See "
+ .."http://prosody.im/doc/depends#luaexpat for more information.");
+ end
+ if not lxp.new({}).getcurrentbytecount then
+ log("error", "The version of LuaExpat on your system does not support "
+ .."stanza size limits, which may leave servers on untrusted "
+ .."networks (e.g. the internet) vulnerable to denial-of-service "
+ .."attacks. You should upgrade to LuaExpat 1.3.0 or higher as "
+ .."soon as possible. See "
.."http://prosody.im/doc/depends#luaexpat for more information.");
end
end