yifan-c commented on code in PR #188:
URL: https://github.com/apache/cassandra-sidecar/pull/188#discussion_r1945581607
##########
server/src/test/integration/org/apache/cassandra/testing/CassandraTestTemplate.java:
##########
@@ -382,13 +382,16 @@ private Path truststorePath(CertificateBundle ca, Path
path) throws Exception
return ca.toTempKeyStorePath(path, truststorePassword.toCharArray(),
truststorePassword.toCharArray());
}
- private Path serverKeystorePath(CertificateBundle ca, Path path) throws
Exception
+ private Path serverKeystorePath(CertificateBundle ca, Path path, int
totalNodes) throws Exception
{
- CertificateBundle keystore = new CertificateBuilder()
- .subject("CN=Apache Cassandra,
OU=ssl_test, O=Unknown, L=Unknown, ST=Unknown, C=Unknown")
- .addSanDnsName("localhost")
- .addSanIpAddress("127.0.0.1")
- .buildIssuedBy(ca);
+ CertificateBuilder builder = new CertificateBuilder();
+ builder.subject("CN=Apache Cassandra, OU=ssl_test, O=Unknown,
L=Unknown, ST=Unknown, C=Unknown")
+ .addSanDnsName("localhost");
+ for (int i = 1; i <= totalNodes; i++)
+ {
+ builder.addSanIpAddress("127.0.0." + i);
+ }
+ CertificateBundle keystore = builder.buildIssuedBy(ca);
Review Comment:
Allow contacting other hosts rather than 127.0.0.1 only.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]