22.03.2013 Views

AT+i Programmer's Manual - SE Spezial-Electronic AG

AT+i Programmer's Manual - SE Spezial-Electronic AG

AT+i Programmer's Manual - SE Spezial-Electronic AG

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

20 Secure Socket Protocol<br />

Secure Socket Protocol<br />

iChip supports the SSL3/TLS1 secure socket protocol, based on RFC2246. iChip<br />

supports the following Cipher suites:<br />

SSL_RSA_WITH_RC4_128_MD5<br />

SSL_RSA_WITH_RC4_128_SHA<br />

SSL_RSA_WITH_3DES_EDE_CBC_SHA<br />

TLS_RSA_WITH_AES_128_CBC_SHA<br />

TLS_RSA_WITH_AES_256_CBC_SHA<br />

20.1 Establishing An SSL3/TLS1 Socket Connection<br />

iChip supports a single SSL3/TLS1 TCP/IP active socket connection. Opening a secure<br />

socket on iChip involves two steps:<br />

1. Open a standard TCP/IP socket to a secure server.<br />

2. Initiate an SSL3/TLS1 handshake over the open socket to establish a secure session.<br />

SSL3/TLS1 handshake negotiations are initiated using the <strong>AT+i</strong>SSL command.<br />

iChip negotiates the secure connection based on several security-related parameters. It<br />

authenticates the remote secure server by verifying that the server‘s certificate is signed<br />

by a trusted Certificate Authority (CA). The trusted CA‘s certificate is stored in iChip‘s<br />

CA parameter. Following a successful SSL3/TLS1 handshake, iChip encrypts all data<br />

sent across the socket according to the cipher suite and keys agreed upon during the<br />

handshake. Data received on the socket is decrypted by iChip prior to making it available<br />

to the host processor.<br />

20.2 Sending and Receiving Data over An SSL3/TLS1 Socket<br />

The <strong>AT+i</strong>SSND command is used to send data over an SSL3/TLS1 socket, using the<br />

same syntax as for non-secure sockets:<br />

<strong>AT+i</strong>SSND[%]:,:<br />

However, the size parameter is interpreted as the size of the data packet to encrypt. It is<br />

limited to 2K. Receiving data on an SSL3/TLS1 socket is carried out using the<br />

<strong>AT+i</strong>SRCV command. iChip automatically decrypts data that arrives on the secure<br />

socket. The data transferred to the host is always decrypted data.<br />

20.3 SSL3/TLS1 Handshake and Session Example<br />

Take for example an SSL3/TLS1 server at secure.sslserver.com running a secure<br />

application on port 1503. Using iChip, the following sequence opens a secure<br />

SSL3/TLS1 socket to that application and exchanges data securely. For clarity,<br />

commands sent to iChip appear in bold and iChip replies appear in italics.

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!