summaryrefslogtreecommitdiffstats
path: root/apps
diff options
context:
space:
mode:
authorCarlos Alberto Lopez Perez <clopez@igalia.com>2012-08-06 01:45:51 +0200
committerBen Laurie <ben@links.org>2013-09-05 17:24:55 +0100
commit4e48c77572a9a96a301e362a3646cd3cc7eca0f9 (patch)
tree6de3bb975e7e0d1947c295997529a98c7469ccde /apps
parentdece3209f299ebcd82414868ee39b2c6feb3be0a (diff)
Fix XMPP code detection on s_client starttls xmpp
* Some XMPP Servers (OpenFire) use double quotes. * This makes s_client starttls work with this servers. * Tested with OpenFire servers from http://xmpp.net/ :: openssl s_client -connect coderollers.com:5222 -starttls xmpp
Diffstat (limited to 'apps')
-rw-r--r--apps/s_client.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/apps/s_client.c b/apps/s_client.c
index 61ad29134b..c38c42e037 100644
--- a/apps/s_client.c
+++ b/apps/s_client.c
@@ -1673,7 +1673,8 @@ SSL_set_tlsext_status_ids(con, ids);
"xmlns='jabber:client' to='%s' version='1.0'>", host);
seen = BIO_read(sbio,mbuf,BUFSIZZ);
mbuf[seen] = 0;
- while (!strstr(mbuf, "<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'"))
+ while (!strstr(mbuf, "<starttls xmlns='urn:ietf:params:xml:ns:xmpp-tls'") &&
+ !strstr(mbuf, "<starttls xmlns=\"urn:ietf:params:xml:ns:xmpp-tls\""))
{
if (strstr(mbuf, "/stream:features>"))
goto shut;