Chatty does not update device id
With @devrtz we were looking at a situation were chatty would OMEMO encrypt nicely in one direction but not decrypt in the other direction. This lead to silently lost messages (https://github.com/gkdr/lurch/pull/150). With that out of the way we would see that messages can't be decrypted due to the sending not use the correct device id for encryption. This looks like
15:36:10) jabber: Recv (ssl)(988): <message xml:lang='en' to='agx@sigxcpu.org/bogon' from='devrtz@dismail.de/498705451604900890140509667' type='chat' id='purple5d7ff795'><archived by='agx@sigxcpu.org' id='1590672970115854' xmlns='urn:xmpp:mam:tmp'/><stanza-id by='agx@sigxcpu.org' id='1590672970115854' xmlns='urn:xmpp:sid:0'/><active xmlns='http://jabber.org/protocol/chatstates'/><origin-id xmlns='urn:xmpp:sid:0' id='5a26f24c-0737-4879-a0ae-3ac6aac4edca'/><encrypted xmlns='eu.siacs.conversations.axolotl'><header sid='1974483638'><key rid='412231370'>MwhNEiEFEp6JydPiYd5FIoBhE1e+RnbJAiE+gwx6BzmXnqnhnlMaIQUYxmJzKKtuKFbJh7F2bXi6tjFnpJ2KqEeR+xygL82HPCJiMwohBX8SqmexQtCcqzQ49bAz7iSoNR3O+3iQ88u4hhXug2E/EAkYACIwW1H6i21J9YGNi2vdnetIFGldguq/xz2ec6NAdiF3RsmpBlwxYQdCdZb9t0HkMzVpwWooFO6c8bsotvXArQcwAA==</key><iv>SwpNc21LNaA9ypW008A+yA==</iv></header><payload>iPKCWciR1uf5</payload></encrypted><encryption xmlns='urn:xmpp:eme:0' namespace='eu.siacs.conversations.axolotl' name='OMEMO'/><store xmlns='urn:xmpp:hints'/></message>
(15:36:10) jabber: XML parser error for JabberStream 0x5557ee334c30: Domain 3, code 100, level 1: xmlns: URI eu.siacs.conversations.axolotl is not absolute
(15:36:10) lurch: received omemo message that does not contain a key for this device, skipping
on the receiving side (the rid
is wrong). After fixing the device id in the db on the sending side (as workaround) encryption works both ways.
So there seems to be a problem where chatty does not pick up the device id from the receiving end.
I could see messages where the receiving side is updating it's bundle
(15:30:57) lurch: lurch_bundle_publish_own: published own bundle for agx@sigxcpu.org
(15:30:57) lurch: lurch_devicelist_process: processing devicelist from agx@sigxcpu.org for agx@sigxcpu.org
(15:30:57) lurch: lurch_devicelist_process: cached devicelist is
<publish node="eu.siacs.conversations.axolotl.devicelist"><item><list
xmlns="eu.siacs.conversations.axolotl"><device id="412231370" /><device
id="569804911" /></list></item></publish>
so the sending side should be able to pick that up