Closed mapama closed 8 years ago
i cant reproduce this, im on jabber.at
if i go offline, and send a message from my phone using conversations, after i go online with gajim i get a notification with the message.
You're right my steps to reproduce weren't precise enough. I had to exclude the scenario @lovetox described. I think @lovetox scenario is different because there is no other third client catching away the message while gajim is offline. In this case ejabberd stores the message as offline message and deliver it to gajim when coming online.
The situation that didn't work for me is as follows: Bob has two devices, one computer running gajim and one mobile running conversations, gajim is offline while conversations is online. Now Alice sends a message to Bob. Bob receives the message in conversations. Then switches on gajim, but doesn't get the carbon copied message. Without omemo enabled he does. If you would like to test it with one account you have to use a third client. @lovetox could you test this scenario on jabber.at please?
so do you get the message if gajim and conversations are online in both clients?
also are you using the current branch, or are you using the FTP version 0.4
i cant try this out right now.
Yes if both clients are online I receive the message in both. I am using version 0.4. Right now I can't test it with the current branch.
Ok, tested with the current branch but this doesn't matter. It doesn't work. Tested with two mobile clients running conversations and one client running gajim. Go offline with gajim send a message from one of the mobile clients. The second mobile client receive this message. Go online with gajim but the messages is missed in the chat history.
Bob has two devices, one computer running gajim and one mobile running conversations, gajim is offline while conversations is online. Now Alice sends a message to Bob. Bob receives the message in conversations. Then switches on gajim, but doesn't get the carbon copied message.
I can reproduce this on my server that runs prosody:
# dpkg-query -l | grep prosody
ii prosody 0.9.4-1~bpo70+1 amd64 Lightweight Jabber/XMPP server
I logged the output with gajim -l gajim.plugin_system.omemo=DEBUG -v
you can see it here: https://gist.github.com/exul/7e751ed9b0b5ff7c5647c998f18c44ca
Gajim version is 0.16.5
If you need an account or more information, just let me know.
I am not sure if the bug is as described.
I have the following case:
Server = Ejabberd with MAM
But:
If a contact sends the message using Gajim with OMEMO, it is not stored in the MAM (verified using database dump in ejabberd). So it looks like Gajim does not push OMEMO messages to the MAM ?
So it looks like Gajim does not push OMEMO messages to the MAM ?
I'm not sure if this is related to the rest of the thread but this can be solved by adding the
[yes, offtopic] Gajim seems to be sending
5320144d09002381a9c3ef8ecba34a3c0b301d47 adds the store hint. Not sure if this fixes OPs issue though. (This would require that the sending client in OPs case is gajim)
Go offline in Gajim Write in Conversations (Android) with OMEMO Go online in Gajim Open history in Gajim -> Message is there
Yes, that is not the problem. In this case the OMEMO-message is stored as offline message. As described above the problem occurs if another client is online while gajim is offline. In that case the OMEMO-message is not stored as offline message. But it should be stored via MAM, as it is the case for Non-OMEMO-messages.
I am online also in a second client ...
Thanks for the patch @iNPUTmice - It does not seem to fix the Problem with Gajim - I will have a look at the messages exchanged...
I think the </encrypted>
block? See my comparison between what conversations and what gajim sends ...
272187ce60df66384ea93bf1db97ed08257cf936
Seems to work! Thank you so much!
I am online also in a second client ...
Strange, in that case the messages don't appear in my chat history in gajim. What could be the problem?
Are you sending from Gajim? Does it work when sending i.e. from Conversations? Then the above patch is for you :D
I tried the patch. But it doesn't help. I am sending from conversations. The recipient is online with conversations and offline with gajim. Going online with gajim, the message is missing in the chat history.
@mapama What's the chat history? The history in the current chat window or the 'History Manager'?
@iNPUTmice Not the current window. That one I get with Ctrl-H.
hm seems like my MAM is not working at all gajim querys the server but gets no response at all
<iq xmlns="jabber:client" type="set" id="329">
<query xmlns="urn:xmpp:mam:0" queryid="328">
<x xmlns="jabber:x:data" type="submit">
<field var="FORM_TYPE" type="hidden">
<value>urn:xmpp:mam:0</value>
</field>
</x>
<set xmlns="http://jabber.org/protocol/rsm">
<max>30</max>
<after>1461862207990877</after>
</set>
</query>
</iq>
I can confirm this. It seems that MAM is not working anymore in gajim. I don't understand these strange thing. Even with disabled OMEMO the messages are not stored by MAM.
If this is a Gajim issue, may be @yann-l can have a look at that?
it seems jabber.at has a problem with MAM right now they are working on it.
@lovetox did you find out the problem with jabber.at?
@mapama they had a problem, but its fixed since a few days, does it still not work for you?
@mapama you are right still not working, but its not jabber.at fault, mam seems to work, the messages come through but the plugin seems to drop them, im looking into this now
Are MAM messages for the history window even processed trough the normal message hooks?
no i dont think so, i tested this, and the message never runs to the MessageReiceivedEvent
There is anohter MamMessageReiceivedEvent maybe its that
yeah thats it, event is mam-message-reiceived
@mapama if its not to much work for you you could try my branch
https://github.com/lovetox/gajim-omemo/
i included: Fingerprint UI (only shows you the fingerprints for now) You get better notification when OMEMO is disabled or someone writes you unencrypted MAM Messages should work now
if everything works, i plan to make a pull request
Thank you @lovetox MAM is now partially working. The received messages are shown in the history now but not my own carbon copied messages I wrote with conversations. Where do I find the Fingerprint UI?
Thanks a lot for your effort.
hi i will look into it today or tomorrow, could well be that i missed something
you find it under Plugins -> Omemo -> Configuration select the account, then switch to the fingerprint tab
remember though the buttons "trust" and "untrust" do nothing, every fingerprint is trusted at the moment, even when the UI shows it as false.
i believe i fixed it https://github.com/lovetox/gajim-omemo/commit/7a7c5c76cb7cf4fce18b41ce428e8612961f34c6
please try it @mapama
Thank you so much @lovetox It seems to work exactly as it should.
MAM patch is now merged.
Steps to reproduce this issue:
Expected behaviour: See the message in the chat history.
Tested with ejabberd 15.10 on Debian Jessie and MAM enabled.
Thanks for the development of this great plugin.