Changeset

12977:74b9e05af71e

plugins: Prefix module imports with prosody namespace
author Kim Alvefur <zash@zash.se>
date Fri, 24 Mar 2023 13:15:28 +0100
parents 12976:a187600ec7d6
children 12978:088d278c75b5
files plugins/adhoc/adhoc.lib.lua plugins/adhoc/mod_adhoc.lua plugins/mod_admin_adhoc.lua plugins/mod_admin_shell.lua plugins/mod_admin_socket.lua plugins/mod_admin_telnet.lua plugins/mod_announce.lua plugins/mod_auth_anonymous.lua plugins/mod_auth_insecure.lua plugins/mod_auth_internal_hashed.lua plugins/mod_auth_internal_plain.lua plugins/mod_auth_ldap.lua plugins/mod_authz_internal.lua plugins/mod_blocklist.lua plugins/mod_bookmarks.lua plugins/mod_bosh.lua plugins/mod_c2s.lua plugins/mod_carbons.lua plugins/mod_component.lua plugins/mod_cron.lua plugins/mod_csi.lua plugins/mod_csi_simple.lua plugins/mod_debug_reset.lua plugins/mod_debug_stanzas/watcher.lib.lua plugins/mod_dialback.lua plugins/mod_disco.lua plugins/mod_external_services.lua plugins/mod_groups.lua plugins/mod_http.lua plugins/mod_http_errors.lua plugins/mod_http_file_share.lua plugins/mod_http_files.lua plugins/mod_http_openmetrics.lua plugins/mod_invites.lua plugins/mod_invites_adhoc.lua plugins/mod_invites_register.lua plugins/mod_iq.lua plugins/mod_lastactivity.lua plugins/mod_legacyauth.lua plugins/mod_limits.lua plugins/mod_mam/mamprefsxml.lib.lua plugins/mod_mam/mod_mam.lua plugins/mod_message.lua plugins/mod_mimicking.lua plugins/mod_motd.lua plugins/mod_muc_mam.lua plugins/mod_muc_unique.lua plugins/mod_net_multiplex.lua plugins/mod_offline.lua plugins/mod_pep.lua plugins/mod_pep_simple.lua plugins/mod_ping.lua plugins/mod_posix.lua plugins/mod_presence.lua plugins/mod_private.lua plugins/mod_proxy65.lua plugins/mod_pubsub/mod_pubsub.lua plugins/mod_pubsub/pubsub.lib.lua plugins/mod_register_ibr.lua plugins/mod_register_limits.lua plugins/mod_roster.lua plugins/mod_s2s.lua plugins/mod_s2s_auth_certs.lua plugins/mod_s2s_bidi.lua plugins/mod_saslauth.lua plugins/mod_scansion_record.lua plugins/mod_server_contact_info.lua plugins/mod_smacks.lua plugins/mod_stanza_debug.lua plugins/mod_storage_internal.lua plugins/mod_storage_memory.lua plugins/mod_storage_sql.lua plugins/mod_storage_xep0227.lua plugins/mod_time.lua plugins/mod_tls.lua plugins/mod_tokenauth.lua plugins/mod_tombstones.lua plugins/mod_turn_external.lua plugins/mod_uptime.lua plugins/mod_user_account_management.lua plugins/mod_vcard.lua plugins/mod_vcard4.lua plugins/mod_vcard_legacy.lua plugins/mod_version.lua plugins/mod_watchregistrations.lua plugins/mod_websocket.lua plugins/mod_welcome.lua plugins/muc/hats.lib.lua plugins/muc/history.lib.lua plugins/muc/lock.lib.lua plugins/muc/members_only.lib.lua plugins/muc/mod_muc.lua plugins/muc/muc.lib.lua plugins/muc/occupant.lib.lua plugins/muc/occupant_id.lib.lua plugins/muc/password.lib.lua plugins/muc/presence_broadcast.lib.lua plugins/muc/register.lib.lua plugins/muc/request.lib.lua plugins/muc/subject.lib.lua
diffstat 100 files changed, 499 insertions(+), 499 deletions(-) [+]
line wrap: on
line diff
--- a/plugins/adhoc/adhoc.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/adhoc/adhoc.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -4,7 +4,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st, uuid = require "util.stanza", require "util.uuid";
+local st, uuid = require "prosody.util.stanza", require "prosody.util.uuid";
 
 local xmlns_cmd = "http://jabber.org/protocol/commands";
 
--- a/plugins/adhoc/mod_adhoc.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/adhoc/mod_adhoc.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -5,9 +5,9 @@
 -- COPYING file in the source package for more information.
 --
 
-local it = require "util.iterators";
-local st = require "util.stanza";
-local jid_host = require "util.jid".host;
+local it = require "prosody.util.iterators";
+local st = require "prosody.util.stanza";
+local jid_host = require "prosody.util.jid".host;
 local adhoc_handle_cmd = module:require "adhoc".handle_cmd;
 local xmlns_cmd = "http://jabber.org/protocol/commands";
 local commands = {};
--- a/plugins/mod_admin_adhoc.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_admin_adhoc.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -14,25 +14,25 @@
 
 local module_host = module:get_host();
 
-local keys = require "util.iterators".keys;
-local usermanager_user_exists = require "core.usermanager".user_exists;
-local usermanager_create_user = require "core.usermanager".create_user;
-local usermanager_delete_user = require "core.usermanager".delete_user;
-local usermanager_disable_user = require "core.usermanager".disable_user;
-local usermanager_enable_user = require "core.usermanager".enable_user;
-local usermanager_set_password = require "core.usermanager".set_password;
-local hostmanager_activate = require "core.hostmanager".activate;
-local hostmanager_deactivate = require "core.hostmanager".deactivate;
-local rm_load_roster = require "core.rostermanager".load_roster;
-local st, jid = require "util.stanza", require "util.jid";
-local timer_add_task = require "util.timer".add_task;
-local dataforms_new = require "util.dataforms".new;
-local array = require "util.array";
-local modulemanager = require "core.modulemanager";
+local keys = require "prosody.util.iterators".keys;
+local usermanager_user_exists = require "prosody.core.usermanager".user_exists;
+local usermanager_create_user = require "prosody.core.usermanager".create_user;
+local usermanager_delete_user = require "prosody.core.usermanager".delete_user;
+local usermanager_disable_user = require "prosody.core.usermanager".disable_user;
+local usermanager_enable_user = require "prosody.core.usermanager".enable_user;
+local usermanager_set_password = require "prosody.core.usermanager".set_password;
+local hostmanager_activate = require "prosody.core.hostmanager".activate;
+local hostmanager_deactivate = require "prosody.core.hostmanager".deactivate;
+local rm_load_roster = require "prosody.core.rostermanager".load_roster;
+local st, jid = require "prosody.util.stanza", require "prosody.util.jid";
+local timer_add_task = require "prosody.util.timer".add_task;
+local dataforms_new = require "prosody.util.dataforms".new;
+local array = require "prosody.util.array";
+local modulemanager = require "prosody.core.modulemanager";
 local core_post_stanza = prosody.core_post_stanza;
-local adhoc_simple = require "util.adhoc".new_simple_form;
-local adhoc_initial = require "util.adhoc".new_initial_data_form;
-local set = require"util.set";
+local adhoc_simple = require "prosody.util.adhoc".new_simple_form;
+local adhoc_initial = require "prosody.util.adhoc".new_initial_data_form;
+local set = require"prosody.util.set";
 
 module:depends("adhoc");
 local adhoc_new = module:require "adhoc".new;
--- a/plugins/mod_admin_shell.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_admin_shell.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -10,39 +10,39 @@
 module:set_global();
 module:depends("admin_socket");
 
-local hostmanager = require "core.hostmanager";
-local modulemanager = require "core.modulemanager";
-local s2smanager = require "core.s2smanager";
-local portmanager = require "core.portmanager";
-local helpers = require "util.helpers";
-local server = require "net.server";
-local st = require "util.stanza";
+local hostmanager = require "prosody.core.hostmanager";
+local modulemanager = require "prosody.core.modulemanager";
+local s2smanager = require "prosody.core.s2smanager";
+local portmanager = require "prosody.core.portmanager";
+local helpers = require "prosody.util.helpers";
+local server = require "prosody.net.server";
+local st = require "prosody.util.stanza";
 
 local _G = _G;
 
 local prosody = _G.prosody;
 
 local unpack = table.unpack;
-local iterators = require "util.iterators";
+local iterators = require "prosody.util.iterators";
 local keys, values = iterators.keys, iterators.values;
-local jid_bare, jid_split, jid_join, jid_resource = import("util.jid", "bare", "prepped_split", "join", "resource");
-local set, array = require "util.set", require "util.array";
-local cert_verify_identity = require "util.x509".verify_identity;
-local envload = require "util.envload".envload;
-local envloadfile = require "util.envload".envloadfile;
-local has_pposix, pposix = pcall(require, "util.pposix");
-local async = require "util.async";
-local serialization = require "util.serialization";
+local jid_bare, jid_split, jid_join, jid_resource = import("prosody.util.jid", "bare", "prepped_split", "join", "resource");
+local set, array = require "prosody.util.set", require "prosody.util.array";
+local cert_verify_identity = require "prosody.util.x509".verify_identity;
+local envload = require "prosody.util.envload".envload;
+local envloadfile = require "prosody.util.envload".envloadfile;
+local has_pposix, pposix = pcall(require, "prosody.util.pposix");
+local async = require "prosody.util.async";
+local serialization = require "prosody.util.serialization";
 local serialize_config = serialization.new ({ fatal = false, unquoted = true});
-local time = require "util.time";
-local promise = require "util.promise";
-local logger = require "util.logger";
+local time = require "prosody.util.time";
+local promise = require "prosody.util.promise";
+local logger = require "prosody.util.logger";
 
 local t_insert = table.insert;
 local t_concat = table.concat;
 
-local format_number = require "util.human.units".format;
-local format_table = require "util.human.io".table;
+local format_number = require "prosody.util.human.units".format;
+local format_table = require "prosody.util.human.io".table;
 
 local function capitalize(s)
 	if not s then return end
@@ -696,7 +696,7 @@
 
 def_env.config = {};
 function def_env.config:load(filename, format)
-	local config_load = require "core.configmanager".load;
+	local config_load = require "prosody.core.configmanager".load;
 	local ok, err = config_load(filename, format);
 	if not ok then
 		return false, err or "Unknown error loading config";
@@ -708,7 +708,7 @@
 	if key == nil then
 		host, key = "*", host;
 	end
-	local config_get = require "core.configmanager".get
+	local config_get = require "prosody.core.configmanager".get
 	return true, serialize_config(config_get(host, key));
 end
 
@@ -1506,7 +1506,7 @@
 	end
 end
 
-local um = require"core.usermanager";
+local um = require"prosody.core.usermanager";
 
 def_env.user = {};
 function def_env.user:create(jid, password, role)
@@ -1677,7 +1677,7 @@
 
 def_env.xmpp = {};
 
-local new_id = require "util.id".medium;
+local new_id = require "prosody.util.id".medium;
 function def_env.xmpp:ping(localhost, remotehost, timeout)
 	localhost = select(2, jid_split(localhost));
 	remotehost = select(2, jid_split(remotehost));
@@ -1729,7 +1729,7 @@
 end
 
 def_env.dns = {};
-local adns = require"net.adns";
+local adns = require"prosody.net.adns";
 
 local function get_resolver(session)
 	local resolver = session.dns_resolver;
@@ -1872,7 +1872,7 @@
 	local events_obj;
 	if host and host ~= "*" then
 		if host == "http" then
-			events_obj = require "net.http.server"._events;
+			events_obj = require "prosody.net.http.server"._events;
 		elseif not prosody.hosts[host] then
 			return false, "Unknown host: "..host;
 		else
@@ -1886,7 +1886,7 @@
 
 function def_env.debug:timers()
 	local print = self.session.print;
-	local add_task = require"util.timer".add_task;
+	local add_task = require"prosody.util.timer".add_task;
 	local h, params = add_task.h, add_task.params;
 	local function normalize_time(t)
 		return t;
@@ -2183,7 +2183,7 @@
 end
 
 function def_env.stats:show(name_filter)
-	local statsman = require "core.statsmanager"
+	local statsman = require "prosody.core.statsmanager"
 	local collect = statsman.collect
 	if collect then
 		-- force collection if in manual mode
--- a/plugins/mod_admin_socket.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_admin_socket.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -16,10 +16,10 @@
 	return;
 end
 
-local server = require "net.server";
+local server = require "prosody.net.server";
 
-local adminstream = require "util.adminstream";
-local st = require "util.stanza";
+local adminstream = require "prosody.util.adminstream";
+local st = require "prosody.util.stanza";
 
 local socket_path = module:get_option_path("admin_socket", "prosody.sock", "data");
 
--- a/plugins/mod_admin_telnet.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_admin_telnet.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -12,8 +12,8 @@
 
 local console_listener = { default_port = 5582; default_mode = "*a"; interface = "127.0.0.1" };
 
-local async = require "util.async";
-local st = require "util.stanza";
+local async = require "prosody.util.async";
+local st = require "prosody.util.stanza";
 
 local def_env = module:shared("admin_shell/env");
 local default_env_mt = { __index = def_env };
--- a/plugins/mod_announce.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_announce.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,7 +6,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st, jid = require "util.stanza", require "util.jid";
+local st, jid = require "prosody.util.stanza", require "prosody.util.jid";
 
 local hosts = prosody.hosts;
 
@@ -63,7 +63,7 @@
 module:hook("message/host", handle_announcement);
 
 -- Ad-hoc command (XEP-0133)
-local dataforms_new = require "util.dataforms".new;
+local dataforms_new = require "prosody.util.dataforms".new;
 local announce_layout = dataforms_new{
 	title = "Making an Announcement";
 	instructions = "Fill out this form to make an announcement to all\nactive users of this service.";
--- a/plugins/mod_auth_anonymous.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_auth_anonymous.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,8 +7,8 @@
 --
 -- luacheck: ignore 212
 
-local new_sasl = require "util.sasl".new;
-local datamanager = require "util.datamanager";
+local new_sasl = require "prosody.util.sasl".new;
+local datamanager = require "prosody.util.datamanager";
 local hosts = prosody.hosts;
 
 local allow_storage = module:get_option_boolean("allow_anonymous_storage", false);
--- a/plugins/mod_auth_insecure.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_auth_insecure.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,9 +7,9 @@
 --
 -- luacheck: ignore 212
 
-local datamanager = require "util.datamanager";
-local new_sasl = require "util.sasl".new;
-local saslprep = require "util.encodings".stringprep.saslprep;
+local datamanager = require "prosody.util.datamanager";
+local new_sasl = require "prosody.util.sasl".new;
+local saslprep = require "prosody.util.encodings".stringprep.saslprep;
 
 local host = module.host;
 local provider = { name = "insecure" };
--- a/plugins/mod_auth_internal_hashed.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_auth_internal_hashed.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -9,13 +9,13 @@
 
 local max = math.max;
 
-local scram_hashers = require "util.sasl.scram".hashers;
-local generate_uuid = require "util.uuid".generate;
-local new_sasl = require "util.sasl".new;
-local hex = require"util.hex";
+local scram_hashers = require "prosody.util.sasl.scram".hashers;
+local generate_uuid = require "prosody.util.uuid".generate;
+local new_sasl = require "prosody.util.sasl".new;
+local hex = require"prosody.util.hex";
 local to_hex, from_hex = hex.encode, hex.decode;
-local saslprep = require "util.encodings".stringprep.saslprep;
-local secure_equals = require "util.hashes".equals;
+local saslprep = require "prosody.util.encodings".stringprep.saslprep;
+local secure_equals = require "prosody.util.hashes".equals;
 
 local log = module._log;
 local host = module.host;
--- a/plugins/mod_auth_internal_plain.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_auth_internal_plain.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,10 +6,10 @@
 -- COPYING file in the source package for more information.
 --
 
-local usermanager = require "core.usermanager";
-local new_sasl = require "util.sasl".new;
-local saslprep = require "util.encodings".stringprep.saslprep;
-local secure_equals = require "util.hashes".equals;
+local usermanager = require "prosody.core.usermanager";
+local new_sasl = require "prosody.util.sasl".new;
+local saslprep = require "prosody.util.encodings".stringprep.saslprep;
+local secure_equals = require "prosody.util.hashes".equals;
 
 local log = module._log;
 local host = module.host;
--- a/plugins/mod_auth_ldap.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_auth_ldap.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,6 +1,6 @@
 -- mod_auth_ldap
 
-local new_sasl = require "util.sasl".new;
+local new_sasl = require "prosody.util.sasl".new;
 local lualdap = require "lualdap";
 
 local function ldap_filter_escape(s)
--- a/plugins/mod_authz_internal.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_authz_internal.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,9 +1,9 @@
-local array = require "util.array";
-local it = require "util.iterators";
-local set = require "util.set";
-local jid_split, jid_bare, jid_host = import("util.jid", "split", "bare", "host");
-local normalize = require "util.jid".prep;
-local roles = require "util.roles";
+local array = require "prosody.util.array";
+local it = require "prosody.util.iterators";
+local set = require "prosody.util.set";
+local jid_split, jid_bare, jid_host = import("prosody.util.jid", "split", "bare", "host");
+local normalize = require "prosody.util.jid".prep;
+local roles = require "prosody.util.roles";
 
 local config_global_admin_jids = module:context("*"):get_option_set("admins", {}) / normalize;
 local config_admin_jids = module:get_option_inherited_set("admins", {}) / normalize;
@@ -321,7 +321,7 @@
 		end
 
 		-- Initialize storage layer
-		require "core.storagemanager".initialize_host(migrate_host);
+		require "prosody.core.storagemanager".initialize_host(migrate_host);
 
 		print("II: Migrating roles...");
 		local migrated, failed, skipped = do_migration(migrate_host);
--- a/plugins/mod_blocklist.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_blocklist.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -9,16 +9,16 @@
 -- This module implements XEP-0191: Blocking Command
 --
 
-local user_exists = require"core.usermanager".user_exists;
-local rostermanager = require"core.rostermanager";
+local user_exists = require"prosody.core.usermanager".user_exists;
+local rostermanager = require"prosody.core.rostermanager";
 local is_contact_subscribed = rostermanager.is_contact_subscribed;
 local is_contact_pending_in = rostermanager.is_contact_pending_in;
 local load_roster = rostermanager.load_roster;
 local save_roster = rostermanager.save_roster;
-local st = require"util.stanza";
+local st = require"prosody.util.stanza";
 local st_error_reply = st.error_reply;
-local jid_prep = require"util.jid".prep;
-local jid_split = require"util.jid".split;
+local jid_prep = require"prosody.util.jid".prep;
+local jid_split = require"prosody.util.jid".split;
 
 local storage = module:open_store();
 local sessions = prosody.hosts[module.host].sessions;
@@ -36,7 +36,7 @@
 -- want to use too much memory either, so this can be tuned by advanced
 -- users. TODO use science to figure out a better default, 64 is just a guess.
 local cache_size = module:get_option_number("blocklist_cache_size", 64);
-local cache2 = require"util.cache".new(cache_size);
+local cache2 = require"prosody.util.cache".new(cache_size);
 
 local null_blocklist = {};
 
--- a/plugins/mod_bookmarks.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_bookmarks.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,10 +1,10 @@
-local mm = require "core.modulemanager";
+local mm = require "prosody.core.modulemanager";
 if mm.get_modules_for_host(module.host):contains("bookmarks2") then
 	error("mod_bookmarks and mod_bookmarks2 are conflicting, please disable one of them.", 0);
 end
 
-local st = require "util.stanza";
-local jid_split = require "util.jid".split;
+local st = require "prosody.util.stanza";
+local jid_split = require "prosody.util.jid".split;
 
 local mod_pep = module:depends "pep";
 local private_storage = module:open_store("private", "map");
--- a/plugins/mod_bosh.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_bosh.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,21 +8,21 @@
 
 module:set_global();
 
-local new_xmpp_stream = require "util.xmppstream".new;
-local sm = require "core.sessionmanager";
+local new_xmpp_stream = require "prosody.util.xmppstream".new;
+local sm = require "prosody.core.sessionmanager";
 local sm_destroy_session = sm.destroy_session;
-local new_uuid = require "util.uuid".generate;
+local new_uuid = require "prosody.util.uuid".generate;
 local core_process_stanza = prosody.core_process_stanza;
-local st = require "util.stanza";
-local logger = require "util.logger";
+local st = require "prosody.util.stanza";
+local logger = require "prosody.util.logger";
 local log = module._log;
-local initialize_filters = require "util.filters".initialize;
+local initialize_filters = require "prosody.util.filters".initialize;
 local math_min = math.min;
 local tostring, type = tostring, type;
 local traceback = debug.traceback;
-local runner = require"util.async".runner;
-local nameprep = require "util.encodings".stringprep.nameprep;
-local cache = require "util.cache";
+local runner = require"prosody.util.async".runner;
+local nameprep = require "prosody.util.encodings".stringprep.nameprep;
+local cache = require "prosody.util.cache";
 
 local xmlns_streams = "http://etherx.jabber.org/streams";
 local xmlns_xmpp_streams = "urn:ietf:params:xml:ns:xmpp-streams";
@@ -559,6 +559,6 @@
 	});
 end
 
-if require"core.modulemanager".get_modules_for_host("*"):contains(module.name) then
+if require"prosody.core.modulemanager".get_modules_for_host("*"):contains(module.name) then
 	module:add_host();
 end
--- a/plugins/mod_c2s.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_c2s.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,15 +8,15 @@
 
 module:set_global();
 
-local add_task = require "util.timer".add_task;
-local new_xmpp_stream = require "util.xmppstream".new;
-local nameprep = require "util.encodings".stringprep.nameprep;
-local sessionmanager = require "core.sessionmanager";
-local statsmanager = require "core.statsmanager";
-local st = require "util.stanza";
+local add_task = require "prosody.util.timer".add_task;
+local new_xmpp_stream = require "prosody.util.xmppstream".new;
+local nameprep = require "prosody.util.encodings".stringprep.nameprep;
+local sessionmanager = require "prosody.core.sessionmanager";
+local statsmanager = require "prosody.core.statsmanager";
+local st = require "prosody.util.stanza";
 local sm_new_session, sm_destroy_session = sessionmanager.new_session, sessionmanager.destroy_session;
-local uuid_generate = require "util.uuid".generate;
-local async = require "util.async";
+local uuid_generate = require "prosody.util.uuid".generate;
+local async = require "prosody.util.async";
 local runner = async.runner;
 
 local tostring, type = tostring, type;
@@ -438,7 +438,7 @@
 
 module:hook("server-stopping", function(event) -- luacheck: ignore 212/event
 	-- Close ports
-	local pm = require "core.portmanager";
+	local pm = require "prosody.core.portmanager";
 	for _, netservice in pairs(module.items["net-provider"]) do
 		pm.unregister_service(netservice.name, netservice);
 	end
--- a/plugins/mod_carbons.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_carbons.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -3,9 +3,9 @@
 --
 -- This file is MIT/X11 licensed.
 
-local st = require "util.stanza";
-local jid_bare = require "util.jid".bare;
-local jid_resource = require "util.jid".resource;
+local st = require "prosody.util.stanza";
+local jid_bare = require "prosody.util.jid".bare;
+local jid_resource = require "prosody.util.jid".resource;
 local xmlns_carbons = "urn:xmpp:carbons:2";
 local xmlns_forward = "urn:xmpp:forward:0";
 local full_sessions, bare_sessions = prosody.full_sessions, prosody.bare_sessions;
--- a/plugins/mod_component.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_component.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -10,16 +10,16 @@
 
 local t_concat = table.concat;
 local tostring, type = tostring, type;
-local xpcall = require "util.xpcall".xpcall;
+local xpcall = require "prosody.util.xpcall".xpcall;
 local traceback = debug.traceback;
 
-local logger = require "util.logger";
-local sha1 = require "util.hashes".sha1;
-local st = require "util.stanza";
+local logger = require "prosody.util.logger";
+local sha1 = require "prosody.util.hashes".sha1;
+local st = require "prosody.util.stanza";
 
-local jid_host = require "util.jid".host;
-local new_xmpp_stream = require "util.xmppstream".new;
-local uuid_gen = require "util.uuid".generate;
+local jid_host = require "prosody.util.jid".host;
+local new_xmpp_stream = require "prosody.util.xmppstream".new;
+local uuid_gen = require "prosody.util.uuid".generate;
 
 local core_process_stanza = prosody.core_process_stanza;
 local hosts = prosody.hosts;
--- a/plugins/mod_cron.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_cron.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,7 +1,7 @@
 module:set_global();
 
-local async = require("util.async");
-local datetime = require("util.datetime");
+local async = require("prosody.util.async");
+local datetime = require("prosody.util.datetime");
 
 local periods = { hourly = 3600; daily = 86400; weekly = 7 * 86400 }
 
--- a/plugins/mod_csi.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_csi.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,4 +1,4 @@
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 local xmlns_csi = "urn:xmpp:csi:0";
 local csi_feature = st.stanza("csi", { xmlns = xmlns_csi });
 
--- a/plugins/mod_csi_simple.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_csi_simple.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,11 +6,11 @@
 
 module:depends"csi"
 
-local jid = require "util.jid";
-local st = require "util.stanza";
-local dt = require "util.datetime";
-local filters = require "util.filters";
-local timer = require "util.timer";
+local jid = require "prosody.util.jid";
+local st = require "prosody.util.stanza";
+local dt = require "prosody.util.datetime";
+local filters = require "prosody.util.filters";
+local timer = require "prosody.util.timer";
 
 local queue_size = module:get_option_number("csi_queue_size", 256);
 local resume_delay = module:get_option_number("csi_resume_inactive_delay", 5);
@@ -255,7 +255,7 @@
 		return 1;
 	end
 	-- luacheck: ignore 212/self
-	local xmppstream = require "util.xmppstream";
+	local xmppstream = require "prosody.util.xmppstream";
 	local input_session = { notopen = true }
 	local stream_callbacks = { stream_ns = "jabber:client", default_ns = "jabber:client" };
 	function stream_callbacks:handlestanza(stanza)
--- a/plugins/mod_debug_reset.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_debug_reset.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -5,9 +5,9 @@
 
 module:set_global();
 
-local hostmanager = require "core.hostmanager";
+local hostmanager = require "prosody.core.hostmanager";
 
-local timer = require "util.timer";
+local timer = require "prosody.util.timer";
 
 local function do_reset()
 	module:log("info", "Performing reset...");
--- a/plugins/mod_debug_stanzas/watcher.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_debug_stanzas/watcher.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,6 +1,6 @@
-local filters = require "util.filters";
-local jid = require "util.jid";
-local set = require "util.set";
+local filters = require "prosody.util.filters";
+local jid = require "prosody.util.jid";
+local set = require "prosody.util.set";
 
 local client_watchers = {};
 
--- a/plugins/mod_dialback.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_dialback.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -10,12 +10,12 @@
 
 local log = module._log;
 
-local st = require "util.stanza";
-local sha256_hash = require "util.hashes".sha256;
-local sha256_hmac = require "util.hashes".hmac_sha256;
-local secure_equals = require "util.hashes".equals;
-local nameprep = require "util.encodings".stringprep.nameprep;
-local uuid_gen = require"util.uuid".generate;
+local st = require "prosody.util.stanza";
+local sha256_hash = require "prosody.util.hashes".sha256;
+local sha256_hmac = require "prosody.util.hashes".hmac_sha256;
+local secure_equals = require "prosody.util.hashes".equals;
+local nameprep = require "prosody.util.encodings".stringprep.nameprep;
+local uuid_gen = require"prosody.util.uuid".generate;
 
 local xmlns_stream = "http://etherx.jabber.org/streams";
 
--- a/plugins/mod_disco.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_disco.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,12 +6,12 @@
 -- COPYING file in the source package for more information.
 --
 
-local get_children = require "core.hostmanager".get_children;
-local is_contact_subscribed = require "core.rostermanager".is_contact_subscribed;
-local jid_split = require "util.jid".split;
-local jid_bare = require "util.jid".bare;
-local st = require "util.stanza"
-local calculate_hash = require "util.caps".calculate_hash;
+local get_children = require "prosody.core.hostmanager".get_children;
+local is_contact_subscribed = require "prosody.core.rostermanager".is_contact_subscribed;
+local jid_split = require "prosody.util.jid".split;
+local jid_bare = require "prosody.util.jid".bare;
+local st = require "prosody.util.stanza"
+local calculate_hash = require "prosody.util.caps".calculate_hash;
 
 local expose_admins = module:get_option_boolean("disco_expose_admins", false);
 
--- a/plugins/mod_external_services.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_external_services.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,11 +1,11 @@
 
-local dt = require "util.datetime";
-local base64 = require "util.encodings".base64;
-local hashes = require "util.hashes";
-local st = require "util.stanza";
-local jid = require "util.jid";
-local array = require "util.array";
-local set = require "util.set";
+local dt = require "prosody.util.datetime";
+local base64 = require "prosody.util.encodings".base64;
+local hashes = require "prosody.util.hashes";
+local st = require "prosody.util.stanza";
+local jid = require "prosody.util.jid";
+local array = require "prosody.util.array";
+local set = require "prosody.util.set";
 
 local default_host = module:get_option_string("external_service_host", module.host);
 local default_port = module:get_option_number("external_service_port");
--- a/plugins/mod_groups.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_groups.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -10,8 +10,8 @@
 local groups;
 local members;
 
-local datamanager = require "util.datamanager";
-local jid_prep = require "util.jid".prep;
+local datamanager = require "prosody.util.datamanager";
+local jid_prep = require "prosody.util.jid".prep;
 
 local module_host = module:get_host();
 
--- a/plugins/mod_http.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_http.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -11,19 +11,19 @@
 	module:depends("http_errors");
 end);
 
-local portmanager = require "core.portmanager";
-local moduleapi = require "core.moduleapi";
+local portmanager = require "prosody.core.portmanager";
+local moduleapi = require "prosody.core.moduleapi";
 local url_parse = require "socket.url".parse;
 local url_build = require "socket.url".build;
-local normalize_path = require "util.http".normalize_path;
-local set = require "util.set";
+local normalize_path = require "prosody.util.http".normalize_path;
+local set = require "prosody.util.set";
 
-local ip_util = require "util.ip";
+local ip_util = require "prosody.util.ip";
 local new_ip = ip_util.new_ip;
 local match_ip = ip_util.match;
 local parse_cidr = ip_util.parse_cidr;
 
-local server = require "net.http.server";
+local server = require "prosody.net.http.server";
 
 server.set_default_host(module:get_option_string("http_default_host"));
 
--- a/plugins/mod_http_errors.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_http_errors.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,9 +1,9 @@
 module:set_global();
 
-local server = require "net.http.server";
-local codes = require "net.http.codes";
-local xml_escape = require "util.stanza".xml_escape;
-local render = require "util.interpolation".new("%b{}", xml_escape);
+local server = require "prosody.net.http.server";
+local codes = require "prosody.net.http.codes";
+local xml_escape = require "prosody.util.stanza".xml_escape;
+local render = require "prosody.util.interpolation".new("%b{}", xml_escape);
 
 local show_private = module:get_option_boolean("http_errors_detailed", false);
 local always_serve = module:get_option_boolean("http_errors_always_show", true);
--- a/plugins/mod_http_file_share.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_http_file_share.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,16 +8,16 @@
 -- Again, from the top!
 
 local t_insert = table.insert;
-local jid = require "util.jid";
-local st = require "util.stanza";
+local jid = require "prosody.util.jid";
+local st = require "prosody.util.stanza";
 local url = require "socket.url";
-local dm = require "core.storagemanager".olddm;
-local errors = require "util.error";
-local dataform = require "util.dataforms".new;
-local urlencode = require "util.http".urlencode;
-local dt = require "util.datetime";
-local hi = require "util.human.units";
-local cache = require "util.cache";
+local dm = require "prosody.core.storagemanager".olddm;
+local errors = require "prosody.util.error";
+local dataform = require "prosody.util.dataforms".new;
+local urlencode = require "prosody.util.http".urlencode;
+local dt = require "prosody.util.datetime";
+local hi = require "prosody.util.human.units";
+local cache = require "prosody.util.cache";
 local lfs = require "lfs";
 
 local unknown = math.abs(0/0);
@@ -34,7 +34,7 @@
 local persist_stats = module:open_store("upload_stats", "map");
 -- id, <request>, time, owner
 
-local secret = module:get_option_string(module.name.."_secret", require"util.id".long());
+local secret = module:get_option_string(module.name.."_secret", require"prosody.util.id".long());
 local external_base_url = module:get_option_string(module.name .. "_base_url");
 local file_size_limit = module:get_option_number(module.name .. "_size_limit", 10 * 1024 * 1024); -- 10 MB
 local file_types = module:get_option_set(module.name .. "_allowed_file_types", {});
@@ -43,7 +43,7 @@
 local daily_quota = module:get_option_number(module.name .. "_daily_quota", file_size_limit*10); -- 100 MB / day
 local total_storage_limit = module:get_option_number(module.name.."_global_quota", unlimited);
 
-local create_jwt, verify_jwt = require "util.jwt".init("HS256", secret);
+local create_jwt, verify_jwt = require "prosody.util.jwt".init("HS256", secret);
 
 local access = module:get_option_set(module.name .. "_access", {});
 
@@ -452,9 +452,9 @@
 
 if expiry >= 0 and not external_base_url then
 	-- TODO HTTP DELETE to the external endpoint?
-	local array = require "util.array";
-	local async = require "util.async";
-	local ENOENT = require "util.pposix".ENOENT;
+	local array = require "prosody.util.array";
+	local async = require "prosody.util.async";
+	local ENOENT = require "prosody.util.pposix".ENOENT;
 
 	local function sleep(t)
 		local wait, done = async.waiter();
--- a/plugins/mod_http_files.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_http_files.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -9,7 +9,7 @@
 module:depends("http");
 
 local open = io.open;
-local fileserver = require"net.http.files";
+local fileserver = require"prosody.net.http.files";
 
 local base_path = module:get_option_path("http_files_dir", module:get_option_path("http_path"));
 local cache_size = module:get_option_number("http_files_cache_size", 128);
@@ -74,12 +74,12 @@
 	if opts.index_files == nil then
 		opts.index_files = dir_indices;
 	end
-	module:log("warn", "%s should be updated to use 'net.http.files' instead of mod_http_files", get_calling_module());
+	module:log("warn", "%s should be updated to use 'prosody.net.http.files' instead of mod_http_files", get_calling_module());
 	return fileserver.serve(opts);
 end
 
 function wrap_route(routes)
-	module:log("debug", "%s should be updated to use 'net.http.files' instead of mod_http_files", get_calling_module());
+	module:log("debug", "%s should be updated to use 'prosody.net.http.files' instead of mod_http_files", get_calling_module());
 	for route,handler in pairs(routes) do
 		if type(handler) ~= "function" then
 			routes[route] = fileserver.serve(handler);
--- a/plugins/mod_http_openmetrics.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_http_openmetrics.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,8 +8,8 @@
 
 module:set_global();
 
-local statsman = require "core.statsmanager";
-local ip = require "util.ip";
+local statsman = require "prosody.core.statsmanager";
+local ip = require "prosody.util.ip";
 
 local get_metric_registry = statsman.get_metric_registry;
 local collect = statsman.collect;
--- a/plugins/mod_invites.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_invites.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,8 +1,8 @@
-local id = require "util.id";
-local it = require "util.iterators";
+local id = require "prosody.util.id";
+local it = require "prosody.util.iterators";
 local url = require "socket.url";
-local jid_node = require "util.jid".node;
-local jid_split = require "util.jid".split;
+local jid_node = require "prosody.util.jid".node;
+local jid_split = require "prosody.util.jid".split;
 
 local default_ttl = module:get_option_number("invite_expiry", 86400 * 7);
 
@@ -205,7 +205,7 @@
 	-- Since the console is global this overwrites the command for
 	-- each host it's loaded on, but this should be fine.
 
-	local get_module = require "core.modulemanager".get_module;
+	local get_module = require "prosody.core.modulemanager".get_module;
 
 	local console_env = module:shared("/*/admin_shell/env");
 
@@ -238,8 +238,8 @@
 	end
 	table.remove(arg, 1); -- pop command
 
-	local sm = require "core.storagemanager";
-	local mm = require "core.modulemanager";
+	local sm = require "prosody.core.storagemanager";
+	local mm = require "prosody.core.modulemanager";
 
 	local host = arg[1];
 	assert(prosody.hosts[host], "Host "..tostring(host).." does not exist");
@@ -288,7 +288,7 @@
 			print("--reset and the other options cannot be mixed.")
 			return 2
 		elseif value == "--reset" then
-			local nodeprep = require "util.encodings".stringprep.nodeprep;
+			local nodeprep = require "prosody.util.encodings".stringprep.nodeprep;
 			local username = nodeprep(arg[1])
 			table.remove(arg, 1);
 			if not username then
--- a/plugins/mod_invites_adhoc.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_invites_adhoc.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,7 +1,7 @@
 -- XEP-0401: Easy User Onboarding
-local dataforms = require "util.dataforms";
-local datetime = require "util.datetime";
-local split_jid = require "util.jid".split;
+local dataforms = require "prosody.util.dataforms";
+local datetime = require "prosody.util.datetime";
+local split_jid = require "prosody.util.jid".split;
 
 local new_adhoc = module:require("adhoc").new;
 
--- a/plugins/mod_invites_register.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_invites_register.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,7 +1,7 @@
-local st = require "util.stanza";
-local jid_split = require "util.jid".split;
-local jid_bare = require "util.jid".bare;
-local rostermanager = require "core.rostermanager";
+local st = require "prosody.util.stanza";
+local jid_split = require "prosody.util.jid".split;
+local jid_bare = require "prosody.util.jid".bare;
+local rostermanager = require "prosody.core.rostermanager";
 
 local require_encryption = module:get_option_boolean("c2s_require_encryption",
 	module:get_option_boolean("require_encryption", true));
--- a/plugins/mod_iq.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_iq.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,7 +7,7 @@
 --
 
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 local full_sessions = prosody.full_sessions;
 
--- a/plugins/mod_lastactivity.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_lastactivity.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,10 +6,10 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
-local is_contact_subscribed = require "core.rostermanager".is_contact_subscribed;
-local jid_bare = require "util.jid".bare;
-local jid_split = require "util.jid".split;
+local st = require "prosody.util.stanza";
+local is_contact_subscribed = require "prosody.core.rostermanager".is_contact_subscribed;
+local jid_bare = require "prosody.util.jid".bare;
+local jid_split = require "prosody.util.jid".split;
 
 module:add_feature("jabber:iq:last");
 
--- a/plugins/mod_legacyauth.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_legacyauth.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,17 +8,17 @@
 
 
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 local t_concat = table.concat;
 
 local secure_auth_only = module:get_option("c2s_require_encryption",
 	module:get_option("require_encryption", true))
 	or not(module:get_option("allow_unencrypted_plain_auth"));
 
-local sessionmanager = require "core.sessionmanager";
-local usermanager = require "core.usermanager";
-local nodeprep = require "util.encodings".stringprep.nodeprep;
-local resourceprep = require "util.encodings".stringprep.resourceprep;
+local sessionmanager = require "prosody.core.sessionmanager";
+local usermanager = require "prosody.core.usermanager";
+local nodeprep = require "prosody.util.encodings".stringprep.nodeprep;
+local resourceprep = require "prosody.util.encodings".stringprep.resourceprep;
 
 module:add_feature("jabber:iq:auth");
 module:hook("stream-features", function(event)
--- a/plugins/mod_limits.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_limits.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,9 +1,9 @@
 -- Because we deal with pre-authed sessions and streams we can't be host-specific
 module:set_global();
 
-local filters = require "util.filters";
-local throttle = require "util.throttle";
-local timer = require "util.timer";
+local filters = require "prosody.util.filters";
+local throttle = require "prosody.util.throttle";
+local timer = require "prosody.util.timer";
 local ceil = math.ceil;
 
 local limits_cfg = module:get_option("limits", {});
--- a/plugins/mod_mam/mamprefsxml.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_mam/mamprefsxml.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -10,8 +10,8 @@
 -- XEP-0313: Message Archive Management for Prosody
 --
 
-local st = require"util.stanza";
-local jid_prep = require"util.jid".prep;
+local st = require"prosody.util.stanza";
+local jid_prep = require"prosody.util.jid".prep;
 local xmlns_mam = "urn:xmpp:mam:2";
 
 local default_attrs = {
--- a/plugins/mod_mam/mod_mam.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_mam/mod_mam.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -15,28 +15,28 @@
 local xmlns_forward = "urn:xmpp:forward:0";
 local xmlns_st_id   = "urn:xmpp:sid:0";
 
-local um = require "core.usermanager";
-local st = require "util.stanza";
-local rsm = require "util.rsm";
+local um = require "prosody.core.usermanager";
+local st = require "prosody.util.stanza";
+local rsm = require "prosody.util.rsm";
 local get_prefs = module:require"mamprefs".get;
 local set_prefs = module:require"mamprefs".set;
 local prefs_to_stanza = module:require"mamprefsxml".tostanza;
 local prefs_from_stanza = module:require"mamprefsxml".fromstanza;
-local jid_bare = require "util.jid".bare;
-local jid_split = require "util.jid".split;
-local jid_resource = require "util.jid".resource;
-local jid_prepped_split = require "util.jid".prepped_split;
-local dataform = require "util.dataforms".new;
-local get_form_type = require "util.dataforms".get_type;
+local jid_bare = require "prosody.util.jid".bare;
+local jid_split = require "prosody.util.jid".split;
+local jid_resource = require "prosody.util.jid".resource;
+local jid_prepped_split = require "prosody.util.jid".prepped_split;
+local dataform = require "prosody.util.dataforms".new;
+local get_form_type = require "prosody.util.dataforms".get_type;
 local host = module.host;
 
-local rm_load_roster = require "core.rostermanager".load_roster;
+local rm_load_roster = require "prosody.core.rostermanager".load_roster;
 
 local is_stanza = st.is_stanza;
 local tostring = tostring;
-local time_now = require "util.time".now;
+local time_now = require "prosody.util.time".now;
 local m_min = math.min;
-local timestamp, datestamp = import("util.datetime", "datetime", "date");
+local timestamp, datestamp = import("prosody.util.datetime", "datetime", "date");
 local default_max_items, max_max_items = 20, module:get_option_number("max_archive_query_results", 50);
 local strip_tags = module:get_option_set("dont_archive_namespaces", { "http://jabber.org/protocol/chatstates" });
 
@@ -532,7 +532,7 @@
 	-- outside the cleanup range.
 
 	if not (archive.caps and archive.caps.wildcard_delete) then
-		local last_date = require "util.cache".new(module:get_option_number("archive_cleanup_date_cache_size", 1000));
+		local last_date = require "prosody.util.cache".new(module:get_option_number("archive_cleanup_date_cache_size", 1000));
 		function schedule_cleanup(username, date)
 			date = date or datestamp();
 			if last_date:get(username) == date then return end
@@ -545,7 +545,7 @@
 
 	local cleanup_time = module:measure("cleanup", "times");
 
-	local async = require "util.async";
+	local async = require "prosody.util.async";
 	module:daily("Remove expired messages", function ()
 		local cleanup_done = cleanup_time();
 
--- a/plugins/mod_message.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_message.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -10,10 +10,10 @@
 local full_sessions = prosody.full_sessions;
 local bare_sessions = prosody.bare_sessions;
 
-local st = require "util.stanza";
-local jid_bare = require "util.jid".bare;
-local jid_split = require "util.jid".split;
-local user_exists = require "core.usermanager".user_exists;
+local st = require "prosody.util.stanza";
+local jid_bare = require "prosody.util.jid".bare;
+local jid_split = require "prosody.util.jid".split;
+local user_exists = require "prosody.core.usermanager".user_exists;
 
 local function process_to_bare(bare, origin, stanza)
 	local user = bare_sessions[bare];
--- a/plugins/mod_mimicking.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_mimicking.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,13 +6,13 @@
 -- COPYING file in the source package for more information.
 --
 
-local encodings = require "util.encodings";
+local encodings = require "prosody.util.encodings";
 assert(encodings.confusable, "This module requires that Prosody be built with ICU");
 local skeleton = encodings.confusable.skeleton;
 
-local usage = require "util.prosodyctl".show_usage;
-local usermanager = require "core.usermanager";
-local storagemanager = require "core.storagemanager";
+local usage = require "prosody.util.prosodyctl".show_usage;
+local usermanager = require "prosody.core.usermanager";
+local storagemanager = require "prosody.core.storagemanager";
 
 local skeletons
 function module.load()
--- a/plugins/mod_motd.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_motd.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -13,7 +13,7 @@
 
 if not motd_text then return; end
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 motd_text = motd_text:gsub("^%s*(.-)%s*$", "%1"):gsub("\n[ \t]+", "\n"); -- Strip indentation from the config
 
--- a/plugins/mod_muc_mam.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_muc_mam.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -16,22 +16,22 @@
 local xmlns_muc_user = "http://jabber.org/protocol/muc#user";
 local muc_form_enable = "muc#roomconfig_enablearchiving"
 
-local st = require "util.stanza";
-local rsm = require "util.rsm";
-local jid_bare = require "util.jid".bare;
-local jid_split = require "util.jid".split;
-local jid_prep = require "util.jid".prep;
-local dataform = require "util.dataforms".new;
-local get_form_type = require "util.dataforms".get_type;
+local st = require "prosody.util.stanza";
+local rsm = require "prosody.util.rsm";
+local jid_bare = require "prosody.util.jid".bare;
+local jid_split = require "prosody.util.jid".split;
+local jid_prep = require "prosody.util.jid".prep;
+local dataform = require "prosody.util.dataforms".new;
+local get_form_type = require "prosody.util.dataforms".get_type;
 
 local mod_muc = module:depends"muc";
 local get_room_from_jid = mod_muc.get_room_from_jid;
 
 local is_stanza = st.is_stanza;
 local tostring = tostring;
-local time_now = require "util.time".now;
+local time_now = require "prosody.util.time".now;
 local m_min = math.min;
-local timestamp, datestamp = import("util.datetime", "datetime", "date");
+local timestamp, datestamp = import("prosody.util.datetime", "datetime", "date");
 local default_max_items, max_max_items = 20, module:get_option_number("max_archive_query_results", 50);
 
 local cleanup_after = module:get_option_string("muc_log_expires_after", "1w");
@@ -492,7 +492,7 @@
 	-- messages, we collect the union of sets of rooms from dates that fall
 	-- outside the cleanup range.
 
-	local last_date = require "util.cache".new(module:get_option_number("muc_log_cleanup_date_cache_size", 1000));
+	local last_date = require "prosody.util.cache".new(module:get_option_number("muc_log_cleanup_date_cache_size", 1000));
 	if not ( archive.caps and archive.caps.wildcard_delete ) then
 		function schedule_cleanup(roomname, date)
 			date = date or datestamp();
@@ -506,7 +506,7 @@
 
 	local cleanup_time = module:measure("cleanup", "times");
 
-	local async = require "util.async";
+	local async = require "prosody.util.async";
 	module:daily("Remove expired messages", function ()
 		local cleanup_done = cleanup_time();
 
--- a/plugins/mod_muc_unique.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_muc_unique.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,6 +1,6 @@
 -- XEP-0307: Unique Room Names for Multi-User Chat
-local st = require "util.stanza";
-local unique_name = require "util.id".medium;
+local st = require "prosody.util.stanza";
+local unique_name = require "prosody.util.id".medium;
 module:add_feature "http://jabber.org/protocol/muc#unique"
 module:hook("iq-get/host/http://jabber.org/protocol/muc#unique:unique", function(event)
 	local origin, stanza = event.origin, event.stanza;
--- a/plugins/mod_net_multiplex.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_net_multiplex.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,10 +1,10 @@
 module:set_global();
 
-local array = require "util.array";
+local array = require "prosody.util.array";
 local max_buffer_len = module:get_option_number("multiplex_buffer_size", 1024);
 local default_mode = module:get_option_number("network_default_read_size", 4096);
 
-local portmanager = require "core.portmanager";
+local portmanager = require "prosody.core.portmanager";
 
 local available_services = {};
 local service_by_protocol = {};
--- a/plugins/mod_offline.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_offline.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,8 +7,8 @@
 --
 
 
-local datetime = require "util.datetime";
-local jid_split = require "util.jid".split;
+local datetime = require "prosody.util.datetime";
+local jid_split = require "prosody.util.jid".split;
 
 local offline_messages = module:open_store("offline", "archive");
 
--- a/plugins/mod_pep.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_pep.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,16 +1,16 @@
-local pubsub = require "util.pubsub";
-local jid_bare = require "util.jid".bare;
-local jid_split = require "util.jid".split;
-local jid_join = require "util.jid".join;
-local set_new = require "util.set".new;
-local st = require "util.stanza";
-local calculate_hash = require "util.caps".calculate_hash;
-local is_contact_subscribed = require "core.rostermanager".is_contact_subscribed;
-local cache = require "util.cache";
-local set = require "util.set";
-local new_id = require "util.id".medium;
-local storagemanager = require "core.storagemanager";
-local usermanager = require "core.usermanager";
+local pubsub = require "prosody.util.pubsub";
+local jid_bare = require "prosody.util.jid".bare;
+local jid_split = require "prosody.util.jid".split;
+local jid_join = require "prosody.util.jid".join;
+local set_new = require "prosody.util.set".new;
+local st = require "prosody.util.stanza";
+local calculate_hash = require "prosody.util.caps".calculate_hash;
+local is_contact_subscribed = require "prosody.core.rostermanager".is_contact_subscribed;
+local cache = require "prosody.util.cache";
+local set = require "prosody.util.set";
+local new_id = require "prosody.util.id".medium;
+local storagemanager = require "prosody.core.storagemanager";
+local usermanager = require "prosody.core.usermanager";
 
 local xmlns_pubsub = "http://jabber.org/protocol/pubsub";
 local xmlns_pubsub_event = "http://jabber.org/protocol/pubsub#event";
--- a/plugins/mod_pep_simple.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_pep_simple.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,15 +7,15 @@
 --
 
 
-local jid_bare = require "util.jid".bare;
-local jid_split = require "util.jid".split;
-local st = require "util.stanza";
-local is_contact_subscribed = require "core.rostermanager".is_contact_subscribed;
+local jid_bare = require "prosody.util.jid".bare;
+local jid_split = require "prosody.util.jid".split;
+local st = require "prosody.util.stanza";
+local is_contact_subscribed = require "prosody.core.rostermanager".is_contact_subscribed;
 local pairs = pairs;
 local next = next;
 local type = type;
 local unpack = table.unpack;
-local calculate_hash = require "util.caps".calculate_hash;
+local calculate_hash = require "prosody.util.caps".calculate_hash;
 local core_post_stanza = prosody.core_post_stanza;
 local bare_sessions = prosody.bare_sessions;
 
--- a/plugins/mod_ping.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_ping.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,7 +6,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 module:add_feature("urn:xmpp:ping");
 
--- a/plugins/mod_posix.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_posix.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -9,13 +9,13 @@
 
 local want_pposix_version = "0.4.0";
 
-local pposix = assert(require "util.pposix");
+local pposix = assert(require "prosody.util.pposix");
 if pposix._VERSION ~= want_pposix_version then
 	module:log("warn", "Unknown version (%s) of binary pposix module, expected %s."
 		.. "Perhaps you need to recompile?", tostring(pposix._VERSION), want_pposix_version);
 end
 
-local have_signal, signal = pcall(require, "util.signal");
+local have_signal, signal = pcall(require, "prosody.util.signal");
 if not have_signal then
 	module:log("warn", "Couldn't load signal library, won't respond to SIGTERM");
 end
@@ -97,7 +97,7 @@
 end
 
 local function remove_log_sinks()
-	local lm = require "core.loggingmanager";
+	local lm = require "prosody.core.loggingmanager";
 	lm.register_sink_type("console", nil);
 	lm.register_sink_type("stdout", nil);
 	lm.reload_logging();
--- a/plugins/mod_presence.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_presence.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -15,19 +15,19 @@
 
 local core_post_stanza = prosody.core_post_stanza;
 local core_process_stanza = prosody.core_process_stanza;
-local st = require "util.stanza";
-local jid_split = require "util.jid".split;
-local jid_bare = require "util.jid".bare;
-local datetime = require "util.datetime";
+local st = require "prosody.util.stanza";
+local jid_split = require "prosody.util.jid".split;
+local jid_bare = require "prosody.util.jid".bare;
+local datetime = require "prosody.util.datetime";
 local hosts = prosody.hosts;
 local bare_sessions = prosody.bare_sessions;
 local full_sessions = prosody.full_sessions;
 local NULL = {};
 
-local rostermanager = require "core.rostermanager";
-local sessionmanager = require "core.sessionmanager";
+local rostermanager = require "prosody.core.rostermanager";
+local sessionmanager = require "prosody.core.sessionmanager";
 
-local recalc_resource_map = require "util.presence".recalc_resource_map;
+local recalc_resource_map = require "prosody.util.presence".recalc_resource_map;
 
 local ignore_presence_priority = module:get_option_boolean("ignore_presence_priority", false);
 
--- a/plugins/mod_private.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_private.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,7 +7,7 @@
 --
 
 
-local st = require "util.stanza"
+local st = require "prosody.util.stanza"
 
 local private_storage = module:open_store("private", "map");
 
--- a/plugins/mod_proxy65.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_proxy65.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -9,11 +9,11 @@
 
 module:set_global();
 
-local jid_compare, jid_prep = require "util.jid".compare, require "util.jid".prep;
-local st = require "util.stanza";
-local sha1 = require "util.hashes".sha1;
-local server = require "net.server";
-local portmanager = require "core.portmanager";
+local jid_compare, jid_prep = require "prosody.util.jid".compare, require "prosody.util.jid".prep;
+local st = require "prosody.util.stanza";
+local sha1 = require "prosody.util.hashes".sha1;
+local server = require "prosody.net.server";
+local portmanager = require "prosody.core.portmanager";
 
 local sessions = module:shared("sessions");
 local transfers = module:shared("transfers");
--- a/plugins/mod_pubsub/mod_pubsub.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_pubsub/mod_pubsub.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,9 +1,9 @@
-local pubsub = require "util.pubsub";
-local st = require "util.stanza";
-local jid_bare = require "util.jid".bare;
-local new_id = require "util.id".medium;
-local storagemanager = require "core.storagemanager";
-local xtemplate = require "util.xtemplate";
+local pubsub = require "prosody.util.pubsub";
+local st = require "prosody.util.stanza";
+local jid_bare = require "prosody.util.jid".bare;
+local new_id = require "prosody.util.id".medium;
+local storagemanager = require "prosody.core.storagemanager";
+local xtemplate = require "prosody.util.xtemplate";
 
 local xmlns_pubsub = "http://jabber.org/protocol/pubsub";
 local xmlns_pubsub_event = "http://jabber.org/protocol/pubsub#event";
--- a/plugins/mod_pubsub/pubsub.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_pubsub/pubsub.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,13 +1,13 @@
 local t_unpack = table.unpack;
 local time_now = os.time;
 
-local jid_prep = require "util.jid".prep;
-local set = require "util.set";
-local st = require "util.stanza";
-local it = require "util.iterators";
-local uuid_generate = require "util.uuid".generate;
-local dataform = require"util.dataforms".new;
-local errors = require "util.error";
+local jid_prep = require "prosody.util.jid".prep;
+local set = require "prosody.util.set";
+local st = require "prosody.util.stanza";
+local it = require "prosody.util.iterators";
+local uuid_generate = require "prosody.util.uuid".generate;
+local dataform = require"prosody.util.dataforms".new;
+local errors = require "prosody.util.error";
 
 local xmlns_pubsub = "http://jabber.org/protocol/pubsub";
 local xmlns_pubsub_errors = "http://jabber.org/protocol/pubsub#errors";
--- a/plugins/mod_register_ibr.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_register_ibr.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,14 +7,14 @@
 --
 
 
-local st = require "util.stanza";
-local dataform_new = require "util.dataforms".new;
-local usermanager_user_exists  = require "core.usermanager".user_exists;
-local usermanager_create_user  = require "core.usermanager".create_user;
-local usermanager_set_password = require "core.usermanager".create_user;
-local usermanager_delete_user  = require "core.usermanager".delete_user;
-local nodeprep = require "util.encodings".stringprep.nodeprep;
-local util_error = require "util.error";
+local st = require "prosody.util.stanza";
+local dataform_new = require "prosody.util.dataforms".new;
+local usermanager_user_exists  = require "prosody.core.usermanager".user_exists;
+local usermanager_create_user  = require "prosody.core.usermanager".create_user;
+local usermanager_set_password = require "prosody.core.usermanager".create_user;
+local usermanager_delete_user  = require "prosody.core.usermanager".delete_user;
+local nodeprep = require "prosody.util.encodings".stringprep.nodeprep;
+local util_error = require "prosody.util.error";
 
 local additional_fields = module:get_option("additional_registration_fields", {});
 local require_encryption = module:get_option_boolean("c2s_require_encryption",
--- a/plugins/mod_register_limits.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_register_limits.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,13 +7,13 @@
 --
 
 
-local create_throttle = require "util.throttle".create;
-local new_cache = require "util.cache".new;
-local ip_util = require "util.ip";
+local create_throttle = require "prosody.util.throttle".create;
+local new_cache = require "prosody.util.cache".new;
+local ip_util = require "prosody.util.ip";
 local new_ip = ip_util.new_ip;
 local match_ip = ip_util.match;
 local parse_cidr = ip_util.parse_cidr;
-local errors = require "util.error";
+local errors = require "prosody.util.error";
 
 -- COMPAT drop old option names
 local min_seconds_between_registrations = module:get_option_number("min_seconds_between_registrations");
--- a/plugins/mod_roster.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_roster.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,18 +7,18 @@
 --
 
 
-local st = require "util.stanza"
+local st = require "prosody.util.stanza"
 
-local jid_split = require "util.jid".split;
-local jid_resource = require "util.jid".resource;
-local jid_prep = require "util.jid".prep;
+local jid_split = require "prosody.util.jid".split;
+local jid_resource = require "prosody.util.jid".resource;
+local jid_prep = require "prosody.util.jid".prep;
 local tonumber = tonumber;
 local pairs = pairs;
 
-local rm_load_roster = require "core.rostermanager".load_roster;
-local rm_remove_from_roster = require "core.rostermanager".remove_from_roster;
-local rm_add_to_roster = require "core.rostermanager".add_to_roster;
-local rm_roster_push = require "core.rostermanager".roster_push;
+local rm_load_roster = require "prosody.core.rostermanager".load_roster;
+local rm_remove_from_roster = require "prosody.core.rostermanager".remove_from_roster;
+local rm_add_to_roster = require "prosody.core.rostermanager".add_to_roster;
+local rm_roster_push = require "prosody.core.rostermanager".roster_push;
 
 module:add_feature("jabber:iq:roster");
 
--- a/plugins/mod_s2s.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_s2s.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -16,23 +16,23 @@
 local t_insert = table.insert;
 local traceback = debug.traceback;
 
-local add_task = require "util.timer".add_task;
-local stop_timer = require "util.timer".stop;
-local st = require "util.stanza";
-local initialize_filters = require "util.filters".initialize;
-local nameprep = require "util.encodings".stringprep.nameprep;
-local new_xmpp_stream = require "util.xmppstream".new;
-local s2s_new_incoming = require "core.s2smanager".new_incoming;
-local s2s_new_outgoing = require "core.s2smanager".new_outgoing;
-local s2s_destroy_session = require "core.s2smanager".destroy_session;
-local uuid_gen = require "util.uuid".generate;
-local async = require "util.async";
+local add_task = require "prosody.util.timer".add_task;
+local stop_timer = require "prosody.util.timer".stop;
+local st = require "prosody.util.stanza";
+local initialize_filters = require "prosody.util.filters".initialize;
+local nameprep = require "prosody.util.encodings".stringprep.nameprep;
+local new_xmpp_stream = require "prosody.util.xmppstream".new;
+local s2s_new_incoming = require "prosody.core.s2smanager".new_incoming;
+local s2s_new_outgoing = require "prosody.core.s2smanager".new_outgoing;
+local s2s_destroy_session = require "prosody.core.s2smanager".destroy_session;
+local uuid_gen = require "prosody.util.uuid".generate;
+local async = require "prosody.util.async";
 local runner = async.runner;
-local connect = require "net.connect".connect;
-local service = require "net.resolvers.service";
-local resolver_chain = require "net.resolvers.chain";
-local errors = require "util.error";
-local set = require "util.set";
+local connect = require "prosody.net.connect".connect;
+local service = require "prosody.net.resolvers.service";
+local resolver_chain = require "prosody.net.resolvers.chain";
+local errors = require "prosody.util.error";
+local set = require "prosody.util.set";
 
 local connect_timeout = module:get_option_number("s2s_timeout", 90);
 local stream_close_timeout = module:get_option_number("s2s_close_timeout", 5);
@@ -1007,7 +1007,7 @@
 
 module:hook("server-stopping", function(event)
 	-- Close ports
-	local pm = require "core.portmanager";
+	local pm = require "prosody.core.portmanager";
 	for _, netservice in pairs(module.items["net-provider"]) do
 		pm.unregister_service(netservice.name, netservice);
 	end
--- a/plugins/mod_s2s_auth_certs.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_s2s_auth_certs.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,6 +1,6 @@
 module:set_global();
 
-local cert_verify_identity = require "util.x509".verify_identity;
+local cert_verify_identity = require "prosody.util.x509".verify_identity;
 local NULL = {};
 local log = module._log;
 
--- a/plugins/mod_s2s_bidi.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_s2s_bidi.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -5,7 +5,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 local xmlns_bidi_feature = "urn:xmpp:features:bidi"
 local xmlns_bidi = "urn:xmpp:bidi";
--- a/plugins/mod_saslauth.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_saslauth.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,14 +8,14 @@
 -- luacheck: ignore 431/log
 
 
-local st = require "util.stanza";
-local sm_bind_resource = require "core.sessionmanager".bind_resource;
-local sm_make_authenticated = require "core.sessionmanager".make_authenticated;
-local base64 = require "util.encodings".base64;
-local set = require "util.set";
-local errors = require "util.error";
+local st = require "prosody.util.stanza";
+local sm_bind_resource = require "prosody.core.sessionmanager".bind_resource;
+local sm_make_authenticated = require "prosody.core.sessionmanager".make_authenticated;
+local base64 = require "prosody.util.encodings".base64;
+local set = require "prosody.util.set";
+local errors = require "prosody.util.error";
 
-local usermanager_get_sasl_handler = require "core.usermanager".get_sasl_handler;
+local usermanager_get_sasl_handler = require "prosody.core.usermanager".get_sasl_handler;
 
 local secure_auth_only = module:get_option_boolean("c2s_require_encryption", module:get_option_boolean("require_encryption", true));
 local allow_unencrypted_plain_auth = module:get_option_boolean("allow_unencrypted_plain_auth", false)
--- a/plugins/mod_scansion_record.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_scansion_record.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -2,11 +2,11 @@
 local devices = { "", "phone", "laptop", "tablet", "toaster", "fridge", "shoe" };
 local users = {};
 
-local filters = require "util.filters";
-local id = require "util.id";
-local dt = require "util.datetime";
-local dm = require "util.datamanager";
-local st = require "util.stanza";
+local filters = require "prosody.util.filters";
+local id = require "prosody.util.id";
+local dt = require "prosody.util.datetime";
+local dm = require "prosody.util.datamanager";
+local st = require "prosody.util.stanza";
 
 local record_id = id.short():lower();
 local record_date = os.date("%Y%b%d"):lower();
--- a/plugins/mod_server_contact_info.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_server_contact_info.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,12 +6,12 @@
 -- COPYING file in the source package for more information.
 --
 
-local array = require "util.array";
-local jid = require "util.jid";
+local array = require "prosody.util.array";
+local jid = require "prosody.util.jid";
 local url = require "socket.url";
 
 -- Source: http://xmpp.org/registrar/formtypes.html#http:--jabber.org-network-serverinfo
-local form_layout = require "util.dataforms".new({
+local form_layout = require "prosody.util.dataforms".new({
 	{ var = "FORM_TYPE"; type = "hidden"; value = "http://jabber.org/network/serverinfo"; };
 	{ name = "abuse", var = "abuse-addresses", type = "list-multi" },
 	{ name = "admin", var = "admin-addresses", type = "list-multi" },
--- a/plugins/mod_smacks.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_smacks.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -45,17 +45,17 @@
 local sessions_started = module:measure("sessions_started", "counter");
 
 
-local datetime = require "util.datetime";
-local add_filter = require "util.filters".add_filter;
-local jid = require "util.jid";
-local smqueue = require "util.smqueue";
-local st = require "util.stanza";
-local timer = require "util.timer";
-local new_id = require "util.id".short;
-local watchdog = require "util.watchdog";
-local it = require"util.iterators";
+local datetime = require "prosody.util.datetime";
+local add_filter = require "prosody.util.filters".add_filter;
+local jid = require "prosody.util.jid";
+local smqueue = require "prosody.util.smqueue";
+local st = require "prosody.util.stanza";
+local timer = require "prosody.util.timer";
+local new_id = require "prosody.util.id".short;
+local watchdog = require "prosody.util.watchdog";
+local it = require"prosody.util.iterators";
 
-local sessionmanager = require "core.sessionmanager";
+local sessionmanager = require "prosody.core.sessionmanager";
 
 local xmlns_errors = "urn:ietf:params:xml:ns:xmpp-stanzas";
 local xmlns_delay = "urn:xmpp:delay";
@@ -104,14 +104,14 @@
 	return old_session_registry:set(session.username, id or session.resumption_token, nil)
 end
 
-local ack_errors = require"util.error".init("mod_smacks", xmlns_sm3, {
+local ack_errors = require"prosody.util.error".init("mod_smacks", xmlns_sm3, {
 	head = { condition = "undefined-condition"; text = "Client acknowledged more stanzas than sent by server" };
 	tail = { condition = "undefined-condition"; text = "Client acknowledged less stanzas than already acknowledged" };
 	pop = { condition = "internal-server-error"; text = "Something went wrong with Stream Management" };
 	overflow = { condition = "resource-constraint", text = "Too many unacked stanzas remaining, session can't be resumed" }
 });
 
-local enable_errors = require "util.error".init("mod_smacks", xmlns_sm3, {
+local enable_errors = require "prosody.util.error".init("mod_smacks", xmlns_sm3, {
 	already_enabled = { condition = "unexpected-request", text = "Stream management is already enabled" };
 	bind_required = { condition = "unexpected-request", text = "Client must bind a resource before enabling stream management" };
 	unavailable = { condition = "service-unavailable", text = "Stream management is not available for this stream" };
--- a/plugins/mod_stanza_debug.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_stanza_debug.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,6 +1,6 @@
 module:set_global();
 
-local filters = require "util.filters";
+local filters = require "prosody.util.filters";
 
 local function log_send(t, session)
 	if t and t ~= "" and t ~= " " then
--- a/plugins/mod_storage_internal.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_storage_internal.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,12 +1,12 @@
-local cache = require "util.cache";
-local datamanager = require "core.storagemanager".olddm;
-local array = require "util.array";
-local datetime = require "util.datetime";
-local st = require "util.stanza";
-local now = require "util.time".now;
-local id = require "util.id".medium;
-local jid_join = require "util.jid".join;
-local set = require "util.set";
+local cache = require "prosody.util.cache";
+local datamanager = require "prosody.core.storagemanager".olddm;
+local array = require "prosody.util.array";
+local datetime = require "prosody.util.datetime";
+local st = require "prosody.util.stanza";
+local now = require "prosody.util.time".now;
+local id = require "prosody.util.id".medium;
+local jid_join = require "prosody.util.jid".join;
+local set = require "prosody.util.set";
 
 local host = module.host;
 
--- a/plugins/mod_storage_memory.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_storage_memory.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,10 +1,10 @@
-local serialize = require "util.serialization".serialize;
-local array = require "util.array";
-local envload = require "util.envload".envload;
-local st = require "util.stanza";
+local serialize = require "prosody.util.serialization".serialize;
+local array = require "prosody.util.array";
+local envload = require "prosody.util.envload".envload;
+local st = require "prosody.util.stanza";
 local is_stanza = st.is_stanza or function (s) return getmetatable(s) == st.stanza_mt end
-local new_id = require "util.id".medium;
-local set = require "util.set";
+local new_id = require "prosody.util.id".medium;
+local set = require "prosody.util.set";
 
 local auto_purge_enabled = module:get_option_boolean("storage_memory_temporary", false);
 local auto_purge_stores = module:get_option_set("storage_memory_temporary_stores", {});
--- a/plugins/mod_storage_sql.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_storage_sql.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,17 +1,17 @@
 
 -- luacheck: ignore 212/self
 
-local deps = require "util.dependencies";
-local cache = require "util.cache";
-local json = require "util.json";
-local sqlite = deps.softreq "util.sqlite3";
-local dbisql = (sqlite and deps.softreq or require) "util.sql";
-local xml_parse = require "util.xml".parse;
-local uuid = require "util.uuid";
-local resolve_relative_path = require "util.paths".resolve_relative_path;
-local jid_join = require "util.jid".join;
+local deps = require "prosody.util.dependencies";
+local cache = require "prosody.util.cache";
+local json = require "prosody.util.json";
+local sqlite = deps.softreq "prosody.util.sqlite3";
+local dbisql = (sqlite and deps.softreq or require) "prosody.util.sql";
+local xml_parse = require "prosody.util.xml".parse;
+local uuid = require "prosody.util.uuid";
+local resolve_relative_path = require "prosody.util.paths".resolve_relative_path;
+local jid_join = require "prosody.util.jid".join;
 
-local is_stanza = require"util.stanza".is_stanza;
+local is_stanza = require"prosody.util.stanza".is_stanza;
 local t_concat = table.concat;
 
 local noop = function() end
@@ -871,8 +871,8 @@
 end
 
 function module.command(arg)
-	local config = require "core.configmanager";
-	local hi = require "util.human.io";
+	local config = require "prosody.core.configmanager";
+	local hi = require "prosody.util.human.io";
 	local command = table.remove(arg, 1);
 	if command == "upgrade" then
 		-- We need to find every unique dburi in the config
--- a/plugins/mod_storage_xep0227.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_storage_xep0227.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -5,19 +5,19 @@
 local next, unpack = next, table.unpack;
 local os_remove = os.remove;
 local io_open = io.open;
-local jid_bare = require "util.jid".bare;
-local jid_prep = require "util.jid".prep;
-local jid_join = require "util.jid".join;
+local jid_bare = require "prosody.util.jid".bare;
+local jid_prep = require "prosody.util.jid".prep;
+local jid_join = require "prosody.util.jid".join;
 
-local array = require "util.array";
-local base64 = require "util.encodings".base64;
-local dt = require "util.datetime";
-local hex = require "util.hex";
-local it = require "util.iterators";
-local paths = require"util.paths";
-local set = require "util.set";
-local st = require "util.stanza";
-local parse_xml_real = require "util.xml".parse;
+local array = require "prosody.util.array";
+local base64 = require "prosody.util.encodings".base64;
+local dt = require "prosody.util.datetime";
+local hex = require "prosody.util.hex";
+local it = require "prosody.util.iterators";
+local paths = require"prosody.util.paths";
+local set = require "prosody.util.set";
+local st = require "prosody.util.stanza";
+local parse_xml_real = require "prosody.util.xml".parse;
 
 local lfs = require "lfs";
 
--- a/plugins/mod_time.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_time.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,9 +6,9 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
-local datetime = require "util.datetime".datetime;
-local now = require "util.time".now;
+local st = require "prosody.util.stanza";
+local datetime = require "prosody.util.datetime".datetime;
+local now = require "prosody.util.time".now;
 
 -- XEP-0202: Entity Time
 
--- a/plugins/mod_tls.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_tls.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,9 +6,9 @@
 -- COPYING file in the source package for more information.
 --
 
-local create_context = require "core.certmanager".create_context;
-local rawgetopt = require"core.configmanager".rawget;
-local st = require "util.stanza";
+local create_context = require "prosody.core.certmanager".create_context;
+local rawgetopt = require"prosody.core.configmanager".rawget;
+local st = require "prosody.util.stanza";
 
 local c2s_require_encryption = module:get_option("c2s_require_encryption", module:get_option("require_encryption", true));
 local s2s_require_encryption = module:get_option("s2s_require_encryption", true);
--- a/plugins/mod_tokenauth.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_tokenauth.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,10 +1,10 @@
-local base64 = require "util.encodings".base64;
-local hashes = require "util.hashes";
-local id = require "util.id";
-local jid = require "util.jid";
-local random = require "util.random";
-local usermanager = require "core.usermanager";
-local generate_identifier = require "util.id".short;
+local base64 = require "prosody.util.encodings".base64;
+local hashes = require "prosody.util.hashes";
+local id = require "prosody.util.id";
+local jid = require "prosody.util.jid";
+local random = require "prosody.util.random";
+local usermanager = require "prosody.core.usermanager";
+local generate_identifier = require "prosody.util.id".short;
 
 local token_store = module:open_store("auth_tokens", "map");
 
--- a/plugins/mod_tombstones.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_tombstones.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,14 +1,14 @@
 -- TODO warn when trying to create an user before the tombstone expires
 -- e.g. via telnet or other admin interface
-local datetime = require "util.datetime";
-local errors = require "util.error";
-local jid_node = require"util.jid".node;
-local st = require "util.stanza";
+local datetime = require "prosody.util.datetime";
+local errors = require "prosody.util.error";
+local jid_node = require"prosody.util.jid".node;
+local st = require "prosody.util.stanza";
 
 -- Using a map store as key-value store so that removal of all user data
 -- does not also remove the tombstone, which would defeat the point
 local graveyard = module:open_store(nil, "map");
-local graveyard_cache = require "util.cache".new(module:get_option_number("tombstone_cache_size", 1024));
+local graveyard_cache = require "prosody.util.cache".new(module:get_option_number("tombstone_cache_size", 1024));
 
 local ttl = module:get_option_number("user_tombstone_expiry", nil);
 -- Keep tombstones forever by default
--- a/plugins/mod_turn_external.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_turn_external.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,4 +1,4 @@
-local set = require "util.set";
+local set = require "prosody.util.set";
 
 local secret = module:get_option_string("turn_external_secret");
 local host = module:get_option_string("turn_external_host", module.host);
--- a/plugins/mod_uptime.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_uptime.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,7 +6,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 local start_time = prosody.start_time;
 module:hook_global("server-started", function() start_time = prosody.start_time end);
--- a/plugins/mod_user_account_management.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_user_account_management.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,11 +7,11 @@
 --
 
 
-local st = require "util.stanza";
-local usermanager_set_password = require "core.usermanager".set_password;
-local usermanager_delete_user = require "core.usermanager".delete_user;
-local nodeprep = require "util.encodings".stringprep.nodeprep;
-local jid_bare = require "util.jid".bare;
+local st = require "prosody.util.stanza";
+local usermanager_set_password = require "prosody.core.usermanager".set_password;
+local usermanager_delete_user = require "prosody.core.usermanager".delete_user;
+local nodeprep = require "prosody.util.encodings".stringprep.nodeprep;
+local jid_bare = require "prosody.util.jid".bare;
 
 local compat = module:get_option_boolean("registration_compat", true);
 
--- a/plugins/mod_vcard.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_vcard.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,8 +6,8 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza"
-local jid_split = require "util.jid".split;
+local st = require "prosody.util.stanza"
+local jid_split = require "prosody.util.jid".split;
 
 local vcards = module:open_store();
 
--- a/plugins/mod_vcard4.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_vcard4.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,5 +1,5 @@
-local st = require "util.stanza"
-local jid_split = require "util.jid".split;
+local st = require "prosody.util.stanza"
+local jid_split = require "prosody.util.jid".split;
 
 local mod_pep = module:depends("pep");
 
--- a/plugins/mod_vcard_legacy.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_vcard_legacy.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,10 +1,10 @@
-local st = require "util.stanza";
-local jid_split = require "util.jid".split;
+local st = require "prosody.util.stanza";
+local jid_split = require "prosody.util.jid".split;
 
 local mod_pep = module:depends("pep");
 
-local sha1 = require "util.hashes".sha1;
-local base64_decode = require "util.encodings".base64.decode;
+local sha1 = require "prosody.util.hashes".sha1;
+local base64_decode = require "prosody.util.encodings".base64.decode;
 
 local vcards = module:open_store("vcard");
 
--- a/plugins/mod_version.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_version.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -6,7 +6,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 module:add_feature("jabber:iq:version");
 
@@ -20,7 +20,7 @@
 		platform = "Windows";
 	else
 		local os_version_command = module:get_option_string("os_version_command");
-		local ok, pposix = pcall(require, "util.pposix");
+		local ok, pposix = pcall(require, "prosody.util.pposix");
 		if not os_version_command and (ok and pposix and pposix.uname) then
 			platform = pposix.uname().sysname;
 		end
--- a/plugins/mod_watchregistrations.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_watchregistrations.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,14 +8,14 @@
 
 
 local host = module:get_host();
-local jid_prep = require "util.jid".prep;
+local jid_prep = require "prosody.util.jid".prep;
 
 local registration_watchers = module:get_option_set("registration_watchers", module:get_option("admins", {})) / jid_prep;
 local registration_from = module:get_option_string("registration_from", host);
 local registration_notification = module:get_option_string("registration_notification", "User $username just registered on $host from $ip");
 local msg_type = module:get_option_string("registration_notification_type", "chat");
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 module:hook("user-registered", function (user)
 	module:log("debug", "Notifying of new registration");
--- a/plugins/mod_websocket.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_websocket.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,19 +8,19 @@
 
 module:set_global();
 
-local add_task = require "util.timer".add_task;
-local add_filter = require "util.filters".add_filter;
-local sha1 = require "util.hashes".sha1;
-local base64 = require "util.encodings".base64.encode;
-local st = require "util.stanza";
-local parse_xml = require "util.xml".parse;
-local contains_token = require "util.http".contains_token;
-local portmanager = require "core.portmanager";
-local sm_destroy_session = require"core.sessionmanager".destroy_session;
+local add_task = require "prosody.util.timer".add_task;
+local add_filter = require "prosody.util.filters".add_filter;
+local sha1 = require "prosody.util.hashes".sha1;
+local base64 = require "prosody.util.encodings".base64.encode;
+local st = require "prosody.util.stanza";
+local parse_xml = require "prosody.util.xml".parse;
+local contains_token = require "prosody.util.http".contains_token;
+local portmanager = require "prosody.core.portmanager";
+local sm_destroy_session = require"prosody.core.sessionmanager".destroy_session;
 local log = module._log;
-local dbuffer = require "util.dbuffer";
+local dbuffer = require "prosody.util.dbuffer";
 
-local websocket_frames = require"net.websocket.frames";
+local websocket_frames = require"prosody.net.websocket.frames";
 local parse_frame = websocket_frames.parse;
 local build_frame = websocket_frames.build;
 local build_close = websocket_frames.build_close;
@@ -370,6 +370,6 @@
 	module:hook("c2s-read-timeout", keepalive, -0.9);
 end
 
-if require"core.modulemanager".get_modules_for_host("*"):contains(module.name) then
+if require"prosody.core.modulemanager".get_modules_for_host("*"):contains(module.name) then
 	module:add_host();
 end
--- a/plugins/mod_welcome.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/mod_welcome.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -9,7 +9,7 @@
 local host = module:get_host();
 local welcome_text = module:get_option_string("welcome_message", "Hello $username, welcome to the $host IM server!");
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 module:hook("user-registered",
 	function (user)
--- a/plugins/muc/hats.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/hats.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,4 +1,4 @@
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 local muc_util = module:require "muc/util";
 
 local xmlns_hats = "xmpp:prosody.im/protocol/hats:1";
--- a/plugins/muc/history.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/history.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -8,8 +8,8 @@
 --
 
 local gettime = os.time;
-local datetime = require "util.datetime";
-local st = require "util.stanza";
+local datetime = require "prosody.util.datetime";
+local st = require "prosody.util.stanza";
 
 local default_history_length = 20;
 local max_history_length = module:get_option_number("max_history_messages", math.huge);
--- a/plugins/muc/lock.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/lock.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,7 +7,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 local lock_rooms = module:get_option_boolean("muc_room_locking", true);
 local lock_room_timeout = module:get_option_number("muc_room_lock_timeout", 300);
--- a/plugins/muc/members_only.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/members_only.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,7 +7,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 local muc_util = module:require "muc/util";
 local valid_affiliations = muc_util.valid_affiliations;
--- a/plugins/muc/mod_muc.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/mod_muc.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -95,11 +95,11 @@
 room_mt.get_salt = occupant_id.get_room_salt;
 room_mt.get_occupant_id = occupant_id.get_occupant_id;
 
-local jid_split = require "util.jid".split;
-local jid_prep = require "util.jid".prep;
-local jid_bare = require "util.jid".bare;
-local st = require "util.stanza";
-local cache = require "util.cache";
+local jid_split = require "prosody.util.jid".split;
+local jid_prep = require "prosody.util.jid".prep;
+local jid_bare = require "prosody.util.jid".bare;
+local st = require "prosody.util.stanza";
+local cache = require "prosody.util.cache";
 
 module:require "muc/config_form_sections";
 
@@ -506,10 +506,10 @@
 	module:depends "adhoc";
 	local t_concat = table.concat;
 	local adhoc_new = module:require "adhoc".new;
-	local adhoc_initial = require "util.adhoc".new_initial_data_form;
-	local adhoc_simple = require "util.adhoc".new_simple_form;
-	local array = require "util.array";
-	local dataforms_new = require "util.dataforms".new;
+	local adhoc_initial = require "prosody.util.adhoc".new_initial_data_form;
+	local adhoc_simple = require "prosody.util.adhoc".new_simple_form;
+	local array = require "prosody.util.array";
+	local dataforms_new = require "prosody.util.dataforms".new;
 
 	local destroy_rooms_layout = dataforms_new {
 		title = "Destroy rooms";
--- a/plugins/muc/muc.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/muc.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -12,18 +12,18 @@
 local next = next;
 local setmetatable = setmetatable;
 
-local dataform = require "util.dataforms";
-local iterators = require "util.iterators";
-local jid_split = require "util.jid".split;
-local jid_bare = require "util.jid".bare;
-local jid_prep = require "util.jid".prep;
-local jid_join = require "util.jid".join;
-local jid_resource = require "util.jid".resource;
-local resourceprep = require "util.encodings".stringprep.resourceprep;
-local st = require "util.stanza";
-local base64 = require "util.encodings".base64;
-local hmac_sha256 = require "util.hashes".hmac_sha256;
-local new_id = require "util.id".medium;
+local dataform = require "prosody.util.dataforms";
+local iterators = require "prosody.util.iterators";
+local jid_split = require "prosody.util.jid".split;
+local jid_bare = require "prosody.util.jid".bare;
+local jid_prep = require "prosody.util.jid".prep;
+local jid_join = require "prosody.util.jid".join;
+local jid_resource = require "prosody.util.jid".resource;
+local resourceprep = require "prosody.util.encodings".stringprep.resourceprep;
+local st = require "prosody.util.stanza";
+local base64 = require "prosody.util.encodings".base64;
+local hmac_sha256 = require "prosody.util.hashes".hmac_sha256;
+local new_id = require "prosody.util.id".medium;
 
 local log = module._log;
 
--- a/plugins/muc/occupant.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/occupant.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,6 +1,6 @@
 local pairs = pairs;
 local setmetatable = setmetatable;
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 local util = module:require "muc/util";
 
 local function get_filtered_presence(stanza)
--- a/plugins/muc/occupant_id.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/occupant_id.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -4,9 +4,9 @@
 -- (C) 2020 Maxime “pep” Buquet <pep@bouah.net>
 -- (C) 2020 Matthew Wild <mwild1@gmail.com>
 
-local uuid = require "util.uuid";
-local hmac_sha256 = require "util.hashes".hmac_sha256;
-local b64encode = require "util.encodings".base64.encode;
+local uuid = require "prosody.util.uuid";
+local hmac_sha256 = require "prosody.util.hashes".hmac_sha256;
+local b64encode = require "prosody.util.encodings".base64.encode;
 
 local xmlns_occupant_id = "urn:xmpp:occupant-id:0";
 
--- a/plugins/muc/password.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/password.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,7 +7,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 local function get_password(room)
 	return room._data.password;
--- a/plugins/muc/presence_broadcast.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/presence_broadcast.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,7 +7,7 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
+local st = require "prosody.util.stanza";
 
 local valid_roles = { "none", "visitor", "participant", "moderator" };
 local default_broadcast = {
--- a/plugins/muc/register.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/register.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -1,8 +1,8 @@
-local jid_bare = require "util.jid".bare;
-local jid_resource = require "util.jid".resource;
-local resourceprep = require "util.encodings".stringprep.resourceprep;
-local st = require "util.stanza";
-local dataforms = require "util.dataforms";
+local jid_bare = require "prosody.util.jid".bare;
+local jid_resource = require "prosody.util.jid".resource;
+local resourceprep = require "prosody.util.encodings".stringprep.resourceprep;
+local st = require "prosody.util.stanza";
+local dataforms = require "prosody.util.dataforms";
 
 local allow_unaffiliated = module:get_option_boolean("allow_unaffiliated_register", false);
 
--- a/plugins/muc/request.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/request.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,14 +7,14 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
-local jid_resource = require "util.jid".resource;
+local st = require "prosody.util.stanza";
+local jid_resource = require "prosody.util.jid".resource;
 
 module:hook("muc-disco#info", function(event)
 	event.reply:tag("feature", {var = "http://jabber.org/protocol/muc#request"}):up();
 end);
 
-local voice_request_form = require "util.dataforms".new({
+local voice_request_form = require "prosody.util.dataforms".new({
 	title = "Voice Request";
 	{
 		name = "FORM_TYPE";
--- a/plugins/muc/subject.lib.lua	Fri Mar 17 18:03:07 2023 +0100
+++ b/plugins/muc/subject.lib.lua	Fri Mar 24 13:15:28 2023 +0100
@@ -7,8 +7,8 @@
 -- COPYING file in the source package for more information.
 --
 
-local st = require "util.stanza";
-local dt = require "util.datetime";
+local st = require "prosody.util.stanza";
+local dt = require "prosody.util.datetime";
 
 local muc_util = module:require "muc/util";
 local valid_roles = muc_util.valid_roles;