Netscape developed SSL in 1994 as a result of the growing concern about security on the Internet. SSL was later converted to a standard called Transport Layer Security (TLS). Devices running Windows Mobile Professional and Windows Mobile Standard support SSL version 2.0, SSL version 3.0, and SSL version 3.1. SSL version 3.1 is most commonly known as TLS version 1.0 (RFC 2246).
The primary use of the technology was (and still is) to secure the communication between a browser and a Web server (by using HTTP), which also is the focus of this article, but this primary use has been combined with many other technologies for email messages (SMTP), file transfers (FTP), newsgroups (NNTP), and so on. Today, SSL is an accepted standard that is endorsed by the major credit card companies (such as Visa, MasterCard, and American Express) and many other leading financial institutions.
The following is a high-level description about how SSL works:
-
A client (normally a browser) requests a secure page (the URL begins with https://).
-
The Web server sends its public key, with its certificate, to the client.
-
The client checks that a trusted party (a Certification Authority [CA]) issued the certificate, that the certificate is still valid, and that the certificate is related to the site contacted.
-
The client uses the public key to generate an encryption key, and sends the encryption key to the server with the URL required (in an encrypted format).
-
The Web server decrypts the encryption key by using its private key, and then uses the key to decrypt the browser's request. The Web server sends back the requested data, which is encrypted with the key.
-
The client decrypts the data by using the encryption key, and uses the information (typically, the client displays the information through a browser).
Encryption that uses a private and public key pair ensures that the data that one key encrypted can only be decrypted by the other key. The keys have similar formats, and they are based on prime numbers.
A mathematical example can explain how the two different keys can be used. Assume that the public key is five (5), the private key is a fifth (1/5 or 0.2), and the algorithm for encryption was multiplication. If person A wanted to send person B the message three (3), the encrypted message that uses the public key would be 15 (5 x 3). When person B received the message, person B could decrypt it with the private key (15 x 0.2) to get the message three (3).
The key length ensures the difficulty to decrypt the messages. Initially, only 40-bit (5-byte) keys were used, but such keys offer 1,099,511,627,776 possible combinations, which—for a computer—is not really that many. It takes a normal desktop computer a couple of weeks to find a 40-bit key, and it takes military intelligence microseconds. A 128-bit key offers exactly 340,282,366,920,938,463,463,374,607,431,768,211,456 different combinations, and it is generally considered to be secure for at least a century ahead (because that's at least how long a military intelligence computer would need to decrypt it).
It is necessary to keep one key secret (the private key) and to distribute the other key (the public key) to anyone who needs to send you an encrypted message. This secrecy ensures that anybody can send you an encrypted message that only your computer or device will be able to decrypt. It also works in the reverse—others can certify that a message comes from you because you have encrypted it with your private key, and only the associated public key will decrypt the message correctly.
As already mentioned, a remote host proves its trustworthiness by obtaining a certificate from a CA. The CA can, in turn, have certification from a higher authority and so on, creating a chain of trust. To determine whether a certificate is trustworthy, an application must determine the identity of the root CA and then determine if the root CA is trustworthy.
SSL for devices running Windows Mobile Professional and Windows Mobile Standard uses trusted CAs. When an application attempts to create a secure connection, SSL extracts the root certificate from the certification chain and checks it against the CA database in the device. It delivers the server certificate to the application through a certificate validation callback function, which also delivers the results of the comparison against the CA database.
A certificate is data that represent a user's identity. Certificates that are used with SSL are based on the X.509 standard (RFC 3280). The X.509 standard is a Public Key Infrastructure (PKI) that allows a third party (a CA) to vouch for a user's identity. The CA, known as the certificate issuer, assigns a certificate to an individual or an entity that associates a public key with the individual or entity. The individual or entity to which a certificate is issued is called the subject of that certificate. A trustworthy CA only issues a certificate after verifying the identity of the certificate's subject.
The following resources are secure links to valid CA authorities: Cybertrust, Entrust, Equifax, GlobalSign, Thawte, and VeriSign.