欢迎光临散文网 会员登陆 & 注册

服务器跟客户端MQTT-TLS/SSL通讯成功。

2023-03-23 11:10 作者:努力学习天天赚钱123456  | 我要投稿

一、基础知识:

1.This method requires an instance of the possible implementations of the KeyCertOptions interface and in this case the PemKeyCertOptions class is 

  used in order to provide the path for the server certificate 

  and the private key with the correspondent certPath and keyPath methods. 

  看国内网站介绍多了把证书叫成公钥。英文是叫server certificate.

2.openssl生成pem数字证书 

  openssl req -x509 -newkey rsa:4096 -sha256 -nodes -keyout privkey.pem -out cacert.pem -days 3650

二、代码



三、参考连接:

1.vertx serivce https://vertx.tk/docs/vertx-mqtt/js/#:~:text=In%20order%20to%20do%20that%2C%20the%20MqttServerOptions%20class,Java%20key%20store%20reference%2C%20PEM%20or%20PFX%20format%29.

2.生成pem数字证书。https://blog.csdn.net/who7708/article/details/104565369

3.vertx ssl说明。https://vertx-china.github.io/docs/vertx-mqtt/java/#_vert_x_mqtt_client


服务器跟客户端MQTT-TLS/SSL通讯成功。的评论 (共 条)

分享到微博请遵守国家法律