-
| Hi, I'm considering selfhosting ejabberd to join the XMPP network, and hope this is the right place to ask about the protocol before proceeding. I've noticed in RFC6120 that, with STARTTLS, the initiator sends unencrypted details about the initiating entity  I've also seen the following on section 4.7.1 of the RFC: 
 Given the information above I would like to ask: is my hypothesis is correct, that there is leakage of userinfo by using STARTTLS? And would exclusively using Direct TLS prevent this, as the TLS negotiation happens before any identity is sent over the wire? Also, are there any further security benefits of using Direct TLS? I've seen XEP-0368 indicating ALPN privacy, and I suppose this is because the  I suppose the answers can be found with Wireshark, but it's better getting confirmation from someone in-the-know. I've also checked #1423 and the blogpost on TLS. The main reason that Direct TLS isn't recommended there is lack of SNI support and multi-domain deployments. I believe this does not apply to my use case as I'm looking to deploy a single-domain instance. Hope for any answers, and thanks in advance. | 
Beta Was this translation helpful? Give feedback.
Replies: 2 comments 2 replies
-
| that blogpost is so old, the hammer swung back already...now DirectTLS is the best one | 
Beta Was this translation helpful? Give feedback.
-
| With starttls only server address is sent unencrypted, username or auth information are sent only after encryption is already established. And until TLS1.3 this was also the case for direct tls, only this version did gain ability to pass hostname encrypted. At this point starttls is just curiosity that was needed at a time it was introduced, it was used to allow to serve multiple domains from single ip address, when this was added to XMPP the only way to be able to serve tls traffic was single domain per single ip address (server could have just single certificate, and that limited it to single domain). Later tls was extended with SNI which made client tell server what domain it wanted to connect, and allowed server to choose what certificate to present - at this point you could have just direct tls that worked as good as starttls - but it still weren't more secure, domain name was still send in plain text. Only TLS1.3 (and i believe also not initially), had enough features to allow encrypting domain accessed, and with that direct tls expose less info than starttls. | 
Beta Was this translation helpful? Give feedback.
With starttls only server address is sent unencrypted, username or auth information are sent only after encryption is already established. And until TLS1.3 this was also the case for direct tls, only this version did gain ability to pass hostname encrypted.
At this point starttls is just curiosity that was needed at a time it was introduced, it was used to allow to serve multiple domains from single ip address, when this was added to XMPP the only way to be able to serve tls traffic was single domain per single ip address (server could have just single certificate, and that limited it to single domain). Later tls was extended with SNI which made client tell server what domain it wanted to…