I have tested it multiple times against 3.4.1-3.4.4 versions of openfire. I verified packet encryption using Wireshark. I've tested this in both Flex and Air applications.
Things you need...
- AS3 version of XIFF
- replace XMPPConnection with attached version
- replace XMPPSocketConnection with attached version
- Latest Crypto
- add UTF8String to util/der
- replace DER with attached (additional type support for openfire certs)
Things to note before hand.
- This only works with XMPPSocketConnection
- I'm not sure but I think crypto will only work with RSA certs. I could be wrong though. Will be checking into it more later.
- Crypto does not work with self signed certificates (detault certs generated by openfire). This can be bipassed by commenting out the checks in TLSEngine.loadCertificates(certs:Array). Just leave these two lines uncommented in the if block that checks for signed/unsigned.
trace("TLS WARNING: No check made on the certificate's identity.");
_otherCertificate = firstCert;
To use TLS simply use the following boolean flag on your interface scripting that handles the initial connect. Here is my example code block.
xconn.username = usernameti.text;
userAccount = usernameti.text;
xconn.password = passwordti.text;
xconn.server = DEFAULT_SERVER;
xconn.tls = true;
xconn.connect("standard");
Enjoy! Let me know if you have any success. Not all the kinks have been worked out but it's a good start.