jdev - 2020-09-16


  1. Moumen

    Hello , im just try to impliment the xep 313 i send the iq in this format iq type="set" to="majdalden@punkpanda.live" id="someId"><query xmlns="urn:xmpp:mam:2"><x xmlns="jabber❌data" type="submit"><field var="FORM_TYPE" type="hidden"><value>urn:xmpp:mam:2</value></field></x></query></iq> but i didn't get any response from the server any help. ?

  2. moparisthebest

    > if tor is activated, i just pass domain.org:5222 to TOR > if that fails to connect, there is nothing you can do and need to abort lovetox: don't a lot of tor exit nodes only allow 443 ?

  3. moparisthebest

    Just do DNS over tor with your protocol of choice, DoT, DoH, DoX

  4. lovetox

    moparisthebest, i connect to localhost:9050 thats the standard TOR port, i dont need to care what exit nodes use ports for outgoing connections, the same i dont need to care what my computer uses as port for an outgoing connection

  5. lovetox

    and no why would i implement the whole DNS protocol, if a admin can just serv the standard xmpp port?

  6. Martin

    > if tor is activated, i just pass domain.org:5222 to TOR > if that fails to connect, there is nothing you can do and need to abort Ah that's why gajim didn't work with TOR when my server was still running on uberspace. I even manually set the port in the account settings. Those are ignored?

  7. Martin

    But actually your logs said gajim us using that port: > 08/07/18 10:21:25 (I) gajim.c.connection: >>>>>> Connecting to mdosch.de [95.143.172.208:61540], type = tls

  8. lovetox

    Martin, you use an old Gajim version

  9. lovetox

    Previously Gajim did do DNS query but not over TOR

  10. lovetox

    which was not good because people that use TOR dont want to query dns in cleartext

  11. lovetox

    But of course you can always set a custom host, means you specify IP and Port yourself

  12. lovetox

    then TOR does not need to do any resolving, which should work fine, at least in the new Gajim version

  13. lovetox

    but we were talking about discoverying endpoints via DNS querys, so thats beside the topic

  14. lovetox

    basically everything works over TOR which only needs A or AAAA resolving

  15. lovetox

    because thats the only thing TOR supports

  16. Martin

    > Martin, you use an old Gajim version Yes, that bug report is from 201 > Previously Gajim did do DNS query but not over TOR Ugh, I wasn't aware of this. I manually put in my IP and my port by that time and wondered why gajim failed. > then TOR does not need to do any resolving, which should work fine, at least in the new Gajim version Exactly that's what I wanted to achieve. Maybe I'll try if gajim can use TOR now with a more recent version. 😃

  17. lovetox

    but the question is, why do you need that at all

  18. lovetox

    why does your server not simply support port 5222

  19. Martin

    By that time I had my server on a shared hoster as I thought it's a good idea to not set up your own vps on the internet before you have some more experience. 🙂

  20. lovetox

    but please have a test with Gajim 1.2, i rewrote the whole xmpp lib, so would be interested in problems

  21. Martin

    I can do, but now I have a vps and therefore I'm using 5222 now.

  22. moparisthebest

    lovetox: what I mean is the amount of tor exit nodes that allow 5222 is far less than the amount that allow 443, you are drastically cutting down the likelihood of a successful connection by not doing srv

  23. lovetox

    im not sure what you are talking about

  24. lovetox

    why would a TOR exit node not allow to connect to a certain port

  25. lovetox

    what does TOR care to what port i connect

  26. lovetox

    TOR is a proxy, why would it act as a outgoing firewall

  27. MattJ

    Exit node operators probably want to limit abuse

  28. lovetox

    so to limit abuse they dont allow to use a service via TOR, meaning users cant use TOR hence less anonymity, and totally the opposite of what TOR wants to achieve

  29. lovetox

    tough i have to say i don’t believe this story until i see evidence, sorry

  30. defanor_

    AFAIK port restriction is the default, see <https://2019.www.torproject.org/docs/tor-manual.html.en#ExitPolicy>. And it's gennerally suggested to allow at least HTTP ports.

  31. Martin

    I use XMPP and email over TOR just fine and neither goes over 443 so I don't think there are many exits only allowing 443.

  32. lovetox

    so defanor_ this exit default policy allows 5222

  33. lovetox

    no problemo :)

  34. Martin

    > The default exit policy is: > reject *:25 > reject *:119 > reject *:135-139 > reject *:445 > reject *:563 > reject *:1214 > reject *:4661-4666 > reject *:6346-6429 > reject *:6699 > reject *:6881-6999 > accept *:* >

  35. Martin

    No problem

  36. lovetox

    actually it blocks very little at all

  37. defanor_

    Indeed, just tried to answer the "what does TOR care to what port i connect" bit.

  38. lovetox

    yes i was wrong at that it seems, i learned every operator blocks whatever he wants

  39. defanor_

    Even the reduced exit policy below it allows 5222-5223.

  40. lovetox

    has even its own entry accept *:5222-5223

  41. lovetox

    xmpp is famous

  42. Zash

    but not 5269! :t

  43. Zash

    but not 5269! 🙁

  44. Moumen

    Hello all , i have a little problem when i send this iq <iq type="set" to="majdalden4@punkpanda.live" id="713D2D6F-B162-4B56-9FE9-2FCE936B3A3E"><query xmlns="urn:xmpp:mam:2"><x xmlns="jabber❌data" type="submit"><field var="start"><value>2020-09-14T00:00:00Z</value></field><field var="FORM_TYPE" type="hidden"><value>urn:xmpp:mam:2</value></field></x><set xmlns="http://jabber.org/protocol/rsm"><max>5</max></set></query></iq> i did't receive any msg from the server

  45. Moumen

    https://ibb.co/c36pttt

  46. Moumen

    you can see it formatted correctly here

  47. Moumen

    https://ibb.co/c36pttt

  48. lovetox

    so what response did you got?

  49. Moumen

    nothing

  50. lovetox

    then the server is broken

  51. lovetox

    every IQ needs to be answered

  52. lovetox

    so look into the server logs

  53. Moumen

    i will. test it again now

  54. Moumen

    now i made a little change so the iq look like that

  55. Moumen

    <iq type="set" to="majdalden4@punkpanda.live" id="1C3716CF-B14C-422A-8880-82B746D77A7C"><query xmlns="urn:xmpp:mam:2"><x xmlns="jabber❌data" type="submit"><field var="with"><value>majdalden4@punkpanda.live</value></field><field var="FORM_TYPE" type="hidden"><value>urn:xmpp:mam:2</value></field></x><set xmlns="http://jabber.org/protocol/rsm"><max>70</max><before></before></set></query></iq>

  56. Moumen

    and i receive this as response

  57. Moumen

    <iq xmlns="jabber:client" lang="en" to="test6000@punkpanda.live/ios" from="test6000" type="error" id="12703B5D-887D-443A-9595-F97B39EB9E20"><query xmlns="http://jabber.org/protocol/disco#items" node="all users"></query><error code="404" type="cancel"><remote-server-not-found xmlns="urn:ietf:params:xml:ns:xmpp-stanzas"></remote-server-not-found><text xmlns="urn:ietf:params:xml:ns:xmpp-stanzas" lang="en">DNS lookup failed: non-existing domain</text></error></iq>

  58. Zash

    That looks like the response to a different query.

  59. Zash

    And it also suggests that the `to` attribute on your MAM query is not correct. Best to leave it out entirely.

  60. Moumen

    where should i put it then ?

  61. Zash

    put what?

  62. Moumen

    and in MAM do i need to add from property ?

  63. lovetox

    you dont need to add a to or a from

  64. Zash

    `<iq type="set" id="something"><query .../></iq>`

  65. Zash

    Just do that

  66. lovetox

    and this was not the answer to your query, the id has to be in both the query and the answer

  67. Moumen

    oh ok thanks a lot .