Skip to content

Commit

Permalink
Add null check to namedGroups property
Browse files Browse the repository at this point in the history
  • Loading branch information
SupremeMortal committed Dec 5, 2019
1 parent 3b839ae commit 2b18ee6
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ public class EncryptionUtils {
// DO NOT REMOVE THIS
// Since Java 8u231, secp384r1 is deprecated and will throw an exception.
String namedGroups = System.getProperty("jdk.tls.namedGroups");
System.setProperty("jdk.tls.namedGroups", namedGroups.isEmpty() ? "secp384r1" : ", secp384r1");
System.setProperty("jdk.tls.namedGroups", namedGroups == null || namedGroups.isEmpty() ? "secp384r1" : ", secp384r1");

try {
KEY_PAIR_GEN = KeyPairGenerator.getInstance("EC");
Expand Down

0 comments on commit 2b18ee6

Please sign in to comment.