| 1 | <!DOCTYPE html> |
| 2 | <html> |
| 3 | <head> |
| 4 | <title>ProFTPD module mod_tls_redis</title> |
| 5 | </head> |
| 6 | |
| 7 | <body bgcolor=white> |
| 8 | |
| 9 | <hr> |
| 10 | <center> |
| 11 | <h2><b>ProFTPD module <code>mod_tls_redis</code></b></h2> |
| 12 | </center> |
| 13 | <hr> |
| 14 | |
| 15 | <p> |
| 16 | The <code>mod_tls_redis</code> submodule is contained in the |
| 17 | <code>mod_tls_redis.c</code> file, and is not compiled by default. |
| 18 | Installation instructions are discussed <a href="#Installation">here</a>. |
| 19 | |
| 20 | <p> |
| 21 | This submodule a Redis-based implementation of an external SSL session |
| 22 | cache for use by the <code>mod_tls</code> module's |
| 23 | <a href="mod_tls.html#TLSSessionCache"><code>TLSSessionCache</code></a> |
| 24 | directive. The module also implements a Redis-based implementation of an |
| 25 | external OCSP response cache for the |
| 26 | <a href="mod_tls.html#TLSStaplingCache"><code>TLSStaplingCache</code></a> |
| 27 | directive. |
| 28 | |
| 29 | <p> |
| 30 | This product includes software developed by the OpenSSL Project for use in the OpenSSL Toolkit (http://www.openssl.org/). |
| 31 | |
| 32 | <p> |
| 33 | This product includes cryptographic software written by Eric Young ([email protected]). |
| 34 | |
| 35 | <h2>Author</h2> |
| 36 | <p> |
| 37 | Please contact TJ Saunders <tj <i>at</i> castaglia.org> with any |
| 38 | questions, concerns, or suggestions regarding this module. |
| 39 | |
| 40 | <p> |
| 41 | The <code>mod_tls_redis</code> module supports the "redis" |
| 42 | string for the <em>type</em> parameter of the |
| 43 | <a href="mod_tls.html#TLSSessionCache"><code>TLSSessionCache</code></a> |
| 44 | configuration directive. The <em>info</em> parameter for |
| 45 | <code>mod_tls_redis</code> can be empty/blank, indicating JSON encoding of |
| 46 | the cached data. This means that the |
| 47 | <code>TLSSessionCache</code> setting would look like: |
| 48 | <pre> |
| 49 | # Use JSON encoding for caching data using Redis |
| 50 | TLSSessionCache redis: |
| 51 | </pre> |
| 52 | If Redis support has not been enabled in your ProFTPD, this configuration |
| 53 | <b>cannot</b> be used. |
| 54 | |
| 55 | <p> |
| 56 | The <code>mod_tls_redis</code> module also supports the "redis" |
| 57 | string for the <em>type</em> parameter of the |
| 58 | <a href="mod_tls.html#TLSStaplingCache"><code>TLStaplingCache</code></a> |
| 59 | configuration directive, <i>e.g.</i>: |
| 60 | <pre> |
| 61 | TLSStaplingCache redis: |
| 62 | </pre> |
| 63 | |
| 64 | <p> |
| 65 | <b>Examples</b><br> |
| 66 | |
| 67 | <p> |
| 68 | <pre> |
| 69 | <IfModule mod_redis.c> |
| 70 | RedisEngine on |
| 71 | RedisServer <i>redis-server</i> |
| 72 | </IfModule> |
| 73 | |
| 74 | <IfModule mod_tls.c> |
| 75 | ... |
| 76 | |
| 77 | <IfModule mod_tls_redis.c> |
| 78 | TLSSessionCache redis: |
| 79 | TLSStaplingCache redis: |
| 80 | </IfModule> |
| 81 | </IfModule> |
| 82 | </pre> |
| 83 | |
| 84 | <p> |
| 85 | <b>Logging</b><br> |
| 86 | The <code>mod_tls_redis</code> module supports <a href="../howto/Tracing.html">trace logging</a>, via the module-specific log channels: |
| 87 | <ul> |
| 88 | <li>tls.redis |
| 89 | </ul> |
| 90 | Thus for trace logging, to aid in debugging, you would use the following in |
| 91 | your <code>proftpd.conf</code>: |
| 92 | <pre> |
| 93 | TraceLog /path/to/ftpd/trace.log |
| 94 | Trace tls.redis:20 |
| 95 | </pre> |
| 96 | This trace logging can generate large files; it is intended for debugging use |
| 97 | only, and should be removed from any production configuration. |
| 98 | |
| 99 | <p> |
| 100 | <hr> |
| 101 | <h2><a name="Installation">Installation</a></h2> |
| 102 | The <code>mod_tls_redis</code> module is distributed with the ProFTPD |
| 103 | source code. Simply follow the normal steps for using third-party modules |
| 104 | in ProFTPD, being sure to include the <code>mod_tls</code> module (on which |
| 105 | <code>mod_tls_redis</code> depends), <b>and</b> enabling redis support: |
| 106 | <pre> |
| 107 | $ ./configure --enable-redis --with-modules=mod_tls:mod_tls_redis |
| 108 | $ make |
| 109 | $ make install |
| 110 | </pre> |
| 111 | |
| 112 | <p> |
| 113 | Alternatively, if your <code>proftpd</code> was compiled with DSO support, you |
| 114 | can use the <code>prxs</code> tool to build <code>mod_tls_redis</code> as |
| 115 | a shared module: |
| 116 | <pre> |
| 117 | $ prxs -c -i -d mod_tls_redis.c |
| 118 | </pre> |
| 119 | |
| 120 | <p> |
| 121 | <hr> |
| 122 | <font size=2><b><i> |
| 123 | © Copyright 2017 TJ Saunders<br> |
| 124 | All Rights Reserved<br> |
| 125 | </i></b></font> |
| 126 | <hr> |
| 127 | |
| 128 | </body> |
| 129 | </html> |