在嵌入式Jetty上启用TLS

编程入门 行业动态 更新时间:2024-10-11 07:26:42
本文介绍了在嵌入式Jetty上启用TLS-1.2的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧! 问题描述

目前,我正在使用启用TLS 1.2的代码:

Currently I am using this code which is enabling TLS 1.2:

ServerConnector httpsConnector = new ServerConnector(server, new SslConnectionFactory(sslContextFactory, "http/1.1"), new HttpConnectionFactory(https_config)); httpsConnector.setPort(8443); httpsConnector.setIdleTimeout(50000)

现在我正在使用TLS 1.1并想要更改它TLS 1.2。

Now I am using TLS 1.1 and want to change it to TLS 1.2.

推荐答案

Java 8默认为TLS / 1.2。

Java 8 is TLS/1.2 by default.

  • blogs.oracle/java- platform-group / entry / java_8_will_use_tls
  • blogs.oracle/java-platform-group/entry/java_8_will_use_tls

您可以使用以下技术在JVM中诊断TLS:

You can diagnose TLS in the JVM using the techniques at:

  • blogs.oracle/java-platform-group/entry/diagnosing_tls_ssl_and_https
  • blogs.oracle/java-platform-group/entry/diagnosing_tls_ssl_and_https

如果要强制TLS / 1.2,请参见以下先前的答案:

If you want to force TLS/1.2, see the prior answer at:

如何强制Java服务器仅接受tls 1.2并拒绝tls 1.0和tls 1.1连接

知道您公开的密码和协议在Jetty的SslContextFactory中也会对您的TLS支持级别产生影响。 (例如:您可以排除TLS / 1.0知道的不保留任何密码进行协商的密码)

Know that the ciphers and protocols you expose in Jetty's SslContextFactory will also have an influence on your TLS support level. (For example: you can exclude the ciphers that TLS/1.0 knows about leaving no ciphers to negotiate against)

更多推荐

在嵌入式Jetty上启用TLS

本文发布于:2023-11-05 03:08:14,感谢您对本站的认可!
本文链接:https://www.elefans.com/category/jswz/34/1559741.html
版权声明:本站内容均来自互联网,仅供演示用,请勿用于商业和其他非法用途。如果侵犯了您的权益请与我们联系,我们将在24小时内删除。
本文标签:嵌入式   Jetty   TLS

发布评论

评论列表 (有 0 条评论)
草根站长

>www.elefans.com

编程频道|电子爱好者 - 技术资讯及电子产品介绍!