Skip to content

Commit

Permalink
Merge branch 'release/3.3.0'
Browse files Browse the repository at this point in the history
  • Loading branch information
jfallows committed Jun 13, 2024
2 parents f68593e + 149cc94 commit 95f574c
Show file tree
Hide file tree
Showing 16 changed files with 74 additions and 11 deletions.
13 changes: 13 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
# Changelog

## [3.2.0](https://github.com/aklivity/k3po/tree/3.2.0) (2024-06-10)

[Full Changelog](https://github.com/aklivity/k3po/compare/284507aec12987508378f7fb470ccc88754e17f1...3.2.0)

**Merged pull requests:**

- Initial tidy [\#4](https://github.com/aklivity/k3po/pull/4) ([jfallows](https://github.com/jfallows))



\* *This Changelog was automatically generated by [github_changelog_generator](https://github.com/github-changelog-generator/github-changelog-generator)*
6 changes: 3 additions & 3 deletions pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
<modelVersion>4.0.0</modelVersion>
<groupId>io.aklivity.k3po</groupId>
<artifactId>k3po</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<packaging>pom</packaging>
<name>k3po</name>
<url>https://github.com/aklivity/k3po</url>
Expand Down Expand Up @@ -115,12 +115,12 @@
<dependency>
<groupId>com.fasterxml.jackson.core</groupId>
<artifactId>jackson-databind</artifactId>
<version>2.9.10.6</version>
<version>2.12.7.1</version>
</dependency>
<dependency>
<groupId>org.apache.maven</groupId>
<artifactId>maven-compat</artifactId>
<version>3.5.0</version>
<version>3.8.1</version>
<scope>provided</scope>
</dependency>
<dependency>
Expand Down
2 changes: 1 addition & 1 deletion runtime/control-junit/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>runtime</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion runtime/control/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>runtime</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion runtime/driver/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>runtime</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -36,6 +36,7 @@ public final class TlsTypeSystem implements TypeSystemSpi
public static final TypeInfo<String> OPTION_APPLICATION_PROTOCOLS = new TypeInfo<>("applicationProtocols", String.class);
public static final TypeInfo<Boolean> OPTION_NEED_CLIENT_AUTH = new TypeInfo<>("needClientAuth", Boolean.class);
public static final TypeInfo<Boolean> OPTION_WANT_CLIENT_AUTH = new TypeInfo<>("wantClientAuth", Boolean.class);
public static final TypeInfo<String> OPTION_CIPHER_SUITES = new TypeInfo<>("cipherSuites", String.class);

private final Set<TypeInfo<?>> acceptOptions;
private final Set<TypeInfo<?>> connectOptions;
Expand All @@ -57,6 +58,7 @@ public TlsTypeSystem()
acceptOptions.add(OPTION_APPLICATION_PROTOCOLS);
acceptOptions.add(OPTION_NEED_CLIENT_AUTH);
acceptOptions.add(OPTION_WANT_CLIENT_AUTH);
acceptOptions.add(OPTION_CIPHER_SUITES);
this.acceptOptions = unmodifiableSet(acceptOptions);

Set<TypeInfo<?>> connectOptions = new LinkedHashSet<>();
Expand All @@ -66,6 +68,7 @@ public TlsTypeSystem()
connectOptions.add(OPTION_TRUST_STORE_FILE);
connectOptions.add(OPTION_TRUST_STORE_PASSWORD);
connectOptions.add(OPTION_APPLICATION_PROTOCOLS);
connectOptions.add(OPTION_CIPHER_SUITES);
this.connectOptions = unmodifiableSet(connectOptions);

this.readOptions = emptySet();
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,7 @@ public class DefaultTlsChannelConfig extends DefaultChannelConfig implements Tls
private File trustStoreFile;
private char[] trustStorePassword;
private String[] applicationProtocols;
private String[] cipherSuites;

@Override
public void setParameters(SSLParameters parameters) {
Expand Down Expand Up @@ -105,6 +106,19 @@ public void setApplicationProtocols(
this.applicationProtocols = applicationProtocol;
}

@Override
public String[] getCipherSuites()
{
return cipherSuites;
}

@Override
public void setCipherSuites(
String[] cipherSuites)
{
this.cipherSuites = cipherSuites;
}

@Override
protected boolean setOption0(
String key,
Expand All @@ -130,6 +144,10 @@ else if ("applicationProtocols".equals(key))
{
applicationProtocols = ((String) value).split(",");
}
else if ("cipherSuites".equals(key))
{
cipherSuites = ((String) value).split(",");
}
else
{
return false;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,7 @@ public class DefaultTlsServerChannelConfig extends DefaultServerChannelConfig im
private String[] applicationProtocols;
private boolean needClientAuth;
private boolean wantClientAuth;
private String[] cipherSuites;

@Override
public void setParameters(SSLParameters parameters) {
Expand Down Expand Up @@ -107,6 +108,19 @@ public void setApplicationProtocols(
this.applicationProtocols = applicationProtocol;
}

@Override
public String[] getCipherSuites()
{
return cipherSuites;
}

@Override
public void setCipherSuites(
String[] cipherSuites)
{
this.cipherSuites = cipherSuites;
}

@Override
protected boolean setOption0(
String key,
Expand Down Expand Up @@ -134,6 +148,9 @@ protected boolean setOption0(
case "wantClientAuth":
wantClientAuth = Boolean.valueOf((String) value);
break;
case "cipherSuites":
cipherSuites = ((String) value).split(",");
break;
default:
return false;
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -46,4 +46,8 @@ public interface TlsChannelConfig extends ChannelConfig {
void setApplicationProtocols(String[] applicationProtocol);

String[] getApplicationProtocols();

void setCipherSuites(String[] cipherSuites);

String[] getCipherSuites();
}
Original file line number Diff line number Diff line change
Expand Up @@ -132,6 +132,7 @@ protected void connectRequested(ChannelPipeline pipeline, ChannelStateEvent evt)
char[] keyStorePassword = tlsConnectConfig.getKeyStorePassword();
char[] trustStorePassword = tlsConnectConfig.getTrustStorePassword();
String[] applicationProtocols = tlsConnectConfig.getApplicationProtocols();
String[] cipherSuites = tlsConnectConfig.getCipherSuites();

ChannelPipelineFactory pipelineFactory = new ChannelPipelineFactory() {
@Override
Expand Down Expand Up @@ -174,6 +175,9 @@ public ChannelPipeline getPipeline() throws Exception {
if (applicationProtocols != null && applicationProtocols.length > 0) {
setApplicationProtocols(tlsParameters, applicationProtocols);
}
if (cipherSuites != null && cipherSuites.length > 0) {
tlsParameters.setCipherSuites(cipherSuites);
}
tlsEngine.setSSLParameters(tlsParameters);

SslHandler sslHandler = new SslHandler(tlsEngine);
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -101,6 +101,7 @@ protected void bindRequested(ChannelPipeline pipeline, ChannelStateEvent evt) th
String[] applicationProtocols = tlsConnectConfig.getApplicationProtocols();
boolean wantClientAuth = tlsConnectConfig.getWantClientAuth();
boolean needClientAuth = tlsConnectConfig.getNeedClientAuth();
String[] cipherSuites = tlsConnectConfig.getCipherSuites();

ChannelPipelineFactory pipelineFactory = new ChannelPipelineFactory() {
@Override
Expand Down Expand Up @@ -148,6 +149,9 @@ public ChannelPipeline getPipeline() throws Exception {
if (applicationProtocols != null && applicationProtocols.length > 0) {
setApplicationProtocols(tlsParameters, applicationProtocols);
}
if (cipherSuites != null && cipherSuites.length > 0) {
tlsParameters.setCipherSuites(cipherSuites);
}
tlsEngine.setSSLParameters(tlsParameters);

SslHandler sslHandler = new SslHandler(tlsEngine);
Expand Down
2 changes: 1 addition & 1 deletion runtime/k3po-maven-plugin/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>runtime</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion runtime/lang/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>runtime</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion runtime/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>k3po</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion specs/control.spec/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>specs</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down
2 changes: 1 addition & 1 deletion specs/pom.xml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<parent>
<groupId>io.aklivity.k3po</groupId>
<artifactId>k3po</artifactId>
<version>3.2.0</version>
<version>3.3.0</version>
<relativePath>../pom.xml</relativePath>
</parent>

Expand Down

0 comments on commit 95f574c

Please sign in to comment.