jdev - 2019-09-02


  1. pep.

    re https://mail.jabber.org/pipermail/standards/2019-August/036367.html, do I really want to send directed presences to anybody who initiates an OMEMO discussion with me?

  2. pep.

    That means anybody can freely request my presence

  3. pep.

    And I guess subscribing to PEP would be the same to some extent?

  4. Daniel

    Zash: omemo dates back to a time when multiple items in a node wasn't a thing

  5. Daniel

    And changing the access model is a later, backward compatible change. Using just one node is not

  6. Daniel

    I also find the multiple nodes thing to be ugly but 🤷‍♂️

  7. Daniel

    tom: some servers also allow you to set the access model server side

  8. pep.

    Daniel: no opinion on my question above?

  9. Daniel

    pep., on the subscribe / not subscribe?

  10. Daniel

    no not really. it is a tough question. i don’t have a good answer

  11. pep.

    I think I'll be subscribing to PEP manually when I get a message from a non-contact, and unsubscribe when either the user closes the tab, or I disconnect, or if I get a PEP notification and I don't have any tab for them anymore

  12. Daniel

    > if I get a PEP notification and I don't have any tab for them anymore + not having mutual presence sub

  13. pep.

    That opens me to less things I guess? Sending directed presence automatically seems a bit meh privacy-wise? (Or am I missing something)

  14. pep.

    Yee

  15. pep.

    Yess

  16. pep.

    Yes

  17. pep.

    (I'm not drunk, honest)

  18. Daniel

    i follow that logic privacey wise. seems like a lot of hassle

  19. Daniel

    plus unclear what happens if Conversations still has a tab open

  20. Daniel

    can i subscribe full jid?

  21. pep.

    Well that means anybody can get a directed presence from me if they send me some kind of omemo attempt

  22. Zash

    You specify the JID to subscribe

  23. Daniel

    pep., well in both cases i would first sub/send presence when you want to respond

  24. pep.

    Why?

  25. pep.

    I would refuse it. I don't want everybody in my contacts

  26. Zash

    pep-sub

  27. Zash

    I assume

  28. Daniel

    yes

  29. Zash

    pep-subscription and directed presence

  30. pep.

    Ah

  31. Daniel

    *or

  32. pep.

    Yes

  33. pep.

    Or yes

  34. Daniel

    so either way it will be a) a little less harmfull privacey wise b) more of a just-in-time / just-if-needed approach

  35. pep.

    Ah I see what you mean

  36. pep.

    When you want to respond and not when you revive it

  37. pep.

    Receive*

  38. Daniel

    yes

  39. Zash

    User signals intent, so seems fine.

  40. pep.

    Also directed presence then? Or do you think it's not useful? (Because there's no associated behaviour yet)

  41. Daniel

    i mean the manually pep-sub / pep-unsub is really annoying because later on you will also want to pep-sub to muc participants

  42. Daniel

    and then when a notification comes in you have to check for tab open, mutual presence and if you are in a muc with that person

  43. Zash

    That will be fragile

  44. Daniel

    and if not pep-unsub

  45. pep.

    Yeah that sounds annoying

  46. Daniel

    yes that will be super fragile

  47. Daniel

    that's why i haven’t done it yet either

  48. Daniel

    that's why i kinda like the simplicity of the directed presence suggestion you had

  49. Daniel

    but i also totally see the downsides of that

  50. Daniel

    plus if you go the pep-sub route? do you unsub before logoff? do you resub on every login?

  51. pep.

    I probably would

  52. Daniel

    since you can’t really know if you have succesfully subbed in a previous session you will probably have to resub on login anyway

  53. Daniel

    so that's a lot of traffic

  54. Daniel

    however you want to spin it it's going to be supper annoying

  55. pep.

    Hmm, I'm probably not a good example with my ratio of opened public channels vs private ones

  56. pep.

    I think in any case we could make it so that PEP with access_model=open is sent if there is a directed presence. Independently of whether we use it for omemo

  57. pep.

    Then maybe someday it'll get better deployment wise

  58. Daniel

    > I think in any case we could make it so that PEP with access_model=open is sent if there is a directed presence. Independently of whether we use it for omemo Yes as I said on list this probably won't hurt. And then some people can do that until we have something better

  59. pep.

    That would require a change in the xep right?

  60. pep.

    A new disco thing?

  61. Daniel

    Maybe we can also be a bit smarter about how we detect new devices. For example when I receive an omemo message from someone with an unknown device id (because they are using it to carbon copy to one of their other devices) I'll try to trigger a device list query again

  62. Daniel

    Little things like that

  63. pep.

    Right

  64. Ge0rG

    Little undocumented things? Even the part about adding all your other device IDs into a message because of implied 0280 isn't really documented.

  65. Daniel

    little undocumented things? you mean xmpp?

  66. Ge0rG

    No, that's the huge undocumented elephant in the room thing.

  67. Daniel

    also not true. from the omemo xep: > for each intended recipient device, i.e. both own devices as well as devices associated with the contact

  68. pep.

    Ge0rG: we all know the omemo xep could be better. There's an effort to document that on the wiki already iirc

  69. pep.

    (Looking for it)

  70. pep.

    Where was that page again..

  71. Daniel

    under tech pages

  72. Ge0rG

    We should have a wiki category for Errata or somesuch, and link to it from https://xmpp.org/extensions/

  73. pep.

    Daniel: thanks

  74. pep.

    Ge0rG: agreed

  75. Ge0rG

    luckily, you don't have to be on iteam to create wiki categories

  76. pep.

    Then go ahead :p

  77. pep.

    Also don't forget to submit your changes to xsf/xmpp.org

  78. pep.

    Or xeps

  79. Ge0rG

    Also somebody should move the 2020 events from "Recent" into "Upcoming"

  80. pep.

    Somebody should

  81. Daniel

    i'll do that

  82. Daniel

    also gsoc is over, right?

  83. pep.

    Yeah, final evaluation is over almost

  84. Ge0rG

    Hey, I already did that for https://wiki.xmpp.org/web/index.php?title=Category:Interop more or less.

  85. pep.

    There's also the remarks page

  86. Ge0rG

    Daniel: please also add https://wiki.xmpp.org/web/Board_and_Council_Elections_2019

  87. pep.

    https://wiki.xmpp.org/web/XEP_and_RFC_Remarks

  88. pep.

    We could link to that

  89. pep.

    Oh that's a thing already

  90. Ge0rG

    pep.: wait, is that like a Category page but manually maintained?

  91. pep.

    Dunno

  92. pep.

    Maybe it's just a page

  93. pep.

    We could make it a category yeah

  94. Ge0rG

    pep.: it's a page that contains a list of other pages.

  95. Ge0rG

    Yes please

  96. pep.

    "Errata"

  97. pep.

    Never done that, and I'm on the phone right now (biggest hurdle)

  98. Ge0rG

    Category:Errata is good, I think. "Remarks" are slightly more than Errata, but I think it captures the meaing rather well

  99. Ge0rG

    pep.: it's actually super-easy, just add the category tag at the bottom of each page, like this: https://wiki.xmpp.org/web/index.php?title=Interop_2010&curid=408&diff=11425&oldid=2346

  100. Ge0rG

    pep.: if you can schedule the time to do it in the next days, that would be great.

  101. pep.

    I like how you give work to others :p

  102. Ge0rG

    pep.: finally, move the https://wiki.xmpp.org/web/XEP_and_RFC_Remarks page into https://wiki.xmpp.org/web/index.php?title=Category:Errata

  103. Ge0rG

    pep.: "I'm on the phone right now" is a temporary state, and I read that "I'd like to do it, but"

  104. Ge0rG

    pep.: also you said at FrOSCon that you have some free time for this kind of things ;)

  105. pep.

    That I'm using fully, don't worry about mr

  106. pep.

    That I'm using fully, don't worry about me

  107. pep.

    Not that I don't want to do it, but not right now, also I don't like being told things, so you'll have to be more subtle next time :p

  108. pep.

    Your nerdsniping skills could be improved!

  109. Ge0rG

    pep.: oh, sorry! It would be really great if somebody volunteered to refactor that page into a wiki category... 😇

  110. jonas’

    pep., regarding errata, I’d be interested in having a consistent naming scheme for that so that I can detect existing pages during xeps builds and add links from XEP -> Errata pages

  111. jonas’

    there’s an issue for that in the xeps repo

  112. pep.

    Seems I'm the goto person now. Ge0rG you can take example on jonas’

  113. pep.

    You can't really guarantee what users will do with page names

  114. pep.

    But we can definitely restrict what the build will use

  115. jonas’

    pep., yes, the build needs a URL-template where only the XEP number is a variable.

  116. jonas’

    it’ll still be fun & tricky to do because we can’t (hopefully) do that in XSLT

  117. pep.

    My xslt skills are almost nonexistent anyway

  118. Zash

    jonas’ is that a challenge?

  119. Zash

    Isn't xslt turing-complete?

  120. jonas’

    Zash, it is, but it cannot request external resources in XSLT 1.0

  121. Zash

    Mmmmm, must be some wiki index that can be fetched and used somehow

  122. Ge0rG

    jonas’: would it be insane to have a category for each XEP, and to link to that?

  123. jonas’

    Ge0rG, yes, I think so

  124. jonas’

    a page per XEP should do

  125. jonas’

    do you have a concrete example where that isn’t sufficient? could we do a redirect to a category in that case?

  126. jonas’

    do you have a concrete example where that isn’t sufficient? could we do a redirect to a category in those cases?

  127. Ge0rG

    jonas’: it would give us auto-linking of all pages related to a given XEP

  128. jonas’

    Ge0rG, wait, a category per XEP for all XEP-related stuff, or a category per XEP for all errata?

  129. jonas’

    Ge0rG, wait, a category per XEP for all XEP-related stuff, or a category per XEP for all errata for that XEP?

  130. jonas’

    a category per XEP for all XEP-related stuff (including a single page which is used for errata) makes sense to me

  131. Ge0rG

    jonas’: a category per XEP and a link from the XEP to that category?

  132. pep.

    I think it's fine if a page doesn't exist on the wiki

  133. pep.

    Just link to it, and people can create it when necessary

  134. Daniel

    Zash, does proxy65 have a timeout? between connecting and activation?

  135. Zash

    NAFAIK

  136. Zash

    Is this a XEP question or a Prosody question?

  137. Daniel

    prosody. the xep doesn’t say anything in that regard

  138. Zash

    I'd have to look at the code but I don't remember any timeout in the module itself.

  139. Zash

    There are however socket timeouts that kick in if you're idle for some time and I don't think it has any keepalive logic.

  140. Zash

    Also this is not the prosody support room

  141. Daniel

    it's a prelude to a broader question that concerns jdev

  142. Daniel

    because ejabberd has one and it's causing problems in the way i use proxy65 with jingle

  143. Zash

    I imagine that the receiving end could have troubles if they don't say anything for ~14 minutes

  144. Daniel

    yeah 14 min is probably fine

  145. Zash

    But that's after activatino

  146. Zash

    Large files and poor connections (mobile?) could probably reach that

  147. Daniel

    so the way i use jingle is that i connect to my own candidates before i send the offer. (because there are chances that i can’t reach my own proxy because firewall/missconfiguration and i can’t retroactively kill one of my candidates

  148. Zash

    But you're talking about a timeout between the inital connection(s) and the activation?

  149. Daniel

    so if remote takes it's time to answer my offer, connect to the proxy as well / go through the dance; there might be more time passed than timeout before i can send proxy activate

  150. Daniel

    Zash, that's the one

  151. Daniel

    but maybe i'm just not understanding jingle

  152. Zash

    I thought you could add/change/remove anything at any time, but then I haven't done much Jingle dev either.

  153. Ge0rG

    Are there still MUC implementations that don't set status=110 on your reflected join presence?

  154. chinaocean

    I send xml message to openfire by spark to regieste an account

  155. chinaocean

    but Openfire report the error :

  156. chinaocean

    <field type="jid-single" label="The Jabber ID for the account to be added" var="accountjid"> <required /> </field>

  157. Zash

    Maybe you could pastebin the full stanzas you sent and received?

  158. chinaocean

    in fact , i have trasfered the JID parameter

  159. chinaocean

    <iq id="TQqV7UxKTUq+rBftv6naLA" from="admin@domain" type="set" to="domain" xmlns="jabber:client"> <command node="http://jabber.org/protocol/admin#add-user" xmlns="http://jabber.org/protocol/commands"> <x type="submit" xmlns="jabber❌data"> <field var="FORM_TYPE" type="hidden"> <value>http://jabber.org/protocol/admin</value> </field> <field var="accountjid" type="jid-single"> <value>hahaha@domain</value> </field> <field var="password" type="text-private"> <value>123456</value> </field> <field var="password-verify" type="text-private"> <value>123456</value> </field> </x> </command> </iq>

  160. chinaocean

    the stanza i received

  161. chinaocean

    <iq type="result" id="TQqV7UxKTUq+rBftv6naLA" from="domain" to="admin@domain/aiygy5xatq" xmlns="jabber:client"> <command xmlns="http://jabber.org/protocol/commands" sessionid="RArCgzJpZBzDIse" node="http://jabber.org/protocol/admin#add-user" status="executing"> <x xmlns="jabber❌data" type="form"> <title>Adding a user</title> <instructions>Fill out this form to add a user.</instructions> <field type="hidden" var="FORM_TYPE"> <value>http://jabber.org/protocol/admin</value> </field> <field type="jid-single" label="The Jabber ID for the account to be added" var="accountjid"> <required /> </field> <field type="text-private" label="The password for this account" var="password" /> <field type="text-private" label="Retype password" var="password-verify" /> <field type="text-single" label="Email address" var="email" /> <field type="text-single" label="Given name" var="given_name" /> <field type="text-single" label="Family name" var="surname" /> </x> <actions execute="complete"> <complete /> </actions> </command> </iq>

  162. Zash

    Is that really how ad-hoc command flow goes?

  163. Zash

    https://xmpp.org/extensions/xep-0050.html#execute

  164. chinaocean

    i dont know what is the promlem

  165. Zash

    Not starting with this step? https://xmpp.org/extensions/xep-0050.html#example-8

  166. Zash

    Rougly, for simple commands it goes something like 1. Execute command 2. Receive dataform 3. Submit dataform with values 4. Get result (or another form)

  167. chinaocean

    https://xmpp.org/extensions/xep-0050.html#example-8

  168. chinaocean

    it is OK

  169. chinaocean

    <iq to="admin@domain/Spark" id="isxaf-87" type="result"> <query xmlns="jabber:iq:private"> <scratchpad xmlns="scratchpad:tasks"> <tasks showAll="true"/> </scratchpad> </query> </iq>

  170. chinaocean

    i received this message

  171. Zash

    That looks unrelated

  172. chinaocean

    ??

  173. chinaocean

    what shall i do ?

  174. Zash

    I don't know, I can't help you with that

  175. chinaocean

    thks!

  176. chinaocean

    <iq to="admin@domain/Spark" from="responder@domain" id="exec1" type="error"> <error type="cancel"> <item-not-found xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"/> </error> </iq>

  177. chinaocean

    it return like this

  178. Zash

    If that's in reply to a command then I would guess that you forgot the session id

  179. Zash

    Is there no library functions for dealing with ad-hoc commands?

  180. chinaocean

    MatriX

  181. Zash

    I've never used that, so I can't answer that question

  182. chinaocean

    you remind me: sessionid

  183. chinaocean

    i send a guid , the result is like this

  184. chinaocean

    <error code="400" type="modify"> <bad-request xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" /> </error>

  185. Zash

    The server includes it in the initial response

  186. chinaocean

    openfire didnot repost the JID error

  187. chinaocean

    how to get the sessionid?

  188. Zash

    https://xmpp.org/extensions/xep-0050.html#desc-command

  189. Zash

    It was in the first response you sent earlier

  190. Zash

    Save it and use it in the next request

  191. chinaocean

    i know.

  192. chinaocean

    i create an unique id as a seesion id

  193. chinaocean

    and i will received a stanza like this

  194. chinaocean

    <iq type="error" id="add-user_00001" from="domain" to="admin@domain/7154tif52" xmlns="jabber:client"> <command xmlns="http://jabber.org/protocol/commands" node="http://jabber.org/protocol/admin#add-user" sessionid="6ff594373fd6437aa8ac3439ebe83ae5"> <x xmlns="jabber❌data" type="submit"> <field var="FORM_TYPE" type="hidden"> <value>http://jabber.org/protocol/admin</value> </field> <field var="accountjid" type="jid-single"> <value>hahaha@domain</value> </field> <field var="password" type="text-private"> <value>123456</value> </field> <field var="password-verify" type="text-private"> <value>123456</value> </field> </x> </command> <error code="400" type="modify"> <bad-request xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" /> </error> </iq>

  195. Ge0rG

    Should a client send 0184 receipts for all messages retrieved from MAM? :>

  196. Zash

    Ugh

  197. Zash

    Should the server save 184 recepits?

  198. lovetox

    yes Ge0rG

  199. lovetox

    yes Zash

  200. Ge0rG

    Zash: yes

  201. Ge0rG

    Zash: also message errors.

  202. lovetox

    Ge0rG, you can wait the catchup and see if another client of yours already sent a 0184 receip

  203. lovetox

    then you should not send another one

  204. lovetox

    as receipts should be account based not resource based

  205. Zash

    If receipts are account based then the server should send them

  206. lovetox

    Server cant know if client received a message

  207. Zash

    and then they change meaning to "saved into recipients archive"

  208. lovetox

    receipt means a client successfully processed a message, in my opinion

  209. lovetox

    and not "its in some archive"

  210. lovetox

    though probably debateable

  211. Ge0rG

    I agree with lovetox on that.

  212. Ge0rG

    Otherwise I'd have suggested that before.

  213. Ge0rG

    But there is real value in "this message arrived at a client", because it means the account isn't abandoned

  214. Ge0rG

    I also need a mechanism to delay notifications for MAMed messages.

  215. lovetox

    amazing how much more things you have to think about in a client if you implement this rather easy "get me these messages from the archive" XEP :9

  216. Zash

    Has 333 been fixed to not duplicate parts of 184 and chat states?

  217. Zash

    ... yet?

  218. lovetox

    nope

  219. lovetox

    but also nobody is forced to implement these parts :9

  220. lovetox

    but also nobody is forced to implement these parts :)

  221. Zash

    Nobody is forced to implement 333 at all

  222. Ge0rG

    Sigh. Databases are hard. I want to switch android notifications from live-generated and appended-to, to database based. I'm looking for something like "unread incoming messages", but that conveniently leaves out delivery errors, because those get aggregated into the "outgoing transmitted but failed" messages

  223. Ge0rG

    I wonder if an SQLite index on (from_or_to, delivery_status) will even work efficiently for such a query. After all, from_or_to can take both possible values here.