@eduh_dev021/baileys 0.0.0-stage → 1.0.0
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/LICENSE +23 -0
- package/README.md +495 -2
- package/WAProto/index.d.ts +22220 -0
- package/WAProto/index.js +5 -0
- package/cjs/WAProto/index.d.ts +22220 -0
- package/cjs/WAProto/index.js +60125 -0
- package/cjs/engine-requirements.js +12 -0
- package/cjs/lib/Addon/http-error.d.ts +18 -0
- package/cjs/lib/Addon/http-error.js +66 -0
- package/cjs/lib/Addon/index.d.ts +3 -0
- package/cjs/lib/Addon/index.js +50 -0
- package/cjs/lib/Addon/keyed-db.d.ts +14 -0
- package/cjs/lib/Addon/keyed-db.js +264 -0
- package/cjs/lib/Addon/link-preview.d.ts +15 -0
- package/cjs/lib/Addon/link-preview.js +104 -0
- package/cjs/lib/Defaults/index.d.ts +184 -0
- package/cjs/lib/Defaults/index.js +292 -0
- package/cjs/lib/Signal/Group/ciphertext-message.d.ts +9 -0
- package/cjs/lib/Signal/Group/ciphertext-message.js +37 -0
- package/cjs/lib/Signal/Group/group-cipher.d.ts +10 -0
- package/cjs/lib/Signal/Group/group-cipher.js +105 -0
- package/cjs/lib/Signal/Group/group-session-builder.d.ts +7 -0
- package/cjs/lib/Signal/Group/group-session-builder.js +65 -0
- package/cjs/lib/Signal/Group/index.d.ts +11 -0
- package/cjs/lib/Signal/Group/index.js +67 -0
- package/cjs/lib/Signal/Group/keyhelper.d.ts +6 -0
- package/cjs/lib/Signal/Group/keyhelper.js +47 -0
- package/cjs/lib/Signal/Group/sender-chain-key.d.ts +13 -0
- package/cjs/lib/Signal/Group/sender-chain-key.js +51 -0
- package/cjs/lib/Signal/Group/sender-key-distribution-message.d.ts +16 -0
- package/cjs/lib/Signal/Group/sender-key-distribution-message.js +80 -0
- package/cjs/lib/Signal/Group/sender-key-message.d.ts +18 -0
- package/cjs/lib/Signal/Group/sender-key-message.js +87 -0
- package/cjs/lib/Signal/Group/sender-key-name.d.ts +11 -0
- package/cjs/lib/Signal/Group/sender-key-name.js +73 -0
- package/cjs/lib/Signal/Group/sender-key-record.d.ts +12 -0
- package/cjs/lib/Signal/Group/sender-key-record.js +66 -0
- package/cjs/lib/Signal/Group/sender-key-state.d.ts +16 -0
- package/cjs/lib/Signal/Group/sender-key-state.js +106 -0
- package/cjs/lib/Signal/Group/sender-message-key.d.ts +11 -0
- package/cjs/lib/Signal/Group/sender-message-key.js +51 -0
- package/cjs/lib/Signal/libsignal.d.ts +54 -0
- package/cjs/lib/Signal/libsignal.js +421 -0
- package/cjs/lib/Signal/lid-mapping.d.ts +20 -0
- package/cjs/lib/Signal/lid-mapping.js +292 -0
- package/cjs/lib/Socket/Client/index.d.ts +2 -0
- package/cjs/lib/Socket/Client/index.js +23 -0
- package/cjs/lib/Socket/Client/types.d.ts +5 -0
- package/cjs/lib/Socket/Client/types.js +36 -0
- package/cjs/lib/Socket/Client/websocket.d.ts +12 -0
- package/cjs/lib/Socket/Client/websocket.js +143 -0
- package/cjs/lib/Socket/business.d.ts +387 -0
- package/cjs/lib/Socket/business.js +402 -0
- package/cjs/lib/Socket/chats.d.ts +144 -0
- package/cjs/lib/Socket/chats.js +1118 -0
- package/cjs/lib/Socket/communities.d.ts +554 -0
- package/cjs/lib/Socket/communities.js +456 -0
- package/cjs/lib/Socket/groups.d.ts +286 -0
- package/cjs/lib/Socket/groups.js +366 -0
- package/cjs/lib/Socket/index.d.ts +522 -0
- package/cjs/lib/Socket/index.js +32 -0
- package/cjs/lib/Socket/messages-recv.d.ts +326 -0
- package/cjs/lib/Socket/messages-recv.js +1670 -0
- package/cjs/lib/Socket/messages-send.d.ts +321 -0
- package/cjs/lib/Socket/messages-send.js +1252 -0
- package/cjs/lib/Socket/mex.d.ts +1 -0
- package/cjs/lib/Socket/mex.js +65 -0
- package/cjs/lib/Socket/newsletter.d.ts +283 -0
- package/cjs/lib/Socket/newsletter.js +243 -0
- package/cjs/lib/Socket/socket.d.ts +61 -0
- package/cjs/lib/Socket/socket.js +908 -0
- package/cjs/lib/Store/index.d.ts +3 -0
- package/cjs/lib/Store/index.js +25 -0
- package/cjs/lib/Store/make-in-memory-store.d.ts +63 -0
- package/cjs/lib/Store/make-in-memory-store.js +431 -0
- package/cjs/lib/Store/make-ordered-dictionary.d.ts +12 -0
- package/cjs/lib/Store/make-ordered-dictionary.js +101 -0
- package/cjs/lib/Store/object-repository.d.ts +10 -0
- package/cjs/lib/Store/object-repository.js +49 -0
- package/cjs/lib/Transport/crypto.d.ts +6 -0
- package/cjs/lib/Transport/crypto.js +107 -0
- package/cjs/lib/Transport/curve.d.ts +8 -0
- package/cjs/lib/Transport/curve.js +94 -0
- package/cjs/lib/Transport/index.d.ts +16 -0
- package/cjs/lib/Transport/index.js +67 -0
- package/cjs/lib/Transport/internals.d.ts +57 -0
- package/cjs/lib/Transport/internals.js +203 -0
- package/cjs/lib/Transport/session-builder.d.ts +40 -0
- package/cjs/lib/Transport/session-builder.js +169 -0
- package/cjs/lib/Transport/session-cipher.d.ts +26 -0
- package/cjs/lib/Transport/session-cipher.js +328 -0
- package/cjs/lib/Transport/session-record.d.ts +55 -0
- package/cjs/lib/Transport/session-record.js +289 -0
- package/cjs/lib/Types/Auth.d.ts +1 -0
- package/cjs/lib/Types/Auth.js +15 -0
- package/cjs/lib/Types/Bussines.d.ts +1 -0
- package/cjs/lib/Types/Bussines.js +15 -0
- package/cjs/lib/Types/Call.d.ts +1 -0
- package/cjs/lib/Types/Call.js +15 -0
- package/cjs/lib/Types/Chat.d.ts +1 -0
- package/cjs/lib/Types/Chat.js +33 -0
- package/cjs/lib/Types/Contact.d.ts +1 -0
- package/cjs/lib/Types/Contact.js +15 -0
- package/cjs/lib/Types/Events.d.ts +1 -0
- package/cjs/lib/Types/Events.js +1 -0
- package/cjs/lib/Types/GroupMetadata.d.ts +1 -0
- package/cjs/lib/Types/GroupMetadata.js +15 -0
- package/cjs/lib/Types/Label.d.ts +2 -0
- package/cjs/lib/Types/Label.js +49 -0
- package/cjs/lib/Types/LabelAssociation.d.ts +2 -0
- package/cjs/lib/Types/LabelAssociation.js +31 -0
- package/cjs/lib/Types/Message.d.ts +11 -0
- package/cjs/lib/Types/Message.js +58 -0
- package/cjs/lib/Types/Mex.d.ts +2 -0
- package/cjs/lib/Types/Mex.js +66 -0
- package/cjs/lib/Types/Product.d.ts +1 -0
- package/cjs/lib/Types/Product.js +15 -0
- package/cjs/lib/Types/RichType.d.ts +2 -0
- package/cjs/lib/Types/RichType.js +50 -0
- package/cjs/lib/Types/Signal.d.ts +1 -0
- package/cjs/lib/Types/Signal.js +1 -0
- package/cjs/lib/Types/Socket.d.ts +1 -0
- package/cjs/lib/Types/Socket.js +1 -0
- package/cjs/lib/Types/State.d.ts +5 -0
- package/cjs/lib/Types/State.js +83 -0
- package/cjs/lib/Types/USync.d.ts +1 -0
- package/cjs/lib/Types/USync.js +1 -0
- package/cjs/lib/Types/index.d.ts +13 -0
- package/cjs/lib/Types/index.js +64 -0
- package/cjs/lib/Utils/auth-utils.d.ts +58 -0
- package/cjs/lib/Utils/auth-utils.js +275 -0
- package/cjs/lib/Utils/browser-utils.d.ts +9 -0
- package/cjs/lib/Utils/browser-utils.js +56 -0
- package/cjs/lib/Utils/business.d.ts +49 -0
- package/cjs/lib/Utils/business.js +259 -0
- package/cjs/lib/Utils/chat-utils.d.ts +408 -0
- package/cjs/lib/Utils/chat-utils.js +821 -0
- package/cjs/lib/Utils/companion-reg-client-utils.d.ts +4 -0
- package/cjs/lib/Utils/companion-reg-client-utils.js +71 -0
- package/cjs/lib/Utils/crypto.d.ts +39 -0
- package/cjs/lib/Utils/crypto.js +155 -0
- package/cjs/lib/Utils/decode-wa-message.d.ts +83 -0
- package/cjs/lib/Utils/decode-wa-message.js +316 -0
- package/cjs/lib/Utils/event-buffer.d.ts +12 -0
- package/cjs/lib/Utils/event-buffer.js +605 -0
- package/cjs/lib/Utils/generics.d.ts +63 -0
- package/cjs/lib/Utils/generics.js +440 -0
- package/cjs/lib/Utils/history.d.ts +75 -0
- package/cjs/lib/Utils/history.js +153 -0
- package/cjs/lib/Utils/identity-change-handler.d.ts +13 -0
- package/cjs/lib/Utils/identity-change-handler.js +73 -0
- package/cjs/lib/Utils/index.d.ts +24 -0
- package/cjs/lib/Utils/index.js +67 -0
- package/cjs/lib/Utils/link-preview.d.ts +13 -0
- package/cjs/lib/Utils/link-preview.js +87 -0
- package/cjs/lib/Utils/logger.d.ts +12 -0
- package/cjs/lib/Utils/logger.js +40 -0
- package/cjs/lib/Utils/lt-hash.d.ts +6 -0
- package/cjs/lib/Utils/lt-hash.js +28 -0
- package/cjs/lib/Utils/make-mutex.d.ts +6 -0
- package/cjs/lib/Utils/make-mutex.js +58 -0
- package/cjs/lib/Utils/message-retry-manager.d.ts +79 -0
- package/cjs/lib/Utils/message-retry-manager.js +274 -0
- package/cjs/lib/Utils/messages-media.d.ts +134 -0
- package/cjs/lib/Utils/messages-media.js +799 -0
- package/cjs/lib/Utils/messages.d.ts +47 -0
- package/cjs/lib/Utils/messages.js +1667 -0
- package/cjs/lib/Utils/noise-handler.d.ts +20 -0
- package/cjs/lib/Utils/noise-handler.js +223 -0
- package/cjs/lib/Utils/offline-node-processor.d.ts +10 -0
- package/cjs/lib/Utils/offline-node-processor.js +60 -0
- package/cjs/lib/Utils/pre-key-manager.d.ts +25 -0
- package/cjs/lib/Utils/pre-key-manager.js +116 -0
- package/cjs/lib/Utils/process-message.d.ts +83 -0
- package/cjs/lib/Utils/process-message.js +607 -0
- package/cjs/lib/Utils/reporting-utils.d.ts +12 -0
- package/cjs/lib/Utils/reporting-utils.js +282 -0
- package/cjs/lib/Utils/rich-message-utils.d.ts +48 -0
- package/cjs/lib/Utils/rich-message-utils.js +381 -0
- package/cjs/lib/Utils/signal.d.ts +82 -0
- package/cjs/lib/Utils/signal.js +232 -0
- package/cjs/lib/Utils/stanza-ack.d.ts +16 -0
- package/cjs/lib/Utils/stanza-ack.js +53 -0
- package/cjs/lib/Utils/sync-action-utils.d.ts +2 -0
- package/cjs/lib/Utils/sync-action-utils.js +68 -0
- package/cjs/lib/Utils/tc-token-utils.d.ts +29 -0
- package/cjs/lib/Utils/tc-token-utils.js +182 -0
- package/cjs/lib/Utils/use-multi-file-auth-state.d.ts +10 -0
- package/cjs/lib/Utils/use-multi-file-auth-state.js +135 -0
- package/cjs/lib/Utils/use-single-file-auth-state.d.ts +11 -0
- package/cjs/lib/Utils/use-single-file-auth-state.js +115 -0
- package/cjs/lib/Utils/use-sqlite-auth-state.d.ts +11 -0
- package/cjs/lib/Utils/use-sqlite-auth-state.js +140 -0
- package/cjs/lib/Utils/validate-connection.d.ts +44 -0
- package/cjs/lib/Utils/validate-connection.js +229 -0
- package/cjs/lib/WABinary/constants.d.ts +61 -0
- package/cjs/lib/WABinary/constants.js +1992 -0
- package/cjs/lib/WABinary/decode.d.ts +9 -0
- package/cjs/lib/WABinary/decode.js +292 -0
- package/cjs/lib/WABinary/encode.d.ts +2 -0
- package/cjs/lib/WABinary/encode.js +240 -0
- package/cjs/lib/WABinary/generic-utils.d.ts +79 -0
- package/cjs/lib/WABinary/generic-utils.js +252 -0
- package/cjs/lib/WABinary/index.d.ts +5 -0
- package/cjs/lib/WABinary/index.js +29 -0
- package/cjs/lib/WABinary/jid-utils.d.ts +28 -0
- package/cjs/lib/WABinary/jid-utils.js +151 -0
- package/cjs/lib/WABinary/types.d.ts +1 -0
- package/cjs/lib/WABinary/types.js +23 -0
- package/cjs/lib/WACrypto/appstate-keys.js +39 -0
- package/cjs/lib/WACrypto/curves/constants.js +37 -0
- package/cjs/lib/WACrypto/hkdf.js +38 -0
- package/cjs/lib/WACrypto/index.js +51 -0
- package/cjs/lib/WACrypto/lthash.js +59 -0
- package/cjs/lib/WACrypto/math/constants.js +53 -0
- package/cjs/lib/WACrypto/math/edwards.js +206 -0
- package/cjs/lib/WACrypto/math/fe.js +449 -0
- package/cjs/lib/WACrypto/math/le.js +44 -0
- package/cjs/lib/WACrypto/math/mod.js +36 -0
- package/cjs/lib/WACrypto/util/bytes.js +348 -0
- package/cjs/lib/WACrypto/x25519.js +157 -0
- package/cjs/lib/WACrypto/xeddsa.js +134 -0
- package/cjs/lib/WAM/BinaryInfo.d.ts +7 -0
- package/cjs/lib/WAM/BinaryInfo.js +35 -0
- package/cjs/lib/WAM/constants.d.ts +34926 -0
- package/cjs/lib/WAM/constants.js +22890 -0
- package/cjs/lib/WAM/encode.d.ts +1 -0
- package/cjs/lib/WAM/encode.js +162 -0
- package/cjs/lib/WAM/index.d.ts +3 -0
- package/cjs/lib/WAM/index.js +25 -0
- package/cjs/lib/WAUSync/Protocols/USyncContactProtocol.d.ts +36 -0
- package/cjs/lib/WAUSync/Protocols/USyncContactProtocol.js +77 -0
- package/cjs/lib/WAUSync/Protocols/USyncDeviceProtocol.d.ts +22 -0
- package/cjs/lib/WAUSync/Protocols/USyncDeviceProtocol.js +76 -0
- package/cjs/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.d.ts +12 -0
- package/cjs/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +52 -0
- package/cjs/lib/WAUSync/Protocols/USyncStatusProtocol.d.ts +12 -0
- package/cjs/lib/WAUSync/Protocols/USyncStatusProtocol.js +61 -0
- package/cjs/lib/WAUSync/Protocols/USyncUsernameProtocol.d.ts +9 -0
- package/cjs/lib/WAUSync/Protocols/USyncUsernameProtocol.js +50 -0
- package/cjs/lib/WAUSync/Protocols/UsyncBotProfileProtocol.d.ts +38 -0
- package/cjs/lib/WAUSync/Protocols/UsyncBotProfileProtocol.js +76 -0
- package/cjs/lib/WAUSync/Protocols/UsyncLIDProtocol.d.ts +14 -0
- package/cjs/lib/WAUSync/Protocols/UsyncLIDProtocol.js +53 -0
- package/cjs/lib/WAUSync/Protocols/index.d.ts +5 -0
- package/cjs/lib/WAUSync/Protocols/index.js +29 -0
- package/cjs/lib/WAUSync/USyncQuery.d.ts +20 -0
- package/cjs/lib/WAUSync/USyncQuery.js +113 -0
- package/cjs/lib/WAUSync/USyncUser.d.ts +16 -0
- package/cjs/lib/WAUSync/USyncUser.js +56 -0
- package/cjs/lib/WAUSync/index.d.ts +3 -0
- package/cjs/lib/WAUSync/index.js +25 -0
- package/cjs/lib/index.d.ts +11 -0
- package/cjs/lib/index.js +56 -0
- package/cjs/package.json +3 -0
- package/engine-requirements.js +12 -0
- package/lib/Addon/http-error.d.ts +18 -0
- package/lib/Addon/http-error.js +40 -0
- package/lib/Addon/index.d.ts +3 -0
- package/lib/Addon/index.js +4 -0
- package/lib/Addon/keyed-db.d.ts +14 -0
- package/lib/Addon/keyed-db.js +241 -0
- package/lib/Addon/link-preview.d.ts +15 -0
- package/lib/Addon/link-preview.js +79 -0
- package/lib/Defaults/index.d.ts +184 -0
- package/lib/Defaults/index.js +181 -0
- package/lib/Signal/Group/ciphertext-message.d.ts +9 -0
- package/lib/Signal/Group/ciphertext-message.js +11 -0
- package/lib/Signal/Group/group-cipher.d.ts +10 -0
- package/lib/Signal/Group/group-cipher.js +81 -0
- package/lib/Signal/Group/group-session-builder.d.ts +7 -0
- package/lib/Signal/Group/group-session-builder.js +29 -0
- package/lib/Signal/Group/index.d.ts +11 -0
- package/lib/Signal/Group/index.js +11 -0
- package/lib/Signal/Group/keyhelper.d.ts +6 -0
- package/lib/Signal/Group/keyhelper.js +17 -0
- package/lib/Signal/Group/sender-chain-key.d.ts +13 -0
- package/lib/Signal/Group/sender-chain-key.js +25 -0
- package/lib/Signal/Group/sender-key-distribution-message.d.ts +16 -0
- package/lib/Signal/Group/sender-key-distribution-message.js +62 -0
- package/lib/Signal/Group/sender-key-message.d.ts +18 -0
- package/lib/Signal/Group/sender-key-message.js +65 -0
- package/lib/Signal/Group/sender-key-name.d.ts +11 -0
- package/lib/Signal/Group/sender-key-name.js +47 -0
- package/lib/Signal/Group/sender-key-record.d.ts +12 -0
- package/lib/Signal/Group/sender-key-record.js +40 -0
- package/lib/Signal/Group/sender-key-state.d.ts +16 -0
- package/lib/Signal/Group/sender-key-state.js +83 -0
- package/lib/Signal/Group/sender-message-key.d.ts +11 -0
- package/lib/Signal/Group/sender-message-key.js +25 -0
- package/lib/Signal/libsignal.d.ts +54 -0
- package/lib/Signal/libsignal.js +426 -0
- package/lib/Signal/lid-mapping.d.ts +20 -0
- package/lib/Signal/lid-mapping.js +274 -0
- package/lib/Socket/Client/index.d.ts +2 -0
- package/lib/Socket/Client/index.js +2 -0
- package/lib/Socket/Client/types.d.ts +5 -0
- package/lib/Socket/Client/types.js +10 -0
- package/lib/Socket/Client/websocket.d.ts +12 -0
- package/lib/Socket/Client/websocket.js +119 -0
- package/lib/Socket/business.d.ts +387 -0
- package/lib/Socket/business.js +379 -0
- package/lib/Socket/chats.d.ts +144 -0
- package/lib/Socket/chats.js +1216 -0
- package/lib/Socket/communities.d.ts +554 -0
- package/lib/Socket/communities.js +431 -0
- package/lib/Socket/groups.d.ts +286 -0
- package/lib/Socket/groups.js +347 -0
- package/lib/Socket/index.d.ts +522 -0
- package/lib/Socket/index.js +11 -0
- package/lib/Socket/messages-recv.d.ts +326 -0
- package/lib/Socket/messages-recv.js +1822 -0
- package/lib/Socket/messages-send.d.ts +321 -0
- package/lib/Socket/messages-send.js +1378 -0
- package/lib/Socket/mex.d.ts +1 -0
- package/lib/Socket/mex.js +41 -0
- package/lib/Socket/newsletter.d.ts +283 -0
- package/lib/Socket/newsletter.js +225 -0
- package/lib/Socket/socket.d.ts +61 -0
- package/lib/Socket/socket.js +992 -0
- package/lib/Store/index.d.ts +3 -0
- package/lib/Store/index.js +3 -0
- package/lib/Store/make-in-memory-store.d.ts +63 -0
- package/lib/Store/make-in-memory-store.js +419 -0
- package/lib/Store/make-ordered-dictionary.d.ts +12 -0
- package/lib/Store/make-ordered-dictionary.js +78 -0
- package/lib/Store/object-repository.d.ts +10 -0
- package/lib/Store/object-repository.js +23 -0
- package/lib/Transport/crypto.d.ts +6 -0
- package/lib/Transport/crypto.js +61 -0
- package/lib/Transport/curve.d.ts +8 -0
- package/lib/Transport/curve.js +66 -0
- package/lib/Transport/index.d.ts +16 -0
- package/lib/Transport/index.js +9 -0
- package/lib/Transport/internals.d.ts +57 -0
- package/lib/Transport/internals.js +155 -0
- package/lib/Transport/session-builder.d.ts +40 -0
- package/lib/Transport/session-builder.js +143 -0
- package/lib/Transport/session-cipher.d.ts +26 -0
- package/lib/Transport/session-cipher.js +301 -0
- package/lib/Transport/session-record.d.ts +55 -0
- package/lib/Transport/session-record.js +272 -0
- package/lib/Types/Auth.d.ts +1 -0
- package/lib/Types/Auth.js +1 -0
- package/lib/Types/Bussines.d.ts +1 -0
- package/lib/Types/Bussines.js +1 -0
- package/lib/Types/Call.d.ts +1 -0
- package/lib/Types/Call.js +1 -0
- package/lib/Types/Chat.d.ts +1 -0
- package/lib/Types/Chat.js +7 -0
- package/lib/Types/Contact.d.ts +1 -0
- package/lib/Types/Contact.js +1 -0
- package/lib/Types/Events.d.ts +1 -0
- package/lib/Types/Events.js +1 -0
- package/lib/Types/GroupMetadata.d.ts +1 -0
- package/lib/Types/GroupMetadata.js +1 -0
- package/lib/Types/Label.d.ts +2 -0
- package/lib/Types/Label.js +24 -0
- package/lib/Types/LabelAssociation.d.ts +2 -0
- package/lib/Types/LabelAssociation.js +6 -0
- package/lib/Types/Message.d.ts +11 -0
- package/lib/Types/Message.js +17 -0
- package/lib/Types/Mex.d.ts +2 -0
- package/lib/Types/Mex.js +38 -0
- package/lib/Types/Product.d.ts +1 -0
- package/lib/Types/Product.js +1 -0
- package/lib/Types/RichType.d.ts +2 -0
- package/lib/Types/RichType.js +22 -0
- package/lib/Types/Signal.d.ts +1 -0
- package/lib/Types/Signal.js +1 -0
- package/lib/Types/Socket.d.ts +1 -0
- package/lib/Types/Socket.js +1 -0
- package/lib/Types/State.d.ts +5 -0
- package/lib/Types/State.js +54 -0
- package/lib/Types/USync.d.ts +1 -0
- package/lib/Types/USync.js +1 -0
- package/lib/Types/index.d.ts +13 -0
- package/lib/Types/index.js +25 -0
- package/lib/Utils/auth-utils.d.ts +58 -0
- package/lib/Utils/auth-utils.js +316 -0
- package/lib/Utils/browser-utils.d.ts +9 -0
- package/lib/Utils/browser-utils.js +28 -0
- package/lib/Utils/business.d.ts +49 -0
- package/lib/Utils/business.js +230 -0
- package/lib/Utils/chat-utils.d.ts +408 -0
- package/lib/Utils/chat-utils.js +871 -0
- package/lib/Utils/companion-reg-client-utils.d.ts +4 -0
- package/lib/Utils/companion-reg-client-utils.js +39 -0
- package/lib/Utils/crypto.d.ts +39 -0
- package/lib/Utils/crypto.js +117 -0
- package/lib/Utils/decode-wa-message.d.ts +83 -0
- package/lib/Utils/decode-wa-message.js +316 -0
- package/lib/Utils/event-buffer.d.ts +12 -0
- package/lib/Utils/event-buffer.js +621 -0
- package/lib/Utils/generics.d.ts +63 -0
- package/lib/Utils/generics.js +394 -0
- package/lib/Utils/history.d.ts +75 -0
- package/lib/Utils/history.js +133 -0
- package/lib/Utils/identity-change-handler.d.ts +13 -0
- package/lib/Utils/identity-change-handler.js +48 -0
- package/lib/Utils/index.d.ts +24 -0
- package/lib/Utils/index.js +24 -0
- package/lib/Utils/link-preview.d.ts +13 -0
- package/lib/Utils/link-preview.js +73 -0
- package/lib/Utils/logger.d.ts +12 -0
- package/lib/Utils/logger.js +12 -0
- package/lib/Utils/lt-hash.d.ts +6 -0
- package/lib/Utils/lt-hash.js +7 -0
- package/lib/Utils/make-mutex.d.ts +6 -0
- package/lib/Utils/make-mutex.js +32 -0
- package/lib/Utils/message-retry-manager.d.ts +79 -0
- package/lib/Utils/message-retry-manager.js +259 -0
- package/lib/Utils/messages-media.d.ts +134 -0
- package/lib/Utils/messages-media.js +802 -0
- package/lib/Utils/messages.d.ts +47 -0
- package/lib/Utils/messages.js +1911 -0
- package/lib/Utils/noise-handler.d.ts +20 -0
- package/lib/Utils/noise-handler.js +200 -0
- package/lib/Utils/offline-node-processor.d.ts +10 -0
- package/lib/Utils/offline-node-processor.js +40 -0
- package/lib/Utils/pre-key-manager.d.ts +25 -0
- package/lib/Utils/pre-key-manager.js +105 -0
- package/lib/Utils/process-message.d.ts +83 -0
- package/lib/Utils/process-message.js +748 -0
- package/lib/Utils/reporting-utils.d.ts +12 -0
- package/lib/Utils/reporting-utils.js +257 -0
- package/lib/Utils/rich-message-utils.d.ts +48 -0
- package/lib/Utils/rich-message-utils.js +369 -0
- package/lib/Utils/signal.d.ts +82 -0
- package/lib/Utils/signal.js +200 -0
- package/lib/Utils/stanza-ack.d.ts +16 -0
- package/lib/Utils/stanza-ack.js +37 -0
- package/lib/Utils/sync-action-utils.d.ts +2 -0
- package/lib/Utils/sync-action-utils.js +48 -0
- package/lib/Utils/tc-token-utils.d.ts +29 -0
- package/lib/Utils/tc-token-utils.js +163 -0
- package/lib/Utils/use-multi-file-auth-state.d.ts +10 -0
- package/lib/Utils/use-multi-file-auth-state.js +116 -0
- package/lib/Utils/use-single-file-auth-state.d.ts +11 -0
- package/lib/Utils/use-single-file-auth-state.js +94 -0
- package/lib/Utils/use-sqlite-auth-state.d.ts +11 -0
- package/lib/Utils/use-sqlite-auth-state.js +109 -0
- package/lib/Utils/validate-connection.d.ts +44 -0
- package/lib/Utils/validate-connection.js +210 -0
- package/lib/WABinary/constants.d.ts +61 -0
- package/lib/WABinary/constants.js +1466 -0
- package/lib/WABinary/decode.d.ts +9 -0
- package/lib/WABinary/decode.js +261 -0
- package/lib/WABinary/encode.d.ts +2 -0
- package/lib/WABinary/encode.js +219 -0
- package/lib/WABinary/generic-utils.d.ts +79 -0
- package/lib/WABinary/generic-utils.js +228 -0
- package/lib/WABinary/index.d.ts +5 -0
- package/lib/WABinary/index.js +5 -0
- package/lib/WABinary/jid-utils.d.ts +28 -0
- package/lib/WABinary/jid-utils.js +95 -0
- package/lib/WABinary/types.d.ts +1 -0
- package/lib/WABinary/types.js +1 -0
- package/lib/WACrypto/appstate-keys.js +26 -0
- package/lib/WACrypto/curves/constants.js +12 -0
- package/lib/WACrypto/hkdf.js +27 -0
- package/lib/WACrypto/index.js +20 -0
- package/lib/WACrypto/lthash.js +54 -0
- package/lib/WACrypto/math/constants.js +24 -0
- package/lib/WACrypto/math/edwards.js +194 -0
- package/lib/WACrypto/math/fe.js +698 -0
- package/lib/WACrypto/math/le.js +23 -0
- package/lib/WACrypto/math/mod.js +15 -0
- package/lib/WACrypto/util/bytes.js +339 -0
- package/lib/WACrypto/x25519.js +145 -0
- package/lib/WACrypto/xeddsa.js +92 -0
- package/lib/WAM/BinaryInfo.d.ts +7 -0
- package/lib/WAM/BinaryInfo.js +9 -0
- package/lib/WAM/constants.d.ts +34926 -0
- package/lib/WAM/constants.js +22852 -0
- package/lib/WAM/encode.d.ts +1 -0
- package/lib/WAM/encode.js +149 -0
- package/lib/WAM/index.d.ts +3 -0
- package/lib/WAM/index.js +3 -0
- package/lib/WAUSync/Protocols/USyncContactProtocol.d.ts +36 -0
- package/lib/WAUSync/Protocols/USyncContactProtocol.js +51 -0
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.d.ts +22 -0
- package/lib/WAUSync/Protocols/USyncDeviceProtocol.js +53 -0
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.d.ts +12 -0
- package/lib/WAUSync/Protocols/USyncDisappearingModeProtocol.js +26 -0
- package/lib/WAUSync/Protocols/USyncStatusProtocol.d.ts +12 -0
- package/lib/WAUSync/Protocols/USyncStatusProtocol.js +37 -0
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.d.ts +9 -0
- package/lib/WAUSync/Protocols/USyncUsernameProtocol.js +24 -0
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.d.ts +38 -0
- package/lib/WAUSync/Protocols/UsyncBotProfileProtocol.js +50 -0
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.d.ts +14 -0
- package/lib/WAUSync/Protocols/UsyncLIDProtocol.js +28 -0
- package/lib/WAUSync/Protocols/index.d.ts +5 -0
- package/lib/WAUSync/Protocols/index.js +5 -0
- package/lib/WAUSync/USyncQuery.d.ts +20 -0
- package/lib/WAUSync/USyncQuery.js +97 -0
- package/lib/WAUSync/USyncUser.d.ts +16 -0
- package/lib/WAUSync/USyncUser.js +30 -0
- package/lib/WAUSync/index.d.ts +3 -0
- package/lib/WAUSync/index.js +3 -0
- package/lib/index.d.ts +11 -0
- package/lib/index.js +11 -0
- package/package.json +79 -5
|
@@ -0,0 +1,252 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var generic_utils_exports = {};
|
|
19
|
+
__export(generic_utils_exports, {
|
|
20
|
+
assertNodeErrorFree: () => assertNodeErrorFree,
|
|
21
|
+
binaryNodeToString: () => binaryNodeToString,
|
|
22
|
+
getAllBinaryNodeChildren: () => getAllBinaryNodeChildren,
|
|
23
|
+
getBinaryNodeChild: () => getBinaryNodeChild,
|
|
24
|
+
getBinaryNodeChildBuffer: () => getBinaryNodeChildBuffer,
|
|
25
|
+
getBinaryNodeChildString: () => getBinaryNodeChildString,
|
|
26
|
+
getBinaryNodeChildUInt: () => getBinaryNodeChildUInt,
|
|
27
|
+
getBinaryNodeChildren: () => getBinaryNodeChildren,
|
|
28
|
+
getBinaryNodeMessages: () => getBinaryNodeMessages,
|
|
29
|
+
getBizBinaryNode: () => getBizBinaryNode,
|
|
30
|
+
reduceBinaryNodeToDictionary: () => reduceBinaryNodeToDictionary
|
|
31
|
+
});
|
|
32
|
+
module.exports = __toCommonJS(generic_utils_exports);
|
|
33
|
+
var import_node_crypto = require("node:crypto");
|
|
34
|
+
var import_Addon = require("../Addon/index.js");
|
|
35
|
+
var import_WAProto = require("../../WAProto/index.js");
|
|
36
|
+
const indexCache = /* @__PURE__ */ new WeakMap();
|
|
37
|
+
const getBinaryNodeChildren = (node, childTag) => {
|
|
38
|
+
if (!node || !Array.isArray(node.content))
|
|
39
|
+
return [];
|
|
40
|
+
let index = indexCache.get(node);
|
|
41
|
+
if (!index) {
|
|
42
|
+
index = /* @__PURE__ */ new Map();
|
|
43
|
+
for (const child of node.content) {
|
|
44
|
+
let arr = index.get(child.tag);
|
|
45
|
+
if (!arr)
|
|
46
|
+
index.set(child.tag, arr = []);
|
|
47
|
+
arr.push(child);
|
|
48
|
+
}
|
|
49
|
+
indexCache.set(node, index);
|
|
50
|
+
}
|
|
51
|
+
return index.get(childTag) || [];
|
|
52
|
+
};
|
|
53
|
+
const getBinaryNodeChild = (node, childTag) => {
|
|
54
|
+
return getBinaryNodeChildren(node, childTag)[0];
|
|
55
|
+
};
|
|
56
|
+
const getAllBinaryNodeChildren = ({ content }) => {
|
|
57
|
+
if (Array.isArray(content)) {
|
|
58
|
+
return content;
|
|
59
|
+
}
|
|
60
|
+
return [];
|
|
61
|
+
};
|
|
62
|
+
const getBinaryNodeChildBuffer = (node, childTag) => {
|
|
63
|
+
const child = getBinaryNodeChild(node, childTag)?.content;
|
|
64
|
+
if (Buffer.isBuffer(child) || child instanceof Uint8Array) {
|
|
65
|
+
return child;
|
|
66
|
+
}
|
|
67
|
+
};
|
|
68
|
+
const getBinaryNodeChildString = (node, childTag) => {
|
|
69
|
+
const child = getBinaryNodeChild(node, childTag)?.content;
|
|
70
|
+
if (Buffer.isBuffer(child) || child instanceof Uint8Array) {
|
|
71
|
+
return Buffer.from(child).toString("utf-8");
|
|
72
|
+
} else if (typeof child === "string") {
|
|
73
|
+
return child;
|
|
74
|
+
}
|
|
75
|
+
};
|
|
76
|
+
const getBinaryNodeChildUInt = (node, childTag, length) => {
|
|
77
|
+
const buff = getBinaryNodeChildBuffer(node, childTag);
|
|
78
|
+
if (buff) {
|
|
79
|
+
return bufferToUInt(buff, length);
|
|
80
|
+
}
|
|
81
|
+
};
|
|
82
|
+
const assertNodeErrorFree = (node) => {
|
|
83
|
+
const errNode = getBinaryNodeChild(node, "error");
|
|
84
|
+
if (errNode) {
|
|
85
|
+
throw new import_Addon.HttpError(errNode.attrs.text || "Unknown error", { data: +errNode.attrs.code });
|
|
86
|
+
}
|
|
87
|
+
};
|
|
88
|
+
const reduceBinaryNodeToDictionary = (node, tag) => {
|
|
89
|
+
const nodes = getBinaryNodeChildren(node, tag);
|
|
90
|
+
const dict = nodes.reduce((dict2, { attrs }) => {
|
|
91
|
+
if (typeof attrs.name === "string") {
|
|
92
|
+
dict2[attrs.name] = attrs.value || attrs.config_value;
|
|
93
|
+
} else {
|
|
94
|
+
dict2[attrs.config_code] = attrs.value || attrs.config_value;
|
|
95
|
+
}
|
|
96
|
+
return dict2;
|
|
97
|
+
}, {});
|
|
98
|
+
return dict;
|
|
99
|
+
};
|
|
100
|
+
const getBinaryNodeMessages = ({ content }) => {
|
|
101
|
+
const msgs = [];
|
|
102
|
+
if (Array.isArray(content)) {
|
|
103
|
+
for (const item of content) {
|
|
104
|
+
if (item.tag === "message") {
|
|
105
|
+
msgs.push(import_WAProto.proto.WebMessageInfo.decode(item.content).toJSON());
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
return msgs;
|
|
110
|
+
};
|
|
111
|
+
function bufferToUInt(e, t) {
|
|
112
|
+
let a = 0;
|
|
113
|
+
for (let i = 0; i < t; i++) {
|
|
114
|
+
a = 256 * a + e[i];
|
|
115
|
+
}
|
|
116
|
+
return a;
|
|
117
|
+
}
|
|
118
|
+
const tabs = (n) => " ".repeat(n);
|
|
119
|
+
function binaryNodeToString(node, i = 0) {
|
|
120
|
+
if (!node) {
|
|
121
|
+
return node;
|
|
122
|
+
}
|
|
123
|
+
if (typeof node === "string") {
|
|
124
|
+
return tabs(i) + node;
|
|
125
|
+
}
|
|
126
|
+
if (node instanceof Uint8Array) {
|
|
127
|
+
return tabs(i) + Buffer.from(node).toString("hex");
|
|
128
|
+
}
|
|
129
|
+
if (Array.isArray(node)) {
|
|
130
|
+
return node.map((x) => tabs(i + 1) + binaryNodeToString(x, i + 1)).join("\n");
|
|
131
|
+
}
|
|
132
|
+
const children = binaryNodeToString(node.content, i + 1);
|
|
133
|
+
const tag = `<${node.tag} ${Object.entries(node.attrs || {}).filter(([, v]) => v !== void 0).map(([k, v]) => `${k}='${v}'`).join(" ")}`;
|
|
134
|
+
const content = children ? `>
|
|
135
|
+
${children}
|
|
136
|
+
${tabs(i)}</${node.tag}>` : "/>";
|
|
137
|
+
return tag + content;
|
|
138
|
+
}
|
|
139
|
+
const FLOWS_MAP = {
|
|
140
|
+
mpm: true,
|
|
141
|
+
cta_catalog: true,
|
|
142
|
+
send_location: true,
|
|
143
|
+
call_permission_request: true,
|
|
144
|
+
wa_payment_transaction_details: true,
|
|
145
|
+
automated_greeting_message_view_catalog: true,
|
|
146
|
+
form_message: true,
|
|
147
|
+
payment_key_info: true
|
|
148
|
+
};
|
|
149
|
+
const DECISION_SOURCE_CONTENT = [
|
|
150
|
+
{
|
|
151
|
+
tag: "decision_source",
|
|
152
|
+
attrs: { value: "df" }
|
|
153
|
+
}
|
|
154
|
+
];
|
|
155
|
+
const LIST_TYPE_CONTENT = {
|
|
156
|
+
tag: "list",
|
|
157
|
+
attrs: { v: "2", type: "product_list" }
|
|
158
|
+
};
|
|
159
|
+
const NATIVE_FLOW_ATTRIBUTE = { type: "native_flow", v: "1" };
|
|
160
|
+
const MIXED_NATIVE_FLOW = {
|
|
161
|
+
tag: "interactive",
|
|
162
|
+
attrs: NATIVE_FLOW_ATTRIBUTE,
|
|
163
|
+
content: [
|
|
164
|
+
{
|
|
165
|
+
tag: "native_flow",
|
|
166
|
+
attrs: { v: "9", name: "mixed" }
|
|
167
|
+
}
|
|
168
|
+
]
|
|
169
|
+
};
|
|
170
|
+
const getBizBinaryNode = (message) => {
|
|
171
|
+
const flowMsg = message.interactiveMessage?.nativeFlowMessage;
|
|
172
|
+
const firstButtonName = flowMsg?.buttons?.[0]?.name;
|
|
173
|
+
const qualityContent = {
|
|
174
|
+
tag: "quality_control",
|
|
175
|
+
attrs: {
|
|
176
|
+
decision_id: (0, import_node_crypto.randomBytes)(20).toString("hex"),
|
|
177
|
+
source_type: "third_party"
|
|
178
|
+
},
|
|
179
|
+
content: DECISION_SOURCE_CONTENT
|
|
180
|
+
};
|
|
181
|
+
const bizAttributes = {
|
|
182
|
+
actual_actors: "2",
|
|
183
|
+
host_storage: "2",
|
|
184
|
+
privacy_mode_ts: `${Date.now() / 1e3 | 0}`
|
|
185
|
+
};
|
|
186
|
+
if (firstButtonName === "review_and_pay" || firstButtonName === "payment_info") {
|
|
187
|
+
bizAttributes.native_flow_name = firstButtonName === "review_and_pay" ? "order_details" : firstButtonName;
|
|
188
|
+
return {
|
|
189
|
+
tag: "biz",
|
|
190
|
+
attrs: bizAttributes,
|
|
191
|
+
content: [qualityContent]
|
|
192
|
+
};
|
|
193
|
+
}
|
|
194
|
+
if (firstButtonName && FLOWS_MAP[firstButtonName]) {
|
|
195
|
+
return {
|
|
196
|
+
tag: "biz",
|
|
197
|
+
attrs: bizAttributes,
|
|
198
|
+
content: [
|
|
199
|
+
{
|
|
200
|
+
tag: "interactive",
|
|
201
|
+
attrs: NATIVE_FLOW_ATTRIBUTE,
|
|
202
|
+
content: [
|
|
203
|
+
{
|
|
204
|
+
tag: "native_flow",
|
|
205
|
+
attrs: firstButtonName === "form_message" || firstButtonName === "payment_key_info" ? { name: firstButtonName } : { v: "2", name: firstButtonName }
|
|
206
|
+
}
|
|
207
|
+
]
|
|
208
|
+
},
|
|
209
|
+
qualityContent
|
|
210
|
+
]
|
|
211
|
+
};
|
|
212
|
+
}
|
|
213
|
+
if (flowMsg || message.buttonsMessage || message.templateMessage) {
|
|
214
|
+
return {
|
|
215
|
+
tag: "biz",
|
|
216
|
+
attrs: bizAttributes,
|
|
217
|
+
content: [
|
|
218
|
+
MIXED_NATIVE_FLOW,
|
|
219
|
+
qualityContent
|
|
220
|
+
]
|
|
221
|
+
};
|
|
222
|
+
}
|
|
223
|
+
if (message.listMessage) {
|
|
224
|
+
return {
|
|
225
|
+
tag: "biz",
|
|
226
|
+
attrs: bizAttributes,
|
|
227
|
+
content: [
|
|
228
|
+
LIST_TYPE_CONTENT,
|
|
229
|
+
qualityContent
|
|
230
|
+
]
|
|
231
|
+
};
|
|
232
|
+
}
|
|
233
|
+
return {
|
|
234
|
+
tag: "biz",
|
|
235
|
+
attrs: bizAttributes,
|
|
236
|
+
content: [qualityContent]
|
|
237
|
+
};
|
|
238
|
+
};
|
|
239
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
240
|
+
0 && (module.exports = {
|
|
241
|
+
assertNodeErrorFree,
|
|
242
|
+
binaryNodeToString,
|
|
243
|
+
getAllBinaryNodeChildren,
|
|
244
|
+
getBinaryNodeChild,
|
|
245
|
+
getBinaryNodeChildBuffer,
|
|
246
|
+
getBinaryNodeChildString,
|
|
247
|
+
getBinaryNodeChildUInt,
|
|
248
|
+
getBinaryNodeChildren,
|
|
249
|
+
getBinaryNodeMessages,
|
|
250
|
+
getBizBinaryNode,
|
|
251
|
+
reduceBinaryNodeToDictionary
|
|
252
|
+
});
|
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __copyProps = (to, from, except, desc) => {
|
|
6
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
7
|
+
for (let key of __getOwnPropNames(from))
|
|
8
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
9
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
10
|
+
}
|
|
11
|
+
return to;
|
|
12
|
+
};
|
|
13
|
+
var __reExport = (target, mod, secondTarget) => (__copyProps(target, mod, "default"), secondTarget && __copyProps(secondTarget, mod, "default"));
|
|
14
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
15
|
+
var index_exports = {};
|
|
16
|
+
module.exports = __toCommonJS(index_exports);
|
|
17
|
+
__reExport(index_exports, require("./encode.js"), module.exports);
|
|
18
|
+
__reExport(index_exports, require("./decode.js"), module.exports);
|
|
19
|
+
__reExport(index_exports, require("./generic-utils.js"), module.exports);
|
|
20
|
+
__reExport(index_exports, require("./jid-utils.js"), module.exports);
|
|
21
|
+
__reExport(index_exports, require("./types.js"), module.exports);
|
|
22
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
23
|
+
0 && (module.exports = {
|
|
24
|
+
...require("./encode.js"),
|
|
25
|
+
...require("./decode.js"),
|
|
26
|
+
...require("./generic-utils.js"),
|
|
27
|
+
...require("./jid-utils.js"),
|
|
28
|
+
...require("./types.js")
|
|
29
|
+
});
|
|
@@ -0,0 +1,28 @@
|
|
|
1
|
+
export const S_WHATSAPP_NET: "@s.whatsapp.net";
|
|
2
|
+
export const OFFICIAL_BIZ_JID: "16505361212@c.us";
|
|
3
|
+
export const SERVER_JID: "server@c.us";
|
|
4
|
+
export const PSA_WID: "0@c.us";
|
|
5
|
+
export const STORIES_JID: "status@broadcast";
|
|
6
|
+
export const META_AI_JID: "13135550002@c.us";
|
|
7
|
+
export const WAJIDDomains: any;
|
|
8
|
+
export function getServerFromDomainType(initialServer: any, domainType: any): any;
|
|
9
|
+
export function jidEncode(user: any, server: any, device: any, agent: any): string;
|
|
10
|
+
export function jidDecode(jid: any): {
|
|
11
|
+
server: any;
|
|
12
|
+
user: any;
|
|
13
|
+
domainType: any;
|
|
14
|
+
device: number | undefined;
|
|
15
|
+
} | undefined;
|
|
16
|
+
export function areJidsSameUser(jid1: any, jid2: any): boolean;
|
|
17
|
+
export function isJidMetaAI(jid: any): any;
|
|
18
|
+
export function isPnUser(jid: any): any;
|
|
19
|
+
export function isLidUser(jid: any): any;
|
|
20
|
+
export function isJidBroadcast(jid: any): any;
|
|
21
|
+
export function isJidGroup(jid: any): any;
|
|
22
|
+
export function isJidStatusBroadcast(jid: any): boolean;
|
|
23
|
+
export function isJidNewsletter(jid: any): any;
|
|
24
|
+
export function isHostedPnUser(jid: any): any;
|
|
25
|
+
export function isHostedLidUser(jid: any): any;
|
|
26
|
+
export function isJidBot(jid: any): any;
|
|
27
|
+
export function jidNormalizedUser(jid: any): string;
|
|
28
|
+
export function transferDevice(fromJid: any, toJid: any): string;
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var jid_utils_exports = {};
|
|
19
|
+
__export(jid_utils_exports, {
|
|
20
|
+
META_AI_JID: () => META_AI_JID,
|
|
21
|
+
OFFICIAL_BIZ_JID: () => OFFICIAL_BIZ_JID,
|
|
22
|
+
PSA_WID: () => PSA_WID,
|
|
23
|
+
SERVER_JID: () => SERVER_JID,
|
|
24
|
+
STORIES_JID: () => STORIES_JID,
|
|
25
|
+
S_WHATSAPP_NET: () => S_WHATSAPP_NET,
|
|
26
|
+
WAJIDDomains: () => WAJIDDomains,
|
|
27
|
+
areJidsSameUser: () => areJidsSameUser,
|
|
28
|
+
getServerFromDomainType: () => getServerFromDomainType,
|
|
29
|
+
isHostedLidUser: () => isHostedLidUser,
|
|
30
|
+
isHostedPnUser: () => isHostedPnUser,
|
|
31
|
+
isJidBot: () => isJidBot,
|
|
32
|
+
isJidBroadcast: () => isJidBroadcast,
|
|
33
|
+
isJidGroup: () => isJidGroup,
|
|
34
|
+
isJidMetaAI: () => isJidMetaAI,
|
|
35
|
+
isJidNewsletter: () => isJidNewsletter,
|
|
36
|
+
isJidStatusBroadcast: () => isJidStatusBroadcast,
|
|
37
|
+
isLidUser: () => isLidUser,
|
|
38
|
+
isPnUser: () => isPnUser,
|
|
39
|
+
jidDecode: () => jidDecode,
|
|
40
|
+
jidEncode: () => jidEncode,
|
|
41
|
+
jidNormalizedUser: () => jidNormalizedUser,
|
|
42
|
+
transferDevice: () => transferDevice
|
|
43
|
+
});
|
|
44
|
+
module.exports = __toCommonJS(jid_utils_exports);
|
|
45
|
+
const S_WHATSAPP_NET = "@s.whatsapp.net";
|
|
46
|
+
const OFFICIAL_BIZ_JID = "16505361212@c.us";
|
|
47
|
+
const SERVER_JID = "server@c.us";
|
|
48
|
+
const PSA_WID = "0@c.us";
|
|
49
|
+
const STORIES_JID = "status@broadcast";
|
|
50
|
+
const META_AI_JID = "13135550002@c.us";
|
|
51
|
+
var WAJIDDomains;
|
|
52
|
+
(function(WAJIDDomains2) {
|
|
53
|
+
WAJIDDomains2[WAJIDDomains2["WHATSAPP"] = 0] = "WHATSAPP";
|
|
54
|
+
WAJIDDomains2[WAJIDDomains2["LID"] = 1] = "LID";
|
|
55
|
+
WAJIDDomains2[WAJIDDomains2["HOSTED"] = 128] = "HOSTED";
|
|
56
|
+
WAJIDDomains2[WAJIDDomains2["HOSTED_LID"] = 129] = "HOSTED_LID";
|
|
57
|
+
})(WAJIDDomains || (WAJIDDomains = {}));
|
|
58
|
+
const getServerFromDomainType = (initialServer, domainType) => {
|
|
59
|
+
switch (domainType) {
|
|
60
|
+
case WAJIDDomains.LID:
|
|
61
|
+
return "lid";
|
|
62
|
+
case WAJIDDomains.HOSTED:
|
|
63
|
+
return "hosted";
|
|
64
|
+
case WAJIDDomains.HOSTED_LID:
|
|
65
|
+
return "hosted.lid";
|
|
66
|
+
case WAJIDDomains.WHATSAPP:
|
|
67
|
+
default:
|
|
68
|
+
return initialServer;
|
|
69
|
+
}
|
|
70
|
+
};
|
|
71
|
+
const jidEncode = (user, server, device, agent) => {
|
|
72
|
+
return `${user || ""}${!!agent ? `_${agent}` : ""}${!!device ? `:${device}` : ""}@${server || "lid"}`;
|
|
73
|
+
};
|
|
74
|
+
const jidDecode = (jid) => {
|
|
75
|
+
const sepIdx = typeof jid === "string" ? jid.indexOf("@") : -1;
|
|
76
|
+
if (sepIdx < 0) {
|
|
77
|
+
return void 0;
|
|
78
|
+
}
|
|
79
|
+
const server = jid.slice(sepIdx + 1);
|
|
80
|
+
const userCombined = jid.slice(0, sepIdx);
|
|
81
|
+
const [userAgent, device] = userCombined.split(":");
|
|
82
|
+
const [user, agent] = userAgent.split("_");
|
|
83
|
+
let domainType = WAJIDDomains.WHATSAPP;
|
|
84
|
+
if (server === "lid") {
|
|
85
|
+
domainType = WAJIDDomains.LID;
|
|
86
|
+
} else if (server === "hosted") {
|
|
87
|
+
domainType = WAJIDDomains.HOSTED;
|
|
88
|
+
} else if (server === "hosted.lid") {
|
|
89
|
+
domainType = WAJIDDomains.HOSTED_LID;
|
|
90
|
+
} else if (agent) {
|
|
91
|
+
domainType = parseInt(agent);
|
|
92
|
+
}
|
|
93
|
+
return {
|
|
94
|
+
server,
|
|
95
|
+
user,
|
|
96
|
+
domainType,
|
|
97
|
+
device: device ? +device : void 0
|
|
98
|
+
};
|
|
99
|
+
};
|
|
100
|
+
const areJidsSameUser = (jid1, jid2) => jidDecode(jid1)?.user === jidDecode(jid2)?.user;
|
|
101
|
+
const isJidMetaAI = (jid) => jid?.endsWith("@bot");
|
|
102
|
+
const isPnUser = (jid) => jid?.endsWith("@s.whatsapp.net");
|
|
103
|
+
const isLidUser = (jid) => jid?.endsWith("@lid");
|
|
104
|
+
const isJidBroadcast = (jid) => jid?.endsWith("@broadcast");
|
|
105
|
+
const isJidGroup = (jid) => jid?.endsWith("@g.us");
|
|
106
|
+
const isJidStatusBroadcast = (jid) => jid === "status@broadcast";
|
|
107
|
+
const isJidNewsletter = (jid) => jid?.endsWith("@newsletter");
|
|
108
|
+
const isHostedPnUser = (jid) => jid?.endsWith("@hosted");
|
|
109
|
+
const isHostedLidUser = (jid) => jid?.endsWith("@hosted.lid");
|
|
110
|
+
const botRegexp = /^1313555\d{4}$|^131655500\d{2}$/;
|
|
111
|
+
const isJidBot = (jid) => jid && botRegexp.test(jid.split("@")[0]) && jid.endsWith("@c.us");
|
|
112
|
+
const jidNormalizedUser = (jid) => {
|
|
113
|
+
const result = jidDecode(jid);
|
|
114
|
+
if (!result) {
|
|
115
|
+
return "";
|
|
116
|
+
}
|
|
117
|
+
const { user, server } = result;
|
|
118
|
+
return jidEncode(user, server === "c.us" ? "s.whatsapp.net" : server);
|
|
119
|
+
};
|
|
120
|
+
const transferDevice = (fromJid, toJid) => {
|
|
121
|
+
const fromDecoded = jidDecode(fromJid);
|
|
122
|
+
const deviceId = fromDecoded?.device || 0;
|
|
123
|
+
const { server, user } = jidDecode(toJid);
|
|
124
|
+
return jidEncode(user, server, deviceId);
|
|
125
|
+
};
|
|
126
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
127
|
+
0 && (module.exports = {
|
|
128
|
+
META_AI_JID,
|
|
129
|
+
OFFICIAL_BIZ_JID,
|
|
130
|
+
PSA_WID,
|
|
131
|
+
SERVER_JID,
|
|
132
|
+
STORIES_JID,
|
|
133
|
+
S_WHATSAPP_NET,
|
|
134
|
+
WAJIDDomains,
|
|
135
|
+
areJidsSameUser,
|
|
136
|
+
getServerFromDomainType,
|
|
137
|
+
isHostedLidUser,
|
|
138
|
+
isHostedPnUser,
|
|
139
|
+
isJidBot,
|
|
140
|
+
isJidBroadcast,
|
|
141
|
+
isJidGroup,
|
|
142
|
+
isJidMetaAI,
|
|
143
|
+
isJidNewsletter,
|
|
144
|
+
isJidStatusBroadcast,
|
|
145
|
+
isLidUser,
|
|
146
|
+
isPnUser,
|
|
147
|
+
jidDecode,
|
|
148
|
+
jidEncode,
|
|
149
|
+
jidNormalizedUser,
|
|
150
|
+
transferDevice
|
|
151
|
+
});
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export {};
|
|
@@ -0,0 +1,23 @@
|
|
|
1
|
+
var __create = Object.create;
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
6
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
|
+
var __copyProps = (to, from, except, desc) => {
|
|
8
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
9
|
+
for (let key of __getOwnPropNames(from))
|
|
10
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
11
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
12
|
+
}
|
|
13
|
+
return to;
|
|
14
|
+
};
|
|
15
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
16
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
17
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
18
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
19
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
20
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
21
|
+
mod
|
|
22
|
+
));
|
|
23
|
+
var constants = __toESM(require("./constants.js"));
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var appstate_keys_exports = {};
|
|
19
|
+
__export(appstate_keys_exports, {
|
|
20
|
+
expandAppStateKeys: () => expandAppStateKeys
|
|
21
|
+
});
|
|
22
|
+
module.exports = __toCommonJS(appstate_keys_exports);
|
|
23
|
+
var import_hkdf = require("./hkdf.js");
|
|
24
|
+
const MUTATION_KEYS_INFO = "WhatsApp Mutation Keys";
|
|
25
|
+
const DERIVED_KEY_LENGTH = 160;
|
|
26
|
+
function expandAppStateKeys(keydata) {
|
|
27
|
+
const expanded = (0, import_hkdf.hkdf)(keydata, DERIVED_KEY_LENGTH, { info: MUTATION_KEYS_INFO });
|
|
28
|
+
return {
|
|
29
|
+
indexKey: expanded.subarray(0, 32),
|
|
30
|
+
valueEncryptionKey: expanded.subarray(32, 64),
|
|
31
|
+
valueMacKey: expanded.subarray(64, 96),
|
|
32
|
+
snapshotMacKey: expanded.subarray(96, 128),
|
|
33
|
+
patchMacKey: expanded.subarray(128, 160)
|
|
34
|
+
};
|
|
35
|
+
}
|
|
36
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
37
|
+
0 && (module.exports = {
|
|
38
|
+
expandAppStateKeys
|
|
39
|
+
});
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var constants_exports = {};
|
|
19
|
+
__export(constants_exports, {
|
|
20
|
+
ED25519_PKCS8_PREFIX: () => ED25519_PKCS8_PREFIX,
|
|
21
|
+
ED25519_SPKI_PREFIX: () => ED25519_SPKI_PREFIX,
|
|
22
|
+
X25519_PKCS8_PREFIX: () => X25519_PKCS8_PREFIX,
|
|
23
|
+
X25519_SPKI_PREFIX: () => X25519_SPKI_PREFIX
|
|
24
|
+
});
|
|
25
|
+
module.exports = __toCommonJS(constants_exports);
|
|
26
|
+
var import_bytes = require("../util/bytes.js");
|
|
27
|
+
const X25519_PKCS8_PREFIX = (0, import_bytes.hexToBytes)("302e020100300506032b656e04220420");
|
|
28
|
+
const X25519_SPKI_PREFIX = (0, import_bytes.hexToBytes)("302a300506032b656e032100");
|
|
29
|
+
const ED25519_PKCS8_PREFIX = (0, import_bytes.hexToBytes)("302e020100300506032b657004220420");
|
|
30
|
+
const ED25519_SPKI_PREFIX = (0, import_bytes.hexToBytes)("302a300506032b6570032100");
|
|
31
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
32
|
+
0 && (module.exports = {
|
|
33
|
+
ED25519_PKCS8_PREFIX,
|
|
34
|
+
ED25519_SPKI_PREFIX,
|
|
35
|
+
X25519_PKCS8_PREFIX,
|
|
36
|
+
X25519_SPKI_PREFIX
|
|
37
|
+
});
|
|
@@ -0,0 +1,38 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var hkdf_exports = {};
|
|
19
|
+
__export(hkdf_exports, {
|
|
20
|
+
hkdf: () => hkdf,
|
|
21
|
+
md5: () => md5
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(hkdf_exports);
|
|
24
|
+
var import_node_crypto = require("node:crypto");
|
|
25
|
+
function md5(buffer) {
|
|
26
|
+
return (0, import_node_crypto.createHash)("md5").update(buffer).digest();
|
|
27
|
+
}
|
|
28
|
+
function hkdf(buffer, expandedLength, info = {}) {
|
|
29
|
+
const options = typeof info === "string" ? { info } : info ?? {};
|
|
30
|
+
const salt = options.salt ?? Buffer.alloc(32);
|
|
31
|
+
const context = Buffer.from(options.info ?? "", "utf8");
|
|
32
|
+
return Buffer.from((0, import_node_crypto.hkdfSync)("sha256", buffer, salt, context, expandedLength));
|
|
33
|
+
}
|
|
34
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
35
|
+
0 && (module.exports = {
|
|
36
|
+
hkdf,
|
|
37
|
+
md5
|
|
38
|
+
});
|
|
@@ -0,0 +1,51 @@
|
|
|
1
|
+
var __defProp = Object.defineProperty;
|
|
2
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
3
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
|
+
var __export = (target, all) => {
|
|
6
|
+
for (var name in all)
|
|
7
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
8
|
+
};
|
|
9
|
+
var __copyProps = (to, from, except, desc) => {
|
|
10
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
11
|
+
for (let key of __getOwnPropNames(from))
|
|
12
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
13
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
14
|
+
}
|
|
15
|
+
return to;
|
|
16
|
+
};
|
|
17
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
18
|
+
var index_exports = {};
|
|
19
|
+
__export(index_exports, {
|
|
20
|
+
LTHashAntiTampering: () => import_lthash.LTHashAntiTampering,
|
|
21
|
+
calculateAgreement: () => import_x25519.calculateAgreement,
|
|
22
|
+
calculateSignature: () => import_xeddsa.calculateSignature,
|
|
23
|
+
clampCurvePrivateKeyInPlace: () => import_x25519.clampCurvePrivateKeyInPlace,
|
|
24
|
+
expandAppStateKeys: () => import_appstate_keys.expandAppStateKeys,
|
|
25
|
+
generateKeyPair: () => import_x25519.generateKeyPair,
|
|
26
|
+
getPublicFromPrivateKey: () => import_x25519.getPublicFromPrivateKey,
|
|
27
|
+
hkdf: () => import_hkdf.hkdf,
|
|
28
|
+
md5: () => import_hkdf.md5,
|
|
29
|
+
montgomeryToEdwardsPublic: () => import_x25519.montgomeryToEdwardsPublic,
|
|
30
|
+
verifySignature: () => import_xeddsa.verifySignature
|
|
31
|
+
});
|
|
32
|
+
module.exports = __toCommonJS(index_exports);
|
|
33
|
+
var import_hkdf = require("./hkdf.js");
|
|
34
|
+
var import_x25519 = require("./x25519.js");
|
|
35
|
+
var import_xeddsa = require("./xeddsa.js");
|
|
36
|
+
var import_lthash = require("./lthash.js");
|
|
37
|
+
var import_appstate_keys = require("./appstate-keys.js");
|
|
38
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
39
|
+
0 && (module.exports = {
|
|
40
|
+
LTHashAntiTampering,
|
|
41
|
+
calculateAgreement,
|
|
42
|
+
calculateSignature,
|
|
43
|
+
clampCurvePrivateKeyInPlace,
|
|
44
|
+
expandAppStateKeys,
|
|
45
|
+
generateKeyPair,
|
|
46
|
+
getPublicFromPrivateKey,
|
|
47
|
+
hkdf,
|
|
48
|
+
md5,
|
|
49
|
+
montgomeryToEdwardsPublic,
|
|
50
|
+
verifySignature
|
|
51
|
+
});
|