<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd"> <html xmlns="http://www.w3.org/1999/xhtml"> <head> <meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/> <meta http-equiv="X-UA-Compatible" content="IE=9"/> <meta name="generator" content="Doxygen 1.8.5"/> <title>PolarSSL v1.3.8: config-ccm-psk-tls1_2.h Source File</title> <link href="tabs.css" rel="stylesheet" type="text/css"/> <script type="text/javascript" src="jquery.js"></script> <script type="text/javascript" src="dynsections.js"></script> <link href="doxygen.css" rel="stylesheet" type="text/css" /> </head> <body> <div id="top"><!-- do not remove this div, it is closed by doxygen! --> <div id="titlearea"> <table cellspacing="0" cellpadding="0"> <tbody> <tr style="height: 56px;"> <td style="padding-left: 0.5em;"> <div id="projectname">PolarSSL v1.3.8 </div> </td> </tr> </tbody> </table> </div> <!-- end header part --> <!-- Generated by Doxygen 1.8.5 --> <div id="navrow1" class="tabs"> <ul class="tablist"> <li><a href="index.html"><span>Main Page</span></a></li> <li><a href="modules.html"><span>Modules</span></a></li> <li><a href="annotated.html"><span>Data Structures</span></a></li> <li class="current"><a href="files.html"><span>Files</span></a></li> </ul> </div> <div id="navrow2" class="tabs2"> <ul class="tablist"> <li><a href="files.html"><span>File List</span></a></li> <li><a href="globals.html"><span>Globals</span></a></li> </ul> </div> <div id="nav-path" class="navpath"> <ul> <li class="navelem"><a class="el" href="dir_04fc776559bc86402b9b97d98656c154.html">configs</a></li> </ul> </div> </div><!-- top --> <div class="header"> <div class="headertitle"> <div class="title">config-ccm-psk-tls1_2.h</div> </div> </div><!--header--> <div class="contents"> <a href="config-ccm-psk-tls1__2_8h.html">Go to the documentation of this file.</a><div class="fragment"><div class="line"><a name="l00001"></a><span class="lineno"> 1</span> <span class="comment">/*</span></div> <div class="line"><a name="l00002"></a><span class="lineno"> 2</span> <span class="comment"> * Minimal configuration for TLS 1.2 with PSK and AES-CCM ciphersuites</span></div> <div class="line"><a name="l00003"></a><span class="lineno"> 3</span> <span class="comment"> * Distinguishing features:</span></div> <div class="line"><a name="l00004"></a><span class="lineno"> 4</span> <span class="comment"> * - no bignum, no PK, no X509</span></div> <div class="line"><a name="l00005"></a><span class="lineno"> 5</span> <span class="comment"> * - fully modern and secure (provided the pre-shared keys have high entropy)</span></div> <div class="line"><a name="l00006"></a><span class="lineno"> 6</span> <span class="comment"> * - very low record overhead with CCM-8</span></div> <div class="line"><a name="l00007"></a><span class="lineno"> 7</span> <span class="comment"> * - optimized for low RAM usage</span></div> <div class="line"><a name="l00008"></a><span class="lineno"> 8</span> <span class="comment"> *</span></div> <div class="line"><a name="l00009"></a><span class="lineno"> 9</span> <span class="comment"> * See README.txt for usage instructions.</span></div> <div class="line"><a name="l00010"></a><span class="lineno"> 10</span> <span class="comment"> */</span></div> <div class="line"><a name="l00011"></a><span class="lineno"> 11</span> <span class="preprocessor">#ifndef POLARSSL_CONFIG_H</span></div> <div class="line"><a name="l00012"></a><span class="lineno"> 12</span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_CONFIG_H</span></div> <div class="line"><a name="l00013"></a><span class="lineno"> 13</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00014"></a><span class="lineno"> 14</span> <span class="comment">/* System support */</span></div> <div class="line"><a name="l00015"></a><span class="lineno"> 15</span> <span class="comment">//#define POLARSSL_HAVE_IPV6 /* Optional */</span></div> <div class="line"><a name="l00016"></a><span class="lineno"> 16</span> <span class="comment">//#define POLARSSL_HAVE_TIME /* Optionally used in Hello messages */</span></div> <div class="line"><a name="l00017"></a><span class="lineno"> 17</span> <span class="comment">/* Other POLARSSL_HAVE_XXX flags irrelevant for this configuration */</span></div> <div class="line"><a name="l00018"></a><span class="lineno"> 18</span> </div> <div class="line"><a name="l00019"></a><span class="lineno"> 19</span> <span class="comment">/* PolarSSL feature support */</span></div> <div class="line"><a name="l00020"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#aac9d1fa5aca6ddbbddcf6c09e16d2f6f"> 20</a></span> <span class="preprocessor">#define POLARSSL_KEY_EXCHANGE_PSK_ENABLED</span></div> <div class="line"><a name="l00021"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a73b7dcb9072ea5db3a35c3cf5b3d859e"> 21</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_SSL_PROTO_TLS1_2</span></div> <div class="line"><a name="l00022"></a><span class="lineno"> 22</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00023"></a><span class="lineno"> 23</span> <span class="comment">/* PolarSSL modules */</span></div> <div class="line"><a name="l00024"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a3310b96b376135cdd739f1d1b1e309a8"> 24</a></span> <span class="preprocessor">#define POLARSSL_AES_C</span></div> <div class="line"><a name="l00025"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a1a58329d93147bce881b202fc9ec6846"> 25</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_CCM_C</span></div> <div class="line"><a name="l00026"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#ad19dd8aaf92e684518f3ea50314e779b"> 26</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_CIPHER_C</span></div> <div class="line"><a name="l00027"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a110dc4418f57b7b3b4f5c94479c8fa0c"> 27</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_CTR_DRBG_C</span></div> <div class="line"><a name="l00028"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a99fb86fb5ae02c8b652a2f1b003d2c76"> 28</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_ENTROPY_C</span></div> <div class="line"><a name="l00029"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#ae87e3dca8e39209137f7aeb3fc1ad4fd"> 29</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_MD_C</span></div> <div class="line"><a name="l00030"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a152f79d8afbf6676a45b6103169f8b1b"> 30</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_NET_C</span></div> <div class="line"><a name="l00031"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a953ccd4b55da116c3572126292df3fb2"> 31</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_SHA256_C</span></div> <div class="line"><a name="l00032"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a7004f00316cf53a70221441e62730fb2"> 32</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_SSL_CLI_C</span></div> <div class="line"><a name="l00033"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#ab7e0e775b47f9651aa04ccf3a2ebd6f2"> 33</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_SSL_SRV_C</span></div> <div class="line"><a name="l00034"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a4d9bde1b523dcd9a4e009cfcaba96096"> 34</a></span> <span class="preprocessor"></span><span class="preprocessor">#define POLARSSL_SSL_TLS_C</span></div> <div class="line"><a name="l00035"></a><span class="lineno"> 35</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00036"></a><span class="lineno"> 36</span> <span class="comment">/* Save RAM at the expense of ROM */</span></div> <div class="line"><a name="l00037"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#afdee84e240d9d1420aa45c7adca21473"> 37</a></span> <span class="preprocessor">#define POLARSSL_AES_ROM_TABLES</span></div> <div class="line"><a name="l00038"></a><span class="lineno"> 38</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00039"></a><span class="lineno"> 39</span> <span class="comment">/* Save some RAM by adjusting to your exact needs */</span></div> <div class="line"><a name="l00040"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a2c09f3b3bad4c092d408b4039196120c"> 40</a></span> <span class="preprocessor">#define POLARSSL_PSK_MAX_LEN 16 </span><span class="comment">/* 128-bits keys are generally enough */</span><span class="preprocessor"></span></div> <div class="line"><a name="l00041"></a><span class="lineno"> 41</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00042"></a><span class="lineno"> 42</span> <span class="comment">/*</span></div> <div class="line"><a name="l00043"></a><span class="lineno"> 43</span> <span class="comment"> * You should adjust this to the exact number of sources you're using: default</span></div> <div class="line"><a name="l00044"></a><span class="lineno"> 44</span> <span class="comment"> * is the "platform_entropy_poll" source, but you may want to add other ones</span></div> <div class="line"><a name="l00045"></a><span class="lineno"> 45</span> <span class="comment"> * Minimum is 2 for the entropy test suite.</span></div> <div class="line"><a name="l00046"></a><span class="lineno"> 46</span> <span class="comment"> */</span></div> <div class="line"><a name="l00047"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a5e9ba2c083acc78efc758deca62d162d"> 47</a></span> <span class="preprocessor">#define ENTROPY_MAX_SOURCES 2</span></div> <div class="line"><a name="l00048"></a><span class="lineno"> 48</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00049"></a><span class="lineno"> 49</span> <span class="comment">/*</span></div> <div class="line"><a name="l00050"></a><span class="lineno"> 50</span> <span class="comment"> * Use only CCM_8 ciphersuites, and</span></div> <div class="line"><a name="l00051"></a><span class="lineno"> 51</span> <span class="comment"> * save ROM and a few bytes of RAM by specifying our own ciphersuite list</span></div> <div class="line"><a name="l00052"></a><span class="lineno"> 52</span> <span class="comment"> */</span></div> <div class="line"><a name="l00053"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#af73cc539c9d46097e9cb75a5bfc43393"> 53</a></span> <span class="preprocessor">#define SSL_CIPHERSUITES \</span></div> <div class="line"><a name="l00054"></a><span class="lineno"> 54</span> <span class="preprocessor"> TLS_PSK_WITH_AES_256_CCM_8, \</span></div> <div class="line"><a name="l00055"></a><span class="lineno"> 55</span> <span class="preprocessor"> TLS_PSK_WITH_AES_128_CCM_8</span></div> <div class="line"><a name="l00056"></a><span class="lineno"> 56</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00057"></a><span class="lineno"> 57</span> <span class="comment">/*</span></div> <div class="line"><a name="l00058"></a><span class="lineno"> 58</span> <span class="comment"> * Save RAM at the expense of interoperability: do this only if you control</span></div> <div class="line"><a name="l00059"></a><span class="lineno"> 59</span> <span class="comment"> * both ends of the connection! (See comments in "polarssl/ssl.h".)</span></div> <div class="line"><a name="l00060"></a><span class="lineno"> 60</span> <span class="comment"> * The optimal size here depends on the typical size of records.</span></div> <div class="line"><a name="l00061"></a><span class="lineno"> 61</span> <span class="comment"> */</span></div> <div class="line"><a name="l00062"></a><span class="lineno"><a class="line" href="config-ccm-psk-tls1__2_8h.html#a70bafb07a819e6bf9df2c97ce6dd139d"> 62</a></span> <span class="preprocessor">#define SSL_MAX_CONTENT_LEN 512</span></div> <div class="line"><a name="l00063"></a><span class="lineno"> 63</span> <span class="preprocessor"></span></div> <div class="line"><a name="l00064"></a><span class="lineno"> 64</span> <span class="preprocessor">#include "<a class="code" href="check__config_8h.html">check_config.h</a>"</span></div> <div class="line"><a name="l00065"></a><span class="lineno"> 65</span> </div> <div class="line"><a name="l00066"></a><span class="lineno"> 66</span> <span class="preprocessor">#endif </span><span class="comment">/* POLARSSL_CONFIG_H */</span><span class="preprocessor"></span></div> <div class="ttc" id="check__config_8h_html"><div class="ttname"><a href="check__config_8h.html">check_config.h</a></div><div class="ttdoc">Consistency checks for configuration options. </div></div> </div><!-- fragment --></div><!-- contents --> <!-- start footer part --> <hr class="footer"/><address class="footer"><small> Generated on Thu Jul 31 2014 11:35:51 for PolarSSL v1.3.8 by  <a href="http://www.doxygen.org/index.html"> <img class="footer" src="doxygen.png" alt="doxygen"/> </a> 1.8.5 </small></address> </body> </html>