mautrix / imessage

A Matrix-iMessage puppeting bridge
https://go.mau.fi/mautrix-imessage/
GNU Affero General Public License v3.0
332 stars 36 forks source link

Redactions & deletions from the iMessage side of the bridge only work partly #207

Open Philantrop opened 3 months ago

Philantrop commented 3 months ago

I've tested redactions and deletions using the artifact from bae4fc50, available at https://mau.dev/mautrix/imessage/-/jobs/45698/artifacts/browse

Test Results

Test Case Expected Result Observed Result Pass/Fail
1 Text message redacted on Matrix side Text message redacted on Matrix side Pass
2 Image deleted on Matrix side Image deleted on Matrix side Pass
3 Edited message deleted on Matrix side Edited message deleted on Matrix side Pass
4 Text message redacted on iMessage side The Matrix side still shows the unredacted message. Fail
5 Image deleted on iMessage side The image is never deleted on the Matrix side. Fail
6 Edited message deleted on iMessage side Edited message deleted on iMessage side Pass

The respective log entries follow ("foo@bar.de" is a redaction for privacy):

Log Entries for Test Case 4:

2024-04-01T10:45:02+02:00 DBG Received incoming message A98F47B7-6A6F-4EA8-94D9-847E8576C030 in iMessage;-;foo@bar.de () module=iMessage
2024-04-01T10:45:02+02:00 DBG Handled message in 125.67µs (queued: 0m/0r/0t/0ch/0ct/0s/0b) module=iMessage
2024-04-01T10:45:02+02:00 DBG Ignoring duplicate message A98F47B7-6A6F-4EA8-94D9-847E8576C030 portal_guid=iMessage;-;foo@bar.de
2024-04-01T10:45:02+02:00 DBG Handled iMessage in 3.057294ms (queued: 0i/0r/0m/0s) portal_guid=iMessage;-;foo@bar.de

Log Entries for Test Case 5:

2024-04-01T10:49:05+02:00 DBG Request completed as_user_id=@m-imessage_foo=40bar.de:mailstation.de duration=37.426096 method=PUT req_body={"timeout":60000,"typing":false} req_id=395 response_length=2 response_mime=application/json status_code=200 url=https://mailstation.de/_matrix/client/v3/rooms/%21WDQqlwEZXDoMWyJCbq:mailstation.de/typing/@m-imessage_foo=40bar.de:mailstation.de?user_id=%40m-imessage_foo%3D40bar.de%3Amailstation.de
2024-04-01T10:49:05+02:00 DBG Handled typing notification in 37.701096ms (queued: 0m/0r/0t/0ch/0ct/0s/0b) module=iMessage
joshuafhiggins commented 3 months ago

Is this happening on the latest BlueBubbles Server version, 1.9.6?

Philantrop commented 3 months ago

Yes, indeed.

joshuafhiggins commented 2 months ago

5 Image deleted on iMessage side The image is never deleted on the Matrix side. Fail

This issue appears to be an upstream problem with BlueBubbles. I'm gonna file an issue on their repo.

joshuafhiggins commented 2 months ago

4 Text message redacted on iMessage side The Matrix side still shows the unredacted message. Fail

I'm unable to reproduce it with what you have included, if you're still able to cause the problem add a comment with more info.

The bridge contains another problem though in that messages edited by oneself in iMessage or BlueBubbles are not updated in Beeper. Because it functions right in BlueBubbles, this may be an issue in the bridge in unintentionally ignoring an updated message event. I'll continue looking into this.

Philantrop commented 2 months ago

To avoid confusion for anyone who did not see us clarifying it: I say "redacted" and you say "edited" but we both mean the same thing. :-)