Skip to content

Commit

Permalink
SSLAwareMongoClient: Use the TLSv1.2 as default for SSL Context
Browse files Browse the repository at this point in the history
Signed-off-by: Andrea Cosentino <ancosen@gmail.com>
  • Loading branch information
oscerd committed Nov 14, 2023
1 parent 88bd7e9 commit 5bea94c
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ public MongoClient get() {
builder.invalidHostNameAllowed(true);
SSLContext sc = null;
try {
sc = SSLContext.getInstance("SSL");
sc = SSLContext.getInstance("TLSv1.2");
} catch (NoSuchAlgorithmException e) {
throw new RuntimeException("Error instantiating trust all SSL context.", e);
}
Expand Down

0 comments on commit 5bea94c

Please sign in to comment.