mirror of
https://github.com/pyMC-dev/pyMC_Repeater.git
synced 2026-08-06 17:03:32 +02:00
9c6ea0151e
push_post_to_client sent posts as TXT_TYPE_SIGNED_PLAIN (plaintext = timestamp + flags + author_prefix + text) but computed its expected ACK over the plain-DM span (timestamp + attempt byte + text). Signed-plain receivers (firmware BaseChatMesh::onPeerDataRecv, and openhop_core's text handler since it gained signed-message ACKs) reply with sha256(decrypted[0 : 9 + strlen(text)] || client_pubkey)[:4], so the server never recognized any push ACK: every push timed out and the same posts were re-pushed forever (issue #286's repeating 'Push timed out' log and duplicate unread floods). Hash the exact plaintext span that is encrypted and sent, plus the client pubkey. Verified against openhop_core's TextMessageHandler: the ACK it emits for a pushed post now matches the stored pending_ack_crc. Fixes #286