From f2a141314d1198965871030153315d2c707832c0 Mon Sep 17 00:00:00 2001 From: Changhua Date: Thu, 13 Apr 2023 00:05:21 +0800 Subject: [PATCH] Add remark --- rpc/pb_types.h | 1 + rpc/pb_util.cpp | 3 +++ rpc/proto/wcf.proto | 11 ++++++----- spy/get_contacts.cpp | 1 + spy/load_calls.cpp | 4 ++-- spy/spy_types.h | 1 + 6 files changed, 14 insertions(+), 7 deletions(-) diff --git a/rpc/pb_types.h b/rpc/pb_types.h index a9a74ca..447f53a 100644 --- a/rpc/pb_types.h +++ b/rpc/pb_types.h @@ -12,6 +12,7 @@ typedef struct { int32_t gender; string wxid; string code; + string remark; string name; string country; string province; diff --git a/rpc/pb_util.cpp b/rpc/pb_util.cpp index 1c77945..c8aa23b 100644 --- a/rpc/pb_util.cpp +++ b/rpc/pb_util.cpp @@ -76,6 +76,9 @@ bool encode_contacts(pb_ostream_t *stream, const pb_field_t *field, void *const message.code.funcs.encode = &encode_string; message.code.arg = (void *)(*it).code.c_str(); + message.remark.funcs.encode = &encode_string; + message.remark.arg = (void *)(*it).remark.c_str(); + message.name.funcs.encode = &encode_string; message.name.arg = (void *)(*it).name.c_str(); diff --git a/rpc/proto/wcf.proto b/rpc/proto/wcf.proto index b2937c8..4d960a8 100644 --- a/rpc/proto/wcf.proto +++ b/rpc/proto/wcf.proto @@ -102,11 +102,12 @@ message RpcContact { string wxid = 1; // 微信 id string code = 2; // 微信号 - string name = 3; // 微信昵称 - string country = 4; // 国家 - string province = 5; // 省/州 - string city = 6; // 城市 - int32 gender = 7; // 性别 + string remark = 3; // 备注 + string name = 4; // 微信昵称 + string country = 5; // 国家 + string province = 6; // 省/州 + string city = 7; // 城市 + int32 gender = 8; // 性别 } message RpcContacts { repeated RpcContact contacts = 1; } diff --git a/spy/get_contacts.cpp b/spy/get_contacts.cpp index 05fcb2c..0fbd5ce 100644 --- a/spy/get_contacts.cpp +++ b/spy/get_contacts.cpp @@ -19,6 +19,7 @@ vector GetContacts() RpcContact_t cnt; cnt.wxid = GetStringByAddress(node + g_WxCalls.contact.wxId); cnt.code = GetStringByAddress(node + g_WxCalls.contact.wxCode); + cnt.remark = GetStringByAddress(node + g_WxCalls.contact.wxRemark); cnt.name = GetStringByAddress(node + g_WxCalls.contact.wxName); cnt.country = GetStringByAddress(node + g_WxCalls.contact.wxCountry); cnt.province = GetStringByAddress(node + g_WxCalls.contact.wxProvince); diff --git a/spy/load_calls.cpp b/spy/load_calls.cpp index 0d14a3c..6119de0 100644 --- a/spy/load_calls.cpp +++ b/spy/load_calls.cpp @@ -16,8 +16,8 @@ WxCalls_t wxCalls = { { 0xB8A70, 0x3ED5E0, 0x107F00, 0x3ED7B0, 0x2386FE4 }, // Send xml Message { 0x771980, 0x4777E0, 0x239E888 }, // Send Emotion Message /* Get Contacts: - Base, head, wxId, Code, Name, Gender, Country, Province, City*/ - { 0x23668F4, 0x4C, 0x30, 0x44, 0x8C, 0x184, 0x1D0, 0x1E4, 0x1F8 }, + Base, head, wxId, Code, Remark,Name, Gender, Country, Province, City*/ + { 0x23668F4, 0x4C, 0x30, 0x44, 0x78, 0x8C, 0x184, 0x1D0, 0x1E4, 0x1F8 }, /* Exec Sql: Exec, base, start, end, slot, name*/ { 0x141BDF0, 0x2366934, 0x1428, 0x142C, 0x3C, 0x50 }, diff --git a/spy/spy_types.h b/spy/spy_types.h index 019b678..c1d0654 100644 --- a/spy/spy_types.h +++ b/spy/spy_types.h @@ -34,6 +34,7 @@ typedef struct Contact { DWORD head; DWORD wxId; DWORD wxCode; + DWORD wxRemark; DWORD wxName; DWORD wxGender; DWORD wxCountry;