8207237: SSLSocket#setEnabledCipherSuites is accepting empty string
Reviewed-by: xuelei
This commit is contained in:
parent
021a771791
commit
8158cca17d
@ -891,9 +891,10 @@ enum CipherSuite {
|
||||
|
||||
List<CipherSuite> cipherSuites = new ArrayList<>(names.length);
|
||||
for (String name : names) {
|
||||
if (name == null) {
|
||||
if (name == null || name.isEmpty()) {
|
||||
throw new IllegalArgumentException(
|
||||
"The specified CipherSuites array contain null element");
|
||||
"The specified CipherSuites array contains " +
|
||||
"invalid null or empty string elements");
|
||||
}
|
||||
|
||||
boolean found = false;
|
||||
|
Loading…
Reference in New Issue
Block a user