vialeys 0.0.1 → 0.0.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +11 -5
- package/WAProto/AICommon/AICommon.js +13991 -9169
- package/WAProto/AICommon/AICommon.proto +110 -3
- package/WAProto/CompanionReg/CompanionReg.js +114 -0
- package/WAProto/CompanionReg/CompanionReg.proto +3 -0
- package/WAProto/DeviceCapabilities/DeviceCapabilities.js +652 -0
- package/WAProto/DeviceCapabilities/DeviceCapabilities.proto +19 -0
- package/WAProto/E2E/E2E.js +77193 -51248
- package/WAProto/E2E/E2E.proto +68 -12
- package/WAProto/HistorySync/HistorySync.js +3375 -178
- package/WAProto/HistorySync/HistorySync.proto +3 -3
- package/WAProto/LidMigrationSyncPayload/LidMigrationSyncPayload.js +98 -49
- package/WAProto/LidMigrationSyncPayload/LidMigrationSyncPayload.proto +2 -2
- package/WAProto/MdStorageMsgRowOpaqueData/MdStorageMsgRowOpaqueData.js +75226 -48422
- package/WAProto/MdStorageMsgRowOpaqueData/MdStorageMsgRowOpaqueData.proto +6 -0
- package/WAProto/StatusAttributions/StatusAttributions.js +21 -0
- package/WAProto/StatusAttributions/StatusAttributions.proto +3 -0
- package/WAProto/SyncAction/SyncAction.js +9423 -2023
- package/WAProto/SyncAction/SyncAction.proto +208 -15
- package/WAProto/Wa6/Wa6.js +83 -0
- package/WAProto/Wa6/Wa6.proto +3 -0
- package/WAProto/Web/Web.js +92664 -63403
- package/WAProto/Web/Web.proto +31 -13
- package/engine-requirements.js +9 -7
- package/lib/Defaults/baileys-version.json +2 -2
- package/lib/Defaults/connection.js +51 -0
- package/lib/Defaults/constants.js +62 -0
- package/lib/Defaults/history.js +17 -0
- package/lib/Defaults/index.js +36 -142
- package/lib/Defaults/media.js +48 -0
- package/lib/Defaults/prefix.js +18 -0
- package/lib/Signal/Group/group-session-builder.js +10 -42
- package/lib/Signal/Group/group_cipher.js +9 -6
- package/lib/Signal/Group/index.js +39 -53
- package/lib/Signal/Group/keyhelper.js +8 -41
- package/lib/Signal/Group/sender-chain-key.js +4 -4
- package/lib/Signal/Group/sender-key-distribution-message.js +5 -5
- package/lib/Signal/Group/sender-key-message.js +12 -8
- package/lib/Signal/Group/sender-key-state.js +4 -4
- package/lib/Signal/Group/sender-message-key.js +2 -2
- package/lib/Signal/libsignal.js +45 -69
- package/lib/Signal/lid-mapping.js +15 -11
- package/lib/Socket/Client/types.js +2 -2
- package/lib/Socket/Client/websocket.js +16 -14
- package/lib/Socket/business.js +41 -32
- package/lib/Socket/chats.js +123 -98
- package/lib/Socket/community.js +50 -40
- package/lib/Socket/groups.js +59 -47
- package/lib/Socket/index.js +4 -4
- package/lib/Socket/messages-recv.js +226 -171
- package/lib/Socket/messages-send.js +187 -143
- package/lib/Socket/newsletter.js +61 -47
- package/lib/Socket/socket.js +133 -90
- package/lib/Socket/usync.js +6 -6
- package/lib/Store/index.js +27 -11
- package/lib/Store/make-cache-manager-store.js +14 -15
- package/lib/Store/make-in-memory-store.js +28 -24
- package/lib/Types/LabelAssociation.js +2 -2
- package/lib/Types/Message.js +6 -6
- package/lib/Types/MexUpdates.js +5 -4
- package/lib/Types/State.js +4 -4
- package/lib/Types/index.js +28 -12
- package/lib/Utils/auth-utils.js +28 -26
- package/lib/Utils/baileys-event-stream.js +68 -69
- package/lib/Utils/business.js +63 -53
- package/lib/Utils/chat-utils.js +81 -71
- package/lib/Utils/crypto.js +25 -45
- package/lib/Utils/decode-wa-message.js +319 -311
- package/lib/Utils/event-buffer.js +21 -22
- package/lib/Utils/generics.js +103 -73
- package/lib/Utils/history.js +21 -21
- package/lib/Utils/index.js +27 -13
- package/lib/Utils/link-preview.js +7 -30
- package/lib/Utils/logger.js +5 -5
- package/lib/Utils/lt-hash.js +3 -3
- package/lib/Utils/message-retry-manager.js +4 -4
- package/lib/Utils/messages-media.js +104 -109
- package/lib/Utils/messages.js +203 -171
- package/lib/Utils/noise-handler.js +28 -19
- package/lib/Utils/process-message.js +370 -136
- package/lib/Utils/signal.js +36 -25
- package/lib/Utils/use-multi-file-auth-state.js +18 -22
- package/lib/Utils/validate-connection.js +52 -45
- package/lib/WABinary/decode.js +6 -32
- package/lib/WABinary/encode.js +3 -29
- package/lib/WABinary/generic-utils.js +4 -4
- package/lib/WABinary/index.js +27 -11
- package/lib/WAM/encode.js +16 -8
- package/lib/WAM/index.js +27 -11
- package/lib/WAUSync/Protocols/USyncBotProfileProtocol.js +20 -16
- package/lib/WAUSync/Protocols/USyncContactProtocol.js +2 -2
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.js +7 -4
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +2 -2
- package/lib/WAUSync/Protocols/USyncLIDProtocol.js +0 -2
- package/lib/WAUSync/Protocols/USyncStatusProtocol.js +2 -2
- package/lib/WAUSync/Protocols/index.js +27 -11
- package/lib/WAUSync/USyncQuery.js +17 -10
- package/lib/WAUSync/index.js +27 -11
- package/lib/index.js +62 -37
- package/package.json +1 -1
- package/WAProto/index.d.ts +0 -55
- package/lib/index.d.ts +0 -13
|
@@ -2,31 +2,46 @@
|
|
|
2
2
|
|
|
3
3
|
Object.defineProperty(exports, "__esModule", { value: true })
|
|
4
4
|
|
|
5
|
-
const
|
|
6
|
-
const
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
5
|
+
const { proto } = require("../../WAProto")
|
|
6
|
+
const { WAMessageStubType } = require("../Types")
|
|
7
|
+
const {
|
|
8
|
+
getDevice,
|
|
9
|
+
getContentType,
|
|
10
|
+
normalizeMessageContent
|
|
11
|
+
} = require("../Utils")
|
|
12
|
+
const {
|
|
13
|
+
areJidsSameUser,
|
|
14
|
+
isJidBroadcast,
|
|
15
|
+
isJidStatusBroadcast,
|
|
16
|
+
jidNormalizedUser
|
|
17
|
+
} = require("../WABinary")
|
|
18
|
+
const {
|
|
19
|
+
aesDecryptGCM,
|
|
20
|
+
hmacSign
|
|
21
|
+
} = require("./crypto")
|
|
22
|
+
const {
|
|
23
|
+
getKeyAuthor,
|
|
24
|
+
toNumber
|
|
25
|
+
} = require("./generics")
|
|
26
|
+
const { downloadAndProcessHistorySyncNotification } = require("./history")
|
|
12
27
|
|
|
13
28
|
const REAL_MSG_STUB_TYPES = new Set([
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
29
|
+
WAMessageStubType.CALL_MISSED_GROUP_VIDEO,
|
|
30
|
+
WAMessageStubType.CALL_MISSED_GROUP_VOICE,
|
|
31
|
+
WAMessageStubType.CALL_MISSED_VIDEO,
|
|
32
|
+
WAMessageStubType.CALL_MISSED_VOICE
|
|
18
33
|
])
|
|
19
34
|
|
|
20
35
|
const REAL_MSG_REQ_ME_STUB_TYPES = new Set([
|
|
21
|
-
|
|
36
|
+
WAMessageStubType.GROUP_PARTICIPANT_ADD
|
|
22
37
|
])
|
|
23
38
|
|
|
24
39
|
/** Cleans a received message to further processing */
|
|
25
40
|
const cleanMessage = (message, meId) => {
|
|
26
41
|
// ensure remoteJid and participant doesn't have device or agent in it
|
|
27
|
-
message.key.remoteJid =
|
|
28
|
-
message.key.participant = message.key.participant ?
|
|
29
|
-
const content =
|
|
42
|
+
message.key.remoteJid = jidNormalizedUser(message.key.remoteJid)
|
|
43
|
+
message.key.participant = message.key.participant ? jidNormalizedUser(message.key.participant) : undefined
|
|
44
|
+
const content = normalizeMessageContent(message.message)
|
|
30
45
|
// if the message has a reaction, ensure fromMe & remoteJid are from our perspective
|
|
31
46
|
if (content?.reactionMessage) {
|
|
32
47
|
normaliseKey(content.reactionMessage.key)
|
|
@@ -41,7 +56,7 @@ const cleanMessage = (message, meId) => {
|
|
|
41
56
|
// if the sender believed the message being reacted to is not from them
|
|
42
57
|
// we've to correct the key to be from them, or some other participant
|
|
43
58
|
msgKey.fromMe = !msgKey.fromMe
|
|
44
|
-
?
|
|
59
|
+
? areJidsSameUser(msgKey.participant || msgKey.remoteJid, meId)
|
|
45
60
|
// if the message being reacted to, was from them
|
|
46
61
|
// fromMe automatically becomes false
|
|
47
62
|
: false
|
|
@@ -54,14 +69,14 @@ const cleanMessage = (message, meId) => {
|
|
|
54
69
|
}
|
|
55
70
|
|
|
56
71
|
const isRealMessage = (message, meId) => {
|
|
57
|
-
const normalizedContent =
|
|
58
|
-
const hasSomeContent = !!
|
|
72
|
+
const normalizedContent = normalizeMessageContent(message.message)
|
|
73
|
+
const hasSomeContent = !!getContentType(normalizedContent)
|
|
59
74
|
return (
|
|
60
75
|
!!normalizedContent ||
|
|
61
76
|
REAL_MSG_STUB_TYPES.has(message.messageStubType) ||
|
|
62
77
|
(
|
|
63
78
|
REAL_MSG_REQ_ME_STUB_TYPES.has(message.messageStubType) &&
|
|
64
|
-
message.messageStubParameters?.some(p =>
|
|
79
|
+
message.messageStubParameters?.some(p => areJidsSameUser(meId, p))
|
|
65
80
|
)
|
|
66
81
|
) &&
|
|
67
82
|
hasSomeContent &&
|
|
@@ -77,8 +92,8 @@ const shouldIncrementChatUnread = (message) => (!message.key.fromMe && !message.
|
|
|
77
92
|
* Typically -- that'll be the remoteJid, but for broadcasts, it'll be the participant
|
|
78
93
|
*/
|
|
79
94
|
const getChatId = ({ remoteJid, participant, fromMe }) => {
|
|
80
|
-
if (
|
|
81
|
-
&& !
|
|
95
|
+
if (isJidBroadcast(remoteJid)
|
|
96
|
+
&& !isJidStatusBroadcast(remoteJid)
|
|
82
97
|
&& !fromMe) {
|
|
83
98
|
return participant
|
|
84
99
|
}
|
|
@@ -99,12 +114,37 @@ function decryptPollVote({ encPayload, encIv }, { pollCreatorJid, pollMsgId, pol
|
|
|
99
114
|
toBinary('Poll Vote'),
|
|
100
115
|
new Uint8Array([1])
|
|
101
116
|
])
|
|
102
|
-
const key0 =
|
|
103
|
-
const decKey =
|
|
117
|
+
const key0 = hmacSign(pollEncKey, new Uint8Array(32), 'sha256')
|
|
118
|
+
const decKey = hmacSign(sign, key0, 'sha256')
|
|
104
119
|
const aad = toBinary(`${pollMsgId}\u0000${voterJid}`)
|
|
105
|
-
const decrypted =
|
|
120
|
+
const decrypted = aesDecryptGCM(encPayload, decKey, encIv, aad)
|
|
106
121
|
|
|
107
|
-
return
|
|
122
|
+
return proto.Message.PollVoteMessage.decode(decrypted)
|
|
123
|
+
|
|
124
|
+
function toBinary(txt) {
|
|
125
|
+
return Buffer.from(txt)
|
|
126
|
+
}
|
|
127
|
+
}
|
|
128
|
+
|
|
129
|
+
/**
|
|
130
|
+
* Decrypt an event edit
|
|
131
|
+
* @param edit encrypted event edit
|
|
132
|
+
* @returns message
|
|
133
|
+
*/
|
|
134
|
+
function decryptEventEdit({ encPayload, encIv }, { eventCreatorJid, eventMsgId, eventEncKey, responderJid }) {
|
|
135
|
+
const sign = Buffer.concat([
|
|
136
|
+
toBinary(eventMsgId),
|
|
137
|
+
toBinary(eventCreatorJid),
|
|
138
|
+
toBinary(responderJid),
|
|
139
|
+
toBinary('Event Edit'),
|
|
140
|
+
new Uint8Array([1])
|
|
141
|
+
])
|
|
142
|
+
|
|
143
|
+
const key0 = hmacSign(eventEncKey, new Uint8Array(32), 'sha256')
|
|
144
|
+
const decKey = hmacSign(sign, key0, 'sha256')
|
|
145
|
+
const decrypted = aesDecryptGCM(encPayload, decKey, encIv, null)
|
|
146
|
+
|
|
147
|
+
return proto.Message.decode(decrypted)
|
|
108
148
|
|
|
109
149
|
function toBinary(txt) {
|
|
110
150
|
return Buffer.from(txt)
|
|
@@ -126,12 +166,62 @@ function decryptEventResponse({ encPayload, encIv }, { eventCreatorJid, eventMsg
|
|
|
126
166
|
new Uint8Array([1])
|
|
127
167
|
])
|
|
128
168
|
|
|
129
|
-
const key0 =
|
|
130
|
-
const decKey =
|
|
169
|
+
const key0 = hmacSign(eventEncKey, new Uint8Array(32), 'sha256')
|
|
170
|
+
const decKey = hmacSign(sign, key0, 'sha256')
|
|
131
171
|
const aad = toBinary(`${eventMsgId}\u0000${responderJid}`)
|
|
132
|
-
const decrypted =
|
|
172
|
+
const decrypted = aesDecryptGCM(encPayload, decKey, encIv, aad)
|
|
173
|
+
|
|
174
|
+
return proto.Message.EventResponseMessage.decode(decrypted)
|
|
175
|
+
|
|
176
|
+
function toBinary(txt) {
|
|
177
|
+
return Buffer.from(txt)
|
|
178
|
+
}
|
|
179
|
+
}
|
|
180
|
+
|
|
181
|
+
/**
|
|
182
|
+
* Decrypt an comment message
|
|
183
|
+
* @param comment encrypted comment message
|
|
184
|
+
* @returns message
|
|
185
|
+
*/
|
|
186
|
+
function decryptComment({ encPayload, encIv }, { commentCreatorJid, commentMsgId, commentEncKey, commentJid }) {
|
|
187
|
+
const sign = Buffer.concat([
|
|
188
|
+
toBinary(commentMsgId),
|
|
189
|
+
toBinary(commentCreatorJid),
|
|
190
|
+
toBinary(commentJid),
|
|
191
|
+
toBinary('Enc Comment'),
|
|
192
|
+
new Uint8Array([1])
|
|
193
|
+
])
|
|
194
|
+
|
|
195
|
+
const key0 = hmacSign(commentEncKey, new Uint8Array(32), 'sha256')
|
|
196
|
+
const decKey = hmacSign(sign, key0, 'sha256')
|
|
197
|
+
const decrypted = aesDecryptGCM(encPayload, decKey, encIv, null)
|
|
133
198
|
|
|
134
|
-
return
|
|
199
|
+
return proto.Message.decode(decrypted)
|
|
200
|
+
|
|
201
|
+
function toBinary(txt) {
|
|
202
|
+
return Buffer.from(txt)
|
|
203
|
+
}
|
|
204
|
+
}
|
|
205
|
+
|
|
206
|
+
/**
|
|
207
|
+
* Decrypt an reaction
|
|
208
|
+
* @param reaction encrypted reaction
|
|
209
|
+
* @returns reaction message
|
|
210
|
+
*/
|
|
211
|
+
function decryptReaction({ encPayload, encIv }, { reactionCreatorJid, reactionMsgId, reactionEncKey, reactionJid }) {
|
|
212
|
+
const sign = Buffer.concat([
|
|
213
|
+
toBinary(reactionMsgId),
|
|
214
|
+
toBinary(reactionCreatorJid),
|
|
215
|
+
toBinary(reactionJid),
|
|
216
|
+
toBinary('Enc Reaction'),
|
|
217
|
+
new Uint8Array([1])
|
|
218
|
+
])
|
|
219
|
+
|
|
220
|
+
const key0 = hmacSign(reactionEncKey, new Uint8Array(32), 'sha256')
|
|
221
|
+
const decKey = hmacSign(sign, key0, 'sha256')
|
|
222
|
+
const decrypted = aesDecryptGCM(encPayload, decKey, encIv, null)
|
|
223
|
+
|
|
224
|
+
return proto.Message.ReactionMessage.decode(decrypted)
|
|
135
225
|
|
|
136
226
|
function toBinary(txt) {
|
|
137
227
|
return Buffer.from(txt)
|
|
@@ -142,17 +232,17 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
142
232
|
const meId = creds.me.id
|
|
143
233
|
const meLid = creds.me.lid
|
|
144
234
|
const { accountSettings } = creds
|
|
145
|
-
const chat = { id:
|
|
235
|
+
const chat = { id: jidNormalizedUser(getChatId(message.key)) }
|
|
146
236
|
const isRealMsg = isRealMessage(message, meId)
|
|
147
237
|
if (isRealMsg) {
|
|
148
238
|
chat.messages = [{ message }]
|
|
149
|
-
chat.conversationTimestamp =
|
|
239
|
+
chat.conversationTimestamp = toNumber(message.messageTimestamp)
|
|
150
240
|
// only increment unread count if not CIPHERTEXT and from another person
|
|
151
241
|
if (shouldIncrementChatUnread(message)) {
|
|
152
242
|
chat.unreadCount = (chat.unreadCount || 0) + 1
|
|
153
243
|
}
|
|
154
244
|
}
|
|
155
|
-
const content =
|
|
245
|
+
const content = normalizeMessageContent(message.message)
|
|
156
246
|
// unarchive chat if it's a real message, or someone reacted to our message
|
|
157
247
|
// and we've the unarchive chats setting on
|
|
158
248
|
if (isRealMsg || content?.reactionMessage?.key?.fromMe
|
|
@@ -163,7 +253,7 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
163
253
|
const protocolMsg = content?.protocolMessage
|
|
164
254
|
if (protocolMsg) {
|
|
165
255
|
switch (protocolMsg.type) {
|
|
166
|
-
case
|
|
256
|
+
case proto.Message.ProtocolMessage.Type.HISTORY_SYNC_NOTIFICATION:
|
|
167
257
|
const histNotification = protocolMsg.historySyncNotification
|
|
168
258
|
const process = shouldProcessHistoryMsg
|
|
169
259
|
const isLatest = !creds.processedHistoryMessages?.length
|
|
@@ -174,7 +264,7 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
174
264
|
isLatest,
|
|
175
265
|
}, 'got history notification')
|
|
176
266
|
if (process) {
|
|
177
|
-
if (histNotification.syncType !==
|
|
267
|
+
if (histNotification.syncType !== proto.HistorySync.HistorySyncType.ON_DEMAND) {
|
|
178
268
|
ev.emit('creds.update', {
|
|
179
269
|
processedHistoryMessages: [
|
|
180
270
|
...(creds.processedHistoryMessages || []),
|
|
@@ -182,17 +272,17 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
182
272
|
]
|
|
183
273
|
})
|
|
184
274
|
}
|
|
185
|
-
const data = await
|
|
275
|
+
const data = await downloadAndProcessHistorySyncNotification(histNotification, options)
|
|
186
276
|
ev.emit('messaging-history.set', {
|
|
187
277
|
...data,
|
|
188
|
-
isLatest: histNotification.syncType !==
|
|
278
|
+
isLatest: histNotification.syncType !== proto.HistorySync.HistorySyncType.ON_DEMAND
|
|
189
279
|
? isLatest
|
|
190
280
|
: undefined,
|
|
191
281
|
peerDataRequestSessionId: histNotification.peerDataRequestSessionId
|
|
192
282
|
})
|
|
193
283
|
}
|
|
194
284
|
break
|
|
195
|
-
case
|
|
285
|
+
case proto.Message.ProtocolMessage.Type.APP_STATE_SYNC_KEY_SHARE:
|
|
196
286
|
const keys = protocolMsg.appStateSyncKeyShare.keys
|
|
197
287
|
if (keys?.length) {
|
|
198
288
|
let newAppStateSyncKeyId = ''
|
|
@@ -212,24 +302,24 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
212
302
|
logger?.info({ protocolMsg }, 'recv app state sync with 0 keys')
|
|
213
303
|
}
|
|
214
304
|
break
|
|
215
|
-
case
|
|
305
|
+
case proto.Message.ProtocolMessage.Type.REVOKE:
|
|
216
306
|
ev.emit('messages.update', [
|
|
217
307
|
{
|
|
218
308
|
key: {
|
|
219
309
|
...message.key,
|
|
220
310
|
id: protocolMsg.key.id
|
|
221
311
|
},
|
|
222
|
-
update: { message: null, messageStubType:
|
|
312
|
+
update: { message: null, messageStubType: WAMessageStubType.REVOKE, key: message.key }
|
|
223
313
|
}
|
|
224
314
|
])
|
|
225
315
|
break
|
|
226
|
-
case
|
|
316
|
+
case proto.Message.ProtocolMessage.Type.EPHEMERAL_SETTING:
|
|
227
317
|
Object.assign(chat, {
|
|
228
|
-
ephemeralSettingTimestamp:
|
|
318
|
+
ephemeralSettingTimestamp: toNumber(message.messageTimestamp),
|
|
229
319
|
ephemeralExpiration: protocolMsg.ephemeralExpiration || null
|
|
230
320
|
})
|
|
231
321
|
break
|
|
232
|
-
case
|
|
322
|
+
case proto.Message.ProtocolMessage.Type.PEER_DATA_OPERATION_REQUEST_RESPONSE_MESSAGE:
|
|
233
323
|
const response = protocolMsg.peerDataOperationRequestResponseMessage
|
|
234
324
|
if (response) {
|
|
235
325
|
await laceholderResendCache?.del(response.stanzaId)
|
|
@@ -239,7 +329,7 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
239
329
|
const { placeholderMessageResendResponse: retryResponse } = result
|
|
240
330
|
//eslint-disable-next-line max-depth
|
|
241
331
|
if (retryResponse) {
|
|
242
|
-
const webMessageInfo =
|
|
332
|
+
const webMessageInfo = proto.WebMessageInfo.decode(retryResponse.webMessageInfoBytes)
|
|
243
333
|
// wait till another upsert event is available, don't want it to be part of the PDO response message
|
|
244
334
|
setTimeout(() => {
|
|
245
335
|
ev.emit('messages.upsert', {
|
|
@@ -252,7 +342,7 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
252
342
|
}
|
|
253
343
|
}
|
|
254
344
|
break
|
|
255
|
-
case
|
|
345
|
+
case proto.Message.ProtocolMessage.Type.MESSAGE_EDIT:
|
|
256
346
|
ev.emit('messages.update', [
|
|
257
347
|
{
|
|
258
348
|
// flip the sender / fromMe properties because they're in the perspective of the sender
|
|
@@ -264,15 +354,15 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
264
354
|
}
|
|
265
355
|
},
|
|
266
356
|
messageTimestamp: protocolMsg.timestampMs
|
|
267
|
-
? Math.floor(
|
|
357
|
+
? Math.floor(toNumber(protocolMsg.timestampMs) / 1000)
|
|
268
358
|
: message.messageTimestamp
|
|
269
359
|
}
|
|
270
360
|
}
|
|
271
361
|
])
|
|
272
362
|
break
|
|
273
|
-
case
|
|
363
|
+
case proto.Message.ProtocolMessage.Type.LID_MIGRATION_MAPPING_SYNC:
|
|
274
364
|
const encodedPayload = protocolMsg.lidMigrationMappingSyncMessage?.encodedMappingPayload
|
|
275
|
-
const { pnToLidMappings, chatDbMigrationTimestamp } =
|
|
365
|
+
const { pnToLidMappings, chatDbMigrationTimestamp } = proto.LIDMigrationMappingSyncPayload.decode(encodedPayload)
|
|
276
366
|
|
|
277
367
|
logger?.debug({ pnToLidMappings, chatDbMigrationTimestamp }, 'got lid mappings and chat db migration timestamp')
|
|
278
368
|
|
|
@@ -285,10 +375,10 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
285
375
|
|
|
286
376
|
await signalRepository.lidMapping.storeLIDPNMappings(pairs)
|
|
287
377
|
break
|
|
288
|
-
case
|
|
378
|
+
case proto.Message.ProtocolMessage.Type.LIMIT_SHARING:
|
|
289
379
|
ev.emit('limit-sharing.update', {
|
|
290
380
|
id: message.key.remoteJid,
|
|
291
|
-
author:
|
|
381
|
+
author: areJidsSameUser(message.key.remoteJid, protocolMsg.key.remoteJid) ? jidNormalizedUser(meId) : message.key.remoteJid,
|
|
292
382
|
action: `${protocolMsg.limitSharing.sharingLimited ? 'on' : 'off'}`,
|
|
293
383
|
trigger: protocolMsg.limitSharing.trigger,
|
|
294
384
|
update_time: protocolMsg.limitSharing.limitSharingSettingTimestamp
|
|
@@ -317,13 +407,13 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
317
407
|
const emitGroupRequestJoin = (participant, action, method) => {
|
|
318
408
|
ev.emit('group.join-request', { id: jid, author: message.participant, participant, action, method: method })
|
|
319
409
|
}
|
|
320
|
-
const participantsIncludesMe = () => participants.find(jid =>
|
|
410
|
+
const participantsIncludesMe = () => participants.find(jid => areJidsSameUser(meId, jid))
|
|
321
411
|
switch (message.messageStubType) {
|
|
322
|
-
case
|
|
412
|
+
case WAMessageStubType.GROUP_PARTICIPANT_CHANGE_NUMBER:
|
|
323
413
|
participants = message.messageStubParameters || []
|
|
324
414
|
emitParticipantsUpdate('modify')
|
|
325
415
|
break
|
|
326
|
-
case
|
|
416
|
+
case WAMessageStubType.GROUP_PARTICIPANT_LEAVE:
|
|
327
417
|
participants = message.messageStubParameters || [];
|
|
328
418
|
emitParticipantsUpdate('leave');
|
|
329
419
|
// mark the chat read only if you left the group
|
|
@@ -331,7 +421,7 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
331
421
|
chat.readOnly = true;
|
|
332
422
|
}
|
|
333
423
|
break;
|
|
334
|
-
case
|
|
424
|
+
case WAMessageStubType.GROUP_PARTICIPANT_REMOVE:
|
|
335
425
|
participants = message.messageStubParameters || []
|
|
336
426
|
emitParticipantsUpdate('remove')
|
|
337
427
|
// mark the chat read only if you left the group
|
|
@@ -339,62 +429,62 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
339
429
|
chat.readOnly = true
|
|
340
430
|
}
|
|
341
431
|
break
|
|
342
|
-
case
|
|
343
|
-
case
|
|
432
|
+
case WAMessageStubType.GROUP_PARTICIPANT_ADD:
|
|
433
|
+
case WAMessageStubType.GROUP_PARTICIPANT_INVITE:
|
|
344
434
|
let actionGp = 'invite'
|
|
345
435
|
participants = message.messageStubParameters || []
|
|
346
436
|
if (participantsIncludesMe()) chat.readOnly = false;
|
|
347
437
|
if (message?.key?.participant && !participants.includes(message?.key?.participant)) {
|
|
348
438
|
actionGp = 'approval-invite'
|
|
349
439
|
}
|
|
350
|
-
case
|
|
440
|
+
case WAMessageStubType.GROUP_PARTICIPANT_ADD_REQUEST_JOIN:
|
|
351
441
|
participants = message.messageStubParameters || []
|
|
352
442
|
if (participantsIncludesMe()) {
|
|
353
443
|
chat.readOnly = false
|
|
354
444
|
}
|
|
355
445
|
emitParticipantsUpdate('add')
|
|
356
446
|
break
|
|
357
|
-
case
|
|
358
|
-
case
|
|
447
|
+
case WAMessageStubType.GROUP_PARTICIPANT_DEMOTE:
|
|
448
|
+
case WAMessageStubType.COMMUNITY_PARTICIPANT_DEMOTE:
|
|
359
449
|
participants = message.messageStubParameters || []
|
|
360
450
|
emitParticipantsUpdate('demote')
|
|
361
451
|
break
|
|
362
|
-
case
|
|
363
|
-
case
|
|
452
|
+
case WAMessageStubType.GROUP_PARTICIPANT_PROMOTE:
|
|
453
|
+
case WAMessageStubType.COMMUNITY_PARTICIPANT_PROMOTE:
|
|
364
454
|
participants = message.messageStubParameters || []
|
|
365
455
|
emitParticipantsUpdate('promote')
|
|
366
456
|
break
|
|
367
|
-
case
|
|
457
|
+
case WAMessageStubType.GROUP_CHANGE_ANNOUNCE:
|
|
368
458
|
const announceValue = message.messageStubParameters?.[0]
|
|
369
459
|
emitGroupUpdate({ announce: announceValue === 'true' || announceValue === 'on' })
|
|
370
460
|
break
|
|
371
|
-
case
|
|
461
|
+
case WAMessageStubType.GROUP_CHANGE_RESTRICT:
|
|
372
462
|
const restrictValue = message.messageStubParameters?.[0]
|
|
373
463
|
emitGroupUpdate({ restrict: restrictValue === 'true' || restrictValue === 'on' })
|
|
374
464
|
break
|
|
375
|
-
case
|
|
465
|
+
case WAMessageStubType.GROUP_CHANGE_SUBJECT:
|
|
376
466
|
const name = message.messageStubParameters?.[0]
|
|
377
467
|
chat.name = name
|
|
378
468
|
emitGroupUpdate({ subject: name })
|
|
379
469
|
break
|
|
380
|
-
case
|
|
470
|
+
case WAMessageStubType.GROUP_CHANGE_DESCRIPTION:
|
|
381
471
|
const description = message.messageStubParameters?.[0]
|
|
382
472
|
chat.description = description
|
|
383
473
|
emitGroupUpdate({ desc: description })
|
|
384
474
|
break
|
|
385
|
-
case
|
|
475
|
+
case WAMessageStubType.GROUP_CHANGE_INVITE_LINK:
|
|
386
476
|
const code = message.messageStubParameters?.[0]
|
|
387
477
|
emitGroupUpdate({ inviteCode: code })
|
|
388
478
|
break
|
|
389
|
-
case
|
|
479
|
+
case WAMessageStubType.GROUP_MEMBER_ADD_MODE:
|
|
390
480
|
const memberAddValue = message.messageStubParameters?.[0]
|
|
391
481
|
emitGroupUpdate({ memberAddMode: memberAddValue === 'all_member_add' })
|
|
392
482
|
break
|
|
393
|
-
case
|
|
483
|
+
case WAMessageStubType.GROUP_MEMBERSHIP_JOIN_APPROVAL_MODE:
|
|
394
484
|
const approvalMode = message.messageStubParameters?.[0]
|
|
395
485
|
emitGroupUpdate({ joinApprovalMode: approvalMode === 'on' })
|
|
396
486
|
break
|
|
397
|
-
case
|
|
487
|
+
case WAMessageStubType.GROUP_MEMBERSHIP_JOIN_APPROVAL_REQUEST_NON_ADMIN_ADD:
|
|
398
488
|
const participant = message.messageStubParameters?.[0]
|
|
399
489
|
const action = message.messageStubParameters?.[1]
|
|
400
490
|
const method = message.messageStubParameters?.[2]
|
|
@@ -403,50 +493,50 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
403
493
|
}
|
|
404
494
|
}
|
|
405
495
|
else if (content?.pollUpdateMessage) {
|
|
406
|
-
|
|
496
|
+
const pollUpdate = content.pollUpdateMessage
|
|
407
497
|
const creationMsgKey = pollUpdate.pollCreationMessageKey
|
|
408
|
-
|
|
498
|
+
|
|
409
499
|
// we need to fetch the poll creation message to get the poll enc key
|
|
410
500
|
const pollMsg = await getMessage(creationMsgKey)
|
|
411
501
|
if (pollMsg) {
|
|
412
|
-
|
|
413
|
-
|
|
414
|
-
|
|
415
|
-
|
|
416
|
-
|
|
417
|
-
|
|
502
|
+
try {
|
|
503
|
+
const meLidNormalised = jidNormalizedUser(meLid)
|
|
504
|
+
const deviceType = getDevice(creationMsgKey.id)
|
|
505
|
+
const pollCreationFromMe = deviceType === 'baileys' ? true : false
|
|
506
|
+
const pollEncKey = pollMsg.messageContextInfo?.messageSecret
|
|
507
|
+
const voterJid = getKeyAuthor(message.key, meLidNormalised)
|
|
418
508
|
|
|
419
|
-
|
|
509
|
+
let pollCreatorJid = getKeyAuthor(creationMsgKey, meLidNormalised)
|
|
420
510
|
|
|
421
|
-
|
|
422
|
-
|
|
423
|
-
|
|
511
|
+
if (pollCreationFromMe) {
|
|
512
|
+
pollCreatorJid = meLidNormalised
|
|
513
|
+
}
|
|
424
514
|
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
515
|
+
if (!pollEncKey) {
|
|
516
|
+
logger?.warn({ vote: pollUpdate.vote, creationMsgKey }, 'poll creation: missing messageSecret for decryption')
|
|
517
|
+
} else {
|
|
518
|
+
const voteMsg = decryptPollVote(pollUpdate.vote, {
|
|
519
|
+
pollEncKey,
|
|
520
|
+
pollCreatorJid,
|
|
521
|
+
pollMsgId: creationMsgKey.id,
|
|
522
|
+
voterJid
|
|
523
|
+
})
|
|
434
524
|
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
}
|
|
525
|
+
ev.emit('messages.update', [
|
|
526
|
+
{
|
|
527
|
+
key: creationMsgKey,
|
|
528
|
+
update: {
|
|
529
|
+
pollUpdates: [
|
|
530
|
+
{
|
|
531
|
+
pollUpdateMessageKey: message.key,
|
|
532
|
+
vote: voteMsg,
|
|
533
|
+
senderTimestampMs: content.pollUpdateMessage.senderTimestampMs.toNumber()
|
|
534
|
+
}
|
|
535
|
+
]
|
|
447
536
|
}
|
|
448
|
-
|
|
449
|
-
|
|
537
|
+
}
|
|
538
|
+
])
|
|
539
|
+
}
|
|
450
540
|
}
|
|
451
541
|
catch (err) {
|
|
452
542
|
logger?.warn({ err, creationMsgKey }, 'failed to decrypt poll vote')
|
|
@@ -456,45 +546,98 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
456
546
|
logger?.warn({ creationMsgKey }, 'poll creation message not found, cannot decrypt update')
|
|
457
547
|
}
|
|
458
548
|
}
|
|
549
|
+
else if (content?.secretEncryptedMessage) {
|
|
550
|
+
const encEventEdit = content.secretEncryptedMessage
|
|
551
|
+
const creationMsgKey = encEventEdit.targetMessageKey
|
|
552
|
+
|
|
553
|
+
if (proto.Message.SecretEncryptedMessage.SecretEncType[encEventEdit.secretEncType] !== 'EVENT_EDIT') return
|
|
554
|
+
|
|
555
|
+
// we need to fetch the event creation message to get the event enc key
|
|
556
|
+
const eventMsg = await getMessage(creationMsgKey)
|
|
557
|
+
if (eventMsg) {
|
|
558
|
+
try {
|
|
559
|
+
const meLidNormalised = jidNormalizedUser(meLid)
|
|
560
|
+
const eventCreatorJid = getKeyAuthor(message.key, meLidNormalised)
|
|
561
|
+
const responderJid = getKeyAuthor(message.key, meLidNormalised)
|
|
562
|
+
const eventEncKey = eventMsg.messageContextInfo?.messageSecret
|
|
563
|
+
|
|
564
|
+
if (!eventEncKey) {
|
|
565
|
+
logger?.warn({ encEventEdit, creationMsgKey }, 'event edit: missing messageSecret for decryption')
|
|
566
|
+
} else {
|
|
567
|
+
const responseMsg = decryptEventEdit(encEventEdit, {
|
|
568
|
+
eventEncKey,
|
|
569
|
+
eventCreatorJid,
|
|
570
|
+
eventMsgId: creationMsgKey.id,
|
|
571
|
+
responderJid
|
|
572
|
+
})
|
|
573
|
+
const content = normalizeMessageContent(responseMsg)
|
|
574
|
+
const protocolMsg = content?.protocolMessage
|
|
575
|
+
|
|
576
|
+
ev.emit('messages.update', [
|
|
577
|
+
{
|
|
578
|
+
key: { ...message.key, id: protocolMsg.key?.id },
|
|
579
|
+
update: {
|
|
580
|
+
message: {
|
|
581
|
+
messageContextInfo: responseMsg.messageContextInfo,
|
|
582
|
+
editedMessage: {
|
|
583
|
+
message: protocolMsg.editedMessage
|
|
584
|
+
}
|
|
585
|
+
},
|
|
586
|
+
messageTimestamp: protocolMsg.timestampMs
|
|
587
|
+
? Math.floor(toNumber(protocolMsg.timestampMs) / 1000)
|
|
588
|
+
: message.messageTimestamp
|
|
589
|
+
}
|
|
590
|
+
}
|
|
591
|
+
])
|
|
592
|
+
}
|
|
593
|
+
}
|
|
594
|
+
catch (err) {
|
|
595
|
+
logger?.warn({ err, creationMsgKey, encEventEdit }, 'failed to decrypt event edit')
|
|
596
|
+
}
|
|
597
|
+
}
|
|
598
|
+
else {
|
|
599
|
+
logger?.warn({ encEventEdit, creationMsgKey }, 'event creation message not found, cannot decrypt update')
|
|
600
|
+
}
|
|
601
|
+
}
|
|
459
602
|
else if (content?.encEventResponseMessage) {
|
|
460
603
|
const encEventResponse = content.encEventResponseMessage
|
|
461
604
|
const creationMsgKey = encEventResponse.eventCreationMessageKey
|
|
462
|
-
|
|
605
|
+
|
|
463
606
|
// we need to fetch the event creation message to get the event enc key
|
|
464
607
|
const eventMsg = await getMessage(creationMsgKey)
|
|
465
608
|
if (eventMsg) {
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
609
|
+
try {
|
|
610
|
+
const meLidNormalised = jidNormalizedUser(meLid)
|
|
611
|
+
const eventCreatorJid = getKeyAuthor(creationMsgKey, meLidNormalised)
|
|
612
|
+
const responderJid = getKeyAuthor(message.key, meLidNormalised)
|
|
613
|
+
const eventEncKey = eventMsg.messageContextInfo?.messageSecret
|
|
614
|
+
|
|
615
|
+
if (!eventEncKey) {
|
|
616
|
+
logger?.warn({ encEventResponse, creationMsgKey }, 'event response: missing messageSecret for decryption')
|
|
617
|
+
} else {
|
|
618
|
+
const responseMsg = decryptEventResponse(encEventResponse, {
|
|
619
|
+
eventEncKey,
|
|
620
|
+
eventCreatorJid,
|
|
621
|
+
eventMsgId: creationMsgKey.id,
|
|
622
|
+
responderJid
|
|
623
|
+
})
|
|
624
|
+
|
|
625
|
+
const eventResponse = {
|
|
626
|
+
eventResponseMessageKey: message.key,
|
|
627
|
+
senderTimestampMs: responseMsg.timestampMs,
|
|
628
|
+
response: responseMsg
|
|
629
|
+
}
|
|
630
|
+
|
|
631
|
+
ev.emit('messages.update', [
|
|
632
|
+
{
|
|
633
|
+
key: creationMsgKey,
|
|
634
|
+
update: {
|
|
635
|
+
eventResponses: [eventResponse]
|
|
636
|
+
}
|
|
637
|
+
}
|
|
638
|
+
])
|
|
639
|
+
}
|
|
640
|
+
}
|
|
498
641
|
catch (err) {
|
|
499
642
|
logger?.warn({ err, creationMsgKey, encEventResponse }, 'failed to decrypt event response')
|
|
500
643
|
}
|
|
@@ -503,6 +646,94 @@ const processMessage = async (message, { shouldProcessHistoryMsg, placeholderRes
|
|
|
503
646
|
logger?.warn({ encEventResponse, creationMsgKey }, 'event creation message not found, cannot decrypt update')
|
|
504
647
|
}
|
|
505
648
|
}
|
|
649
|
+
else if (content?.encCommentMessage) {
|
|
650
|
+
const encComment = content.encCommentMessage
|
|
651
|
+
const creationMsgKey = encComment.targetMessageKey
|
|
652
|
+
|
|
653
|
+
// we need to fetch the message to get the reaction enc key
|
|
654
|
+
const commentMsg = await getMessage(creationMsgKey)
|
|
655
|
+
if (commentMsg) {
|
|
656
|
+
try {
|
|
657
|
+
const meLidNormalised = jidNormalizedUser(meLid)
|
|
658
|
+
const commentCreatorJid = creationMsgKey.participant ? creationMsgKey.participant : message.key?.participant ? message.key.participant : meLidNormalised
|
|
659
|
+
const commentJid = message.key?.participant ? message.key.participant : creationMsgKey.participant ? creationMsgKey.participant : meLidNormalised
|
|
660
|
+
const commentEncKey = commentMsg.messageContextInfo?.messageSecret
|
|
661
|
+
|
|
662
|
+
if (!commentEncKey) {
|
|
663
|
+
logger?.warn({ encComment, creationMsgKey }, 'comment message: missing messageSecret for decryption')
|
|
664
|
+
} else {
|
|
665
|
+
const responseMsg = decryptComment(encComment, {
|
|
666
|
+
commentEncKey,
|
|
667
|
+
commentCreatorJid,
|
|
668
|
+
commentMsgId: creationMsgKey.id,
|
|
669
|
+
commentJid
|
|
670
|
+
})
|
|
671
|
+
|
|
672
|
+
ev.emit('messages.upsert', {
|
|
673
|
+
messages: [{
|
|
674
|
+
key: message.key,
|
|
675
|
+
message: responseMsg
|
|
676
|
+
}],
|
|
677
|
+
type: 'append'
|
|
678
|
+
})
|
|
679
|
+
}
|
|
680
|
+
}
|
|
681
|
+
catch (err) {
|
|
682
|
+
logger?.warn({ err, creationMsgKey, encComment }, 'failed to decrypt comment message')
|
|
683
|
+
}
|
|
684
|
+
}
|
|
685
|
+
else {
|
|
686
|
+
logger?.warn({ encComment, creationMsgKey }, 'creation message not found, cannot decrypt')
|
|
687
|
+
}
|
|
688
|
+
}
|
|
689
|
+
else if (content?.encReactionMessage) {
|
|
690
|
+
const encReaction = content.encReactionMessage
|
|
691
|
+
const creationMsgKey = encReaction.targetMessageKey
|
|
692
|
+
|
|
693
|
+
// we need to fetch the message to get the reaction enc key
|
|
694
|
+
const reactMsg = await getMessage(creationMsgKey)
|
|
695
|
+
if (reactMsg) {
|
|
696
|
+
try {
|
|
697
|
+
const meLidNormalised = jidNormalizedUser(meLid)
|
|
698
|
+
const reactionCreatorJid = creationMsgKey.participant ? creationMsgKey.participant : message.key?.participant ? message.key.participant : meLidNormalised
|
|
699
|
+
const reactionJid = message.key?.participant ? message.key.participant : creationMsgKey.participant ? creationMsgKey.participant : meLidNormalised
|
|
700
|
+
const reactionEncKey = reactMsg.messageContextInfo?.messageSecret
|
|
701
|
+
|
|
702
|
+
if (!reactionEncKey) {
|
|
703
|
+
logger?.warn({ encReaction, creationMsgKey }, 'reaction: missing messageSecret for decryption')
|
|
704
|
+
} else {
|
|
705
|
+
const responseMsg = decryptReaction(encReaction, {
|
|
706
|
+
reactionEncKey,
|
|
707
|
+
reactionCreatorJid,
|
|
708
|
+
reactionMsgId: creationMsgKey.id,
|
|
709
|
+
reactionJid
|
|
710
|
+
})
|
|
711
|
+
|
|
712
|
+
const Reaction = {
|
|
713
|
+
key: message.key,
|
|
714
|
+
message: {
|
|
715
|
+
reactionMessage: {
|
|
716
|
+
key: creationMsgKey,
|
|
717
|
+
text: responseMsg.text,
|
|
718
|
+
senderTimestampMs: responseMsg.senderTimestampMs
|
|
719
|
+
}
|
|
720
|
+
}
|
|
721
|
+
}
|
|
722
|
+
|
|
723
|
+
ev.emit('messages.upsert', {
|
|
724
|
+
messages: [Reaction],
|
|
725
|
+
type: 'append'
|
|
726
|
+
})
|
|
727
|
+
}
|
|
728
|
+
}
|
|
729
|
+
catch (err) {
|
|
730
|
+
logger?.warn({ err, creationMsgKey, encReaction }, 'failed to decrypt reaction')
|
|
731
|
+
}
|
|
732
|
+
}
|
|
733
|
+
else {
|
|
734
|
+
logger?.warn({ encReaction, creationMsgKey }, 'creation message not found, cannot decrypt')
|
|
735
|
+
}
|
|
736
|
+
}
|
|
506
737
|
if (Object.keys(chat).length > 1) {
|
|
507
738
|
ev.emit('chats.update', [chat])
|
|
508
739
|
}
|
|
@@ -514,6 +745,9 @@ module.exports = {
|
|
|
514
745
|
shouldIncrementChatUnread,
|
|
515
746
|
getChatId,
|
|
516
747
|
decryptPollVote,
|
|
748
|
+
decryptEventEdit,
|
|
517
749
|
decryptEventResponse,
|
|
750
|
+
decryptComment,
|
|
751
|
+
decryptReaction,
|
|
518
752
|
processMessage
|
|
519
753
|
}
|