心跳指令不加密:若是心跳指令加密,非法设备不能正确退网

This commit is contained in:
cdyong 2015-12-09 10:30:17 +00:00
parent 1b89816997
commit aa16992982
1 changed files with 1 additions and 1 deletions

View File

@ -527,7 +527,7 @@ bool TinyController::Send(Message& msg)
static bool Encrypt(Message& msg, Array& pass)
{
// 加解密。组网不加密,退网不加密
if(msg.Length > 0 && pass.Length() > 0 && !(msg.Code == 0x01 || msg.Code == 0x02))
if(msg.Length > 0 && pass.Length() > 0 && !(msg.Code == 0x01 || msg.Code == 0x02||msg.Code==0x03))
{
Array bs(msg.Data, msg.Length);
RC4::Encrypt(bs, pass);