title: How to disable SSLv3 fallback with okhttp
body: <p>My android application relies on SNI to access the correct server, so it requires TLS and won't work with SSLv3. I'm using okhttp and retrofit and server logs indicate that suddenly TLS handshakes switch to SSLv3 and may stay this way for a log time, resulting in repeated hostname verification failures due to the lack of server name indication support.</p>
  
  <p>I understand that in some situations (which ones ?) okhttp stops using TLS and switch to SSL as a fallback. However, this is unacceptable in case of SNI, is there a way to disable the fallback ?</p>
  
  <p>Example apache log:</p>
  
  <pre><code>[Wed May 07 18:00:12.799511 2014] [ssl:debug] [pid 20369:tid 140532403599104] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51431] AH02041: Protocol: TLSv1, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:00:28.563170 2014] [ssl:debug] [pid 20455:tid 140532646553344] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51432] AH02041: Protocol: TLSv1, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:00:45.884075 2014] [ssl:debug] [pid 20371:tid 140532445562624] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51433] AH02041: Protocol: TLSv1, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:01:01.322657 2014] [ssl:debug] [pid 20455:tid 140532395206400] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51434] AH02041: Protocol: TLSv1, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:01:18.361705 2014] [ssl:debug] [pid 20370:tid 140532462348032] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51435] AH02041: Protocol: TLSv1, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:01:25.378294 2014] [ssl:debug] [pid 20371:tid 140532487526144] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51436] AH02041: Protocol: SSLv3, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:01:40.807100 2014] [ssl:debug] [pid 20369:tid 140532445562624] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51437] AH02041: Protocol: SSLv3, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:01:41.154782 2014] [ssl:debug] [pid 20371:tid 140532479133440] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51438] AH02041: Protocol: SSLv3, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:01:56.695645 2014] [ssl:debug] [pid 20369:tid 140532504311552] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51439] AH02041: Protocol: SSLv3, Cipher: RC4-SHA (128/128 bits)
  [Wed May 07 18:01:57.252515 2014] [ssl:debug] [pid 20455:tid 140532521096960] ssl_engine_kernel.c(1891): [client &lt;removed&gt;:51440] AH02041: Protocol: SSLv3, Cipher: RC4-SHA (128/128 bits)
  </code></pre>