Using non-persistent instance tags
According to the documentation in UPGRADING, the
create_instag callback is supposed to be optional:
If you don't provide an implementation for this operation, a new non-persistent instance tag will be randomly generated.
Yet without the callback, OTR is unable to complete a handshake. Or am I missing the obvious here?
The problem seems to be that the sender instance isn't properly set on outgoing auth messages.
This is how the first messages look when create_instag is specified:
TAGGEDPLAINTEXT Sender instag: 1878792512 (0x6ffc1940) Recipient instag: 0 (0x0)
DH_COMMIT Sender instag: 1075021345 (0x40138621) Recipient instag: 1878792512 (0x6ffc1940)
Without the callback, the sender instag on the second message is missing:
TAGGEDPLAINTEXT Sender instag: 2432242955 (0x90f9150b) Recipient instag: 0 (0x0)
DH_COMMIT Sender instag: 0 (0x0) Recipient instag: 2432242955 (0x90f9150b)
I've been testing this with https://gist.github.com/mhanne/1630071 - just remove the callback in line 227 to see it fail.
Might be related to #16.
Also, it seems that the problem has come up before: http://debian.2.n7.nabble.com/Bug-733319-psi-plus-plugins-OTR-conversations-between-psi-plus-and-pidgin-sometimes-don-t-work-td3137077.html
Apparently the psi+ developers just added the callback now to avoid the issue.
(from redmine: created on 2016-03-24)