hxb
2022-02-17 699eb9ec4f272e02c06769ec8794b5608cb15627
HDLSDK/hdl-connect/src/main/java/com/hdl/sdk/connect/protocol/LinkMessageDecoder.java
@@ -165,11 +165,13 @@
                        body = bodyBytes;
                    } else {
                        try {
                            LogUtils.e("解密失败,数据内容是:\r\n");
                            if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O)
                                LogUtils.e(Base64.getEncoder().encodeToString(body));
                            else {
                                LogUtils.e(new String(body, "utf-8"));
                            //之前的版本这块是明文的
                            if (!topic.contains("heartbeat_reply")) {
                                if (Build.VERSION.SDK_INT >= Build.VERSION_CODES.O)
                                    LogUtils.e("解密失败,数据内容是:\r\n" + Base64.getEncoder().encodeToString(body));
                                else {
                                    LogUtils.e("解密失败,数据内容是:\r\n" + new String(body, "utf-8"));
                                }
                            }
                        } catch (Exception e) {
                        }