Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Change default TLS named groups #1875

Merged
merged 7 commits into from
Apr 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
6 changes: 6 additions & 0 deletions changelog.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,12 @@ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.0.0/),
### Fixed
- [Fix connection getting closed by stale eviction task after it has been closed by the server](https://github.com/ballerina-platform/ballerina-library/issues/6050)

## Unreleased

### Added

- [Supporting X25519Kyber768 key encapsulation for TLS 1.3](https://github.com/ballerina-platform/ballerina-library/issues/6200)

## [2.10.6] - 2024-02-01

### Added
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -205,6 +205,9 @@ public class HttpUtil {
private static final String IO_EXCEPTION_OCCURRED = "I/O exception occurred";
private static final String CHUNKING_CONFIG = "chunking_config";
private static final String ILLEGAL_FUNCTION_INVOKED = "illegal respond: response has already been sent";
private static final String JAVA_CONFIG_TLS_NAMED_GROUPS = "jdk.tls.namedGroups";
private static final String[] DEFAULT_NAMED_GROUPS = { "X25519Kyber768Draft00", "x25519", "secp256r1",
"secp384r1", "secp521r1" };

/**
* Set new entity to in/out request/response struct.
Expand Down Expand Up @@ -1845,6 +1848,9 @@ private static void evaluateProtocolField(BMap<BString, Object> protocol,
if (!sslProtocol.isBlank()) {
sslConfiguration.setSSLProtocol(sslProtocol);
}
if (System.getProperty(JAVA_CONFIG_TLS_NAMED_GROUPS) == null) {
System.setProperty(JAVA_CONFIG_TLS_NAMED_GROUPS, String.join(",", DEFAULT_NAMED_GROUPS));
}
}

private static void evaluateCertValidationField(BMap<BString, Object> certValidation,
Expand Down
Loading