Package io.netty.internal.tcnative
Interface KeyLogCallback
-
public interface KeyLogCallbackCallback hooked intoSSL_CTX_set_keylog_callback.It is supported by BoringSSL, AWS-LC and OpenSSL 1.1.1 or later, but not by LibreSSL.
Each line uses the NSS Key Log Format (the format of
SSLKEYLOGFILE). This is intended for TLS debugging with tools like Wireshark. For instance, a validSSLKEYLOGFILEimplementation could look like this:{@code final PrintStream out = new PrintStream("~/tls.sslkeylog_file"); SSLContext.setKeyLogCallback(ctxPtr, new KeyLogCallback() {
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method Description voidhandle(long ssl, byte[] line)Called when a new key log line is emitted.
-
-
-
Method Detail
-
handle
void handle(long ssl, byte[] line)Called when a new key log line is emitted.Warning: The log output will contain secret key material, and can be used to decrypt TLS sessions! The log output should be handled with the same care given to the private keys.
This method is expected to never throw any
Throwable: anything it throws is cleared and ignored.- Parameters:
ssl- the nativeSSL*pointer of the connection the line belongs to.line- a single line in the NSS Key Log Format, without a trailing newline.
-
-