|
@@ -48,7 +48,7 @@ func DecodeMessage(src []byte) ([]byte, error) {
|
48
|
48
|
return nil, e1
|
49
|
49
|
}
|
50
|
50
|
|
51
|
|
- bt2, e2 := encrypt.MsgDecode(bt1, aesKey)
|
|
51
|
+ bt2, e2 := encrypt.AESDecode(bt1, aesKey)
|
52
|
52
|
if e2 != nil {
|
53
|
53
|
log.Error("解码加密数据失败: ", e2.Error())
|
54
|
54
|
log.Error("待解密数据: ", string(bt1))
|
|
@@ -79,7 +79,7 @@ func EncodeMessage(appID string, src []byte) ([]byte, error) {
|
79
|
79
|
data = append(data, src...)
|
80
|
80
|
data = append(data, []byte(appID)...)
|
81
|
81
|
|
82
|
|
- bt1, e1 := encrypt.MsgEncode(data, aesKey)
|
|
82
|
+ bt1, e1 := encrypt.AESEncode(data, aesKey)
|
83
|
83
|
if e1 != nil {
|
84
|
84
|
log.Error("加密数据失败: ", e1.Error())
|
85
|
85
|
log.Error("待加密数据: ", string(bt1))
|