File

mod_auth_external_insecure/examples/lua/prosody-auth-example.lua @ 6249:12a2989c7cc1

mod_limits_exception: obsolete diff --git a/mod_limits_exception/README.md b/mod_limits_exception/README.md --- a/mod_limits_exception/README.md +++ b/mod_limits_exception/README.md @@ -1,6 +1,8 @@ --- +labels: +- Stage-Obsolete summary: Allow specified JIDs to bypass rate limits -... +--- This module allows you to configure a list of JIDs that should be allowed to bypass rate limit restrictions.
author Menel <menel@snikket.de>
date Mon, 12 May 2025 10:57:17 +0200
parent 3884:f84ede3e9e3b
line wrap: on
line source

local actions = {};

function actions.auth(data)
	local user, host, pass = data:match("^([^:]+):([^:]+):(.+)$");
	if user == "someone" then
		return "1";
	end
end

for line in io.lines() do
	local action, data = line:match("^([^:]+)(.*)$");
	print(actions[action] and actions[action](data) or "0");
end