8282309: Operation before upper case conversion

Reviewed-by: valeriep, wetmore
This commit is contained in:
Xue-Lei Andrew Fan 2022-02-23 18:32:29 +00:00
parent a020b6ba8f
commit 7dc7184c10

@ -102,7 +102,7 @@ public class TlsChannelBinding {
final byte[] prefix =
TlsChannelBindingType.TLS_SERVER_END_POINT.getName().concat(":").getBytes();
String hashAlg = serverCertificate.getSigAlgName().
replace("SHA", "SHA-").toUpperCase(Locale.ENGLISH);
toUpperCase(Locale.ENGLISH).replace("SHA", "SHA-");
int ind = hashAlg.indexOf("WITH");
if (ind > 0) {
hashAlg = hashAlg.substring(0, ind);