util.xml: Deduplicate handlers for restricted XML
Makes the code more like util.xmppstream, allowing easier comparisons if
we ever need to apply fixes in the future.
For full information on our dependencies, version requirements, and
where to find them, see https://prosody.im/doc/depends
If you have luarocks available on your platform, install the following:
- luaexpat
- luasocket
- luafilesystem
- luasec