From 407fae6f07a2a982a2a814c2f145c40733c966cb Mon Sep 17 00:00:00 2001 From: JLChen <551775569@qq.com> Date: 星期三, 12 一月 2022 15:29:34 +0800 Subject: [PATCH] 2022-01-12 1.更新 --- Crabtree/SmartHome/UI/SimpleControl/MqttCommon.cs | 13 +++++++++---- 1 files changed, 9 insertions(+), 4 deletions(-) diff --git a/Crabtree/SmartHome/UI/SimpleControl/MqttCommon.cs b/Crabtree/SmartHome/UI/SimpleControl/MqttCommon.cs index c8f0475..59f4969 100644 --- a/Crabtree/SmartHome/UI/SimpleControl/MqttCommon.cs +++ b/Crabtree/SmartHome/UI/SimpleControl/MqttCommon.cs @@ -766,6 +766,10 @@ /// </summary> static void SendPushSignOut () { +#if DEBUG + return; +#endif + byte [] message = CommonPage.MyEncodingUTF8.GetBytes (PushSignStr); MqttRemoteSend (message, 4); } @@ -786,6 +790,7 @@ case 0: topicName = $"/ClientToBusGateWay/{CommonConfig.Current.HomeGatewayInfo.gatewayId}/Common/ON"; if (!string.IsNullOrEmpty (mqttEncryptKey)) { + //Utlis.WriteLine ("mqttEncryptKey锛�" + mqttEncryptKey); message = Shared.Securitys.EncryptionService.AesEncryptPayload (message, mqttEncryptKey); } await RemoteMqttClient.PublishAsync (new MqttApplicationMessage { Topic = topicName, Payload = message, Retain = false, QualityOfServiceLevel = MQTTnet.Protocol.MqttQualityOfServiceLevel.AtMostOnce }); @@ -944,7 +949,7 @@ public partial class EncryptionService { - #region 鍔犲瘑 +#region 鍔犲瘑 /// <summary> /// 鍔犲瘑涓婚涓築ase64 /// </summary> @@ -999,10 +1004,10 @@ //浣跨敤AES灏嗘槑鏂囨祦杞垚瀵嗘枃瀛楄妭鏁扮粍 return cTransform.TransformFinalBlock (toEncryptArray, 0, toEncryptArray.Length); } - #endregion +#endregion - #region 瑙e瘑 +#region 瑙e瘑 /// <summary> /// 瑙e瘑涓婚鏁版嵁 /// </summary> @@ -1054,7 +1059,7 @@ //浣跨敤AES灏嗗瘑鏂囨祦杞垚鏄庢枃鐨勫瓧鑺傛暟缁� return cTransform.TransformFinalBlock (toEncryptArray, 0, toEncryptArray.Length); } - #endregion +#endregion -- Gitblit v1.8.0