emqx / mqtt-jmeter

MQTT JMeter Plugin
https://www.emqx.com/en
Apache License 2.0
447 stars 193 forks source link

如何关闭ssl校验,或者忽略ssl证书错误 #146

Open yujinguo0930 opened 11 months ago

yujinguo0930 commented 11 months ago

使用mqttx的时候,有个配置,ssl 安全,关闭后可以忽略证书错误,请问在jmeter插件中可以配置吗,或者类似ws的Ignore SSL certificate errors 已经确定证书中CN有问题,会导致无法校验通过,从而无法建连

错误如下: Caused by: com.hivemq.client.mqtt.exceptions.ConnectionFailedException: javax.net.ssl.SSLHandshakeException: java.security.cert.CertificateException: No name matching xxx.com found Caused by: javax.net.ssl.SSLHandshakeException: java.security.cert.CertificateException: No name matching xxx.com found image

chongyuanyin commented 11 months ago

please try without checking 'Dual SSL authentication'

yujinguo0930 commented 11 months ago

please try without checking 'Dual SSL authentication'

Thank you for answering,but if i remove this check box and the connection will report an error。Another question, if I turn this off, how can I bring the certificate to the server

image

chongyuanyin commented 9 months ago

The plugin actually trusts all certificates (for performance purpose) from server side. If 'Dual SSL authentication' is not checked, the plugin will not send the certificate to the server. So if the broker side requires a certificate from client, it fails.