提交 c692ee05 编写于 作者: 麦壳饼's avatar 麦壳饼

修改端口不能监听127.0.0.1之外的IP的问题

上级 f224a708
...@@ -27,7 +27,7 @@ namespace IoTSharp ...@@ -27,7 +27,7 @@ namespace IoTSharp
{ {
var broker = setting; var broker = setting;
if (broker == null) broker = new MqttBrokerSetting(); if (broker == null) broker = new MqttBrokerSetting();
options.WithDefaultEndpointPort(broker.Port).WithDefaultEndpointBoundIPAddress(System.Net.IPAddress.Parse("127.0.0.1")).WithDefaultEndpoint(); options.WithDefaultEndpointPort(broker.Port).WithDefaultEndpoint();
if (broker.EnableTls) if (broker.EnableTls)
{ {
options.WithEncryptedEndpoint(); options.WithEncryptedEndpoint();
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册