1
0
Fork 0
mirror of git://git.psyced.org/git/psyced synced 2024-08-15 03:25:10 +00:00

fippo redo: don't offer an empty list of mechanisms

This commit is contained in:
psyc://psyced.org/~lynX 2010-11-18 13:08:16 +01:00
parent 1a38cfdc6f
commit a3c6758bba

View file

@ -530,7 +530,6 @@ open_stream(XMLNode node) {
packet += "<starttls xmlns='" NS_XMPP "xmpp-tls'/>"; packet += "<starttls xmlns='" NS_XMPP "xmpp-tls'/>";
} else unless (mappingp(authhosts)) { } else unless (mappingp(authhosts)) {
# ifdef WANT_S2S_SASL # ifdef WANT_S2S_SASL
packet += "<mechanisms xmlns='" NS_XMPP "xmpp-sasl'>";
// if the other side did present a client certificate // if the other side did present a client certificate
// and we have verified it as X509_V_OK (0) // and we have verified it as X509_V_OK (0)
// we offer SASL external (authentication via name // we offer SASL external (authentication via name
@ -545,11 +544,12 @@ open_stream(XMLNode node) {
if (node["@from"] && if (node["@from"] &&
certificate_check_jabbername(node["@from"], certificate_check_jabbername(node["@from"],
certinfo)) { certinfo)) {
packet += "<mechanisms xmlns='" NS_XMPP "xmpp-sasl'>";
packet += "<mechanism>EXTERNAL</mechanism>"; packet += "<mechanism>EXTERNAL</mechanism>";
packet += "</mechanisms>";
} }
} }
# endif # endif
packet += "</mechanisms>";
# endif # endif
} }
} }