kikocis/java-driver public
Changesets · Branches · Tags · Compare
| Changeset | 53db560e9d5adc4ce626c712d384b8929b72fd6d3a905f5a0331c8b2aa00ede9 |
|---|---|
| Author | olim7t <omichallat+github@gmail.com> · 2015-11-02 22:04 +01:00 |
| Committer | olim7t <omichallat+github@gmail.com> · 2015-11-05 18:54 +01:00 |
| Parents | 3168d4757d5a |
1 file changed
modified driver-core/src/main/java/com/datastax/driver/core/SSLOptions.java +1 −7
| @@ -24,8 +24,6 @@ | ||
| 24 | 24 | */ |
| 25 | 25 | public class SSLOptions { |
| 26 | 26 | |
| 27 | - private static final String SSL_PROTOCOL = "TLS"; | |
| 28 | - | |
| 29 | 27 | /** |
| 30 | 28 | * The default SSL cipher suites. |
| 31 | 29 | */ |
| @@ -63,12 +61,8 @@ | ||
| 63 | 61 | |
| 64 | 62 | private static SSLContext makeDefaultContext() throws IllegalStateException { |
| 65 | 63 | try { |
| 66 | - SSLContext ctx = SSLContext.getInstance(SSL_PROTOCOL); | |
| 67 | - ctx.init(null, null, null); // use defaults | |
| 68 | - return ctx; | |
| 64 | + return SSLContext.getDefault(); | |
| 69 | 65 | } catch (NoSuchAlgorithmException e) { |
| 70 | - throw new RuntimeException("This JVM doesn't support TLS, this shouldn't happen"); | |
| 71 | - } catch (KeyManagementException e) { | |
| 72 | 66 | throw new IllegalStateException("Cannot initialize SSL Context", e); |
| 73 | 67 | } |
| 74 | 68 | } |