I came across aSSL, which appears to be a couple of years old and was wondering if anyone has other examples of "secure" AJAX connection code? Obviously, this wouldn't be as secure as using a SSL certificate, but with the null character SSL attack out there (recently demonstrated against PayPal), would it be worthwhile to revisit something like aSSL for sites that need to be "highly" secure such as online banking, etc? And, if so, what would be the best way to go about it?
The only way of having a secure channel is by knowing for sure that the other party is who you think he is. This is where the PKI (Public Key Infrastructure) comes into play with SSL. Without a PKI, it is very hard to have "trust" and this is exactly what CAs (certification authorities) sell.
An example of a system without an explicit CA is PGP, however, the porblem is that it is hard to know if the person who claims to be person X having public key Kx is not in reality person Y having public key Ky.
So it's best to stick to default SSL instead of using some commercial/open source software that is made by semi-professionals.
To avoid any issues with the null character SSL flaw, online banks should use an EV SSL certificate because they are not affected. aSSL might be a good addition to an EV SSL certificate.
The opensource Forge project provides a JavaScript implementation of SSL (TLS) and has an XmlHttpRequest wrapper for using it in ajax calls.