summaryrefslogtreecommitdiffstats
path: root/src/pedro/pedroxmpp.cpp
diff options
context:
space:
mode:
authorBob Jamison <ishmalius@gmail.com>2006-05-28 23:03:10 +0000
committerishmal <ishmal@users.sourceforge.net>2006-05-28 23:03:10 +0000
commitd469324c78c048a6b666b6da1a00642679b2ee8a (patch)
tree9f39185b07f8cdd67aedc1094209afe4efaa5248 /src/pedro/pedroxmpp.cpp
parent(bzr r1046) (diff)
downloadinkscape-d469324c78c048a6b666b6da1a00642679b2ee8a.tar.gz
inkscape-d469324c78c048a6b666b6da1a00642679b2ee8a.zip
Add code to generate and display an SSL-connection event with a padlock
(bzr r1047)
Diffstat (limited to 'src/pedro/pedroxmpp.cpp')
-rw-r--r--src/pedro/pedroxmpp.cpp14
1 files changed, 12 insertions, 2 deletions
diff --git a/src/pedro/pedroxmpp.cpp b/src/pedro/pedroxmpp.cpp
index 92fa2f9a1..1f137850f 100644
--- a/src/pedro/pedroxmpp.cpp
+++ b/src/pedro/pedroxmpp.cpp
@@ -632,7 +632,7 @@ public:
static void hash(unsigned char *dataIn,
unsigned long len, unsigned char *digest);
- static DOMString Md5::hashHex(unsigned char *dataIn, unsigned long len);
+ static DOMString hashHex(unsigned char *dataIn, unsigned long len);
/**
* Initialize the context (also zeroizes contents)
@@ -3866,6 +3866,9 @@ bool XmppClient::saslAuthenticate()
recbuf = readStanza();
status("RECV: '%s'\n", recbuf.c_str());
elem = parser.parse(recbuf);
+
+ XmppEvent event(XmppEvent::EVENT_SSL_STARTED);
+ dispatchXmppEvent(event);
}
//register, if user requests
@@ -3966,6 +3969,12 @@ bool XmppClient::createSession()
return false;
}
+ if (sock->getEnableSSL())
+ {
+ XmppEvent event(XmppEvent::EVENT_SSL_STARTED);
+ dispatchXmppEvent(event);
+ }
+
char *fmt =
"<stream:stream "
"to='%s' "
@@ -4669,7 +4678,8 @@ bool XmppClient::groupChatPresence(const DOMString &groupJid,
char *fmt =
"<presence from='%s' to='%s/%s' type='unavailable'>"
"<x xmlns='http://jabber.org/protocol/muc'/></presence>\n";
- if (!write(fmt, jid.c_str(), groupJid.c_str(), user.c_str(), xmlPresence.c_str()))
+ if (!write(fmt, jid.c_str(), groupJid.c_str(),
+ user.c_str(), xmlPresence.c_str()))
return true;
return true;
}