summaryrefslogtreecommitdiff
path: root/protocols/WhatsAppWeb/src/utils.h
diff options
context:
space:
mode:
authorGeorge Hazan <ghazan@miranda.im>2022-10-05 21:52:15 +0300
committerGeorge Hazan <ghazan@miranda.im>2022-10-05 21:52:15 +0300
commit92735a345ee6837a6c6b5941fd0d7cda7b7a8c2b (patch)
tree76ddc6cb543ced575b778169723ceac8ac66021d /protocols/WhatsAppWeb/src/utils.h
parenteec4dbe75110ce06a44998ddaaa625d7e4378543 (diff)
WhatsApp:
- all signal storage data extracted to the separate class MSignalStore; - MSignalSession added to handle session ciphers - signal store callbacks registered - all libsignal related code moved to signal.cpp
Diffstat (limited to 'protocols/WhatsAppWeb/src/utils.h')
-rw-r--r--protocols/WhatsAppWeb/src/utils.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/protocols/WhatsAppWeb/src/utils.h b/protocols/WhatsAppWeb/src/utils.h
index d3adfb3dc7..5428eb8188 100644
--- a/protocols/WhatsAppWeb/src/utils.h
+++ b/protocols/WhatsAppWeb/src/utils.h
@@ -169,6 +169,10 @@ struct WAJid
std::string encodeBigEndian(uint32_t num, size_t len = sizeof(uint32_t));
void generateIV(uint8_t *iv, int &pVar);
+__forceinline bool operator<<(MessageLite &msg, const MBinBuffer &buf)
+{ return msg.ParseFromArray(buf.data(), (int)buf.length());
+}
+
unsigned char* HKDF(const EVP_MD *evp_md,
const unsigned char *salt, size_t salt_len,
const unsigned char *key, size_t key_len,