Software /
code /
prosody
Diff
plugins/mod_s2s.lua @ 11774:4625093b0768
mod_s2s: Add a Direct TLS listener
Mirroring the c2s 'direct_tls'. Naming things is hard.
direct_tls_s2s_ports = { 5269+1 }
author | Kim Alvefur <zash@zash.se> |
---|---|
date | Tue, 10 Aug 2021 20:55:43 +0200 |
parent | 11773:c5f2b63cf6ff |
child | 11775:af9c7f3f4735 |
line wrap: on
line diff
--- a/plugins/mod_s2s.lua Tue Aug 10 20:54:38 2021 +0200 +++ b/plugins/mod_s2s.lua Tue Aug 10 20:55:43 2021 +0200 @@ -967,3 +967,17 @@ }; }); + +module:provides("net", { + name = "direct_tls_s2s"; + listener = listener; + encryption = "ssl"; + ssl_config = { + verify = { "peer", "client_once", }; + }; + multiplex = { + protocol = "xmpp-server"; + pattern = "^<.*:stream.*%sxmlns%s*=%s*(['\"])jabber:server%1.*>"; + }; +}); +