#68 IPv6 support

Reporter niekbergman
Owner MattJ
Created
Updated
Stars ★★★★★★ (22)
Tags
  • Milestone-0.9
  • Status-Fixed
  • Priority-Medium
  • Type-Enhancement
  1. niekbergman on

    *What steps will reproduce the problem?* 1. Run Prosody on an IPv6 enabled system. 2. Try to connect to the server over IPv6 ( telnet ::1 5222 ) 3. Watch the connection fail. *What is the expected output? What do you see instead?* Expected is that Prosody binds to IPv6 adresses too. It currently does not. *What version of the product are you using? On what operating system?* Mercurial, with the following version: changeset: 831:e2d2095705dc on Ubuntu 8.04.2 *Please provide any additional information below.* No additional information. If more information is needed, please reply ;-)

  2. MattJ on

    Confirmed, the issue seems to be in LuaSocket: > return socket.bind("::1", 1235) nil host not found I have tonight emailed the LuaSocket developer, though I suspect the solution sees me fixing the code, and distributing a patched version until a new one is released :(

    Changes
    • tags Status-Accepted
    • title IPv6 support
    • owner MattJ
  3. nick@lupine.me.uk on

    I'm currently patching LuaSocket to accept IPv6 - I got Prosody to bind to IPv6 sockets tonight. Coordinating with Diego to get a more generally-usable and upstream-friendly API for sockets and resolver; it's always nice to push changes upstream.

  4. Waqas on

    @nick "Bear with me."??? That was cruel.

  5. MattJ on

    Marking an an Enhancement rather than Defect. IPv6 is still a goal, but other pressing things are taking my time at the moment.

    Changes
    • tags Type-Defect Type-Enhancement
  6. agoode on

    For easy reference, here are some links pertaining to the work on LuaSocket: http://lua-users.org/lists/lua-l/2009-06/msg00306.html http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=562163 Things look a little stalled out, I might try to get things going on LuaSocket if I find some time.

  7. agoode on

    I think nixio might be a way forward, the large amount of duplicated code between luasocket and luasec is problematic by itself, and the fact that luasocket seems pretty frozen at this point suggests looking elsewhere.

  8. bernd.zeimetz on

    Nick Thomas provides a patch - see http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=562163#37

  9. ayourtch on

    @bernd.zeimetz: I am not familiar with the VCS that Nick's site uses - what is the clean way to get the diff in "batch" mode ? I'd be curious to give it a shot.

  10. paul.aurich on

    That site is running redmine, but Nick doesn't maintain a running hgserve instance (or didn't, last I checked). You can find a tar.bz2 of his code at http://darkrain42.org/prosody/luasocket-nick.tar.bz2. ~Paul

  11. MattJ on

    Changes
    • tags Milestone-0.9
  12. MattJ on

    Diego (LuaSocket author) informed me today he is currently working on this :)

    Changes
    • tags Status-Started
  13. bernd.zeimetz on

    Any news on this? having ipv6 support would really rock!

  14. bjo.fra81 on

    It works: http://www.lightwitch.org/stories/xmpp/ipv6-prosody-yay I'm running prosody-trunk nightly build 234 and selfbuild luasocket2-hg on debian now.

  15. MattJ on

    Hey, For c2s it certainly works... we're currently working on supporting it for outgoing s2s connections (requires a bit more work, resolving AAAAs, etc.). That said, I think it's mostly done...

  16. bjo.fra81 on

    Ah, this explains why I have only a IPv4-connection to the IPv6-ejabberd of a friend of mine.

  17. normanr on

    fyi, there's also a fork of luasocket here: https://github.com/sam-github/luasocket

  18. MattJ on

    Yes, thanks. Sam contacted me about it. For the record I don't consider luasocket2-hg on code.matthewwild.co.uk a fork... the intent is for all of it to be merged into the official LuaSocket and a new release made. I'm encouraging Sam to do the same with his work. Diego mentioned he was considering setting up an official LuaSocket repository, which would be a very good thing in my opinion.

  19. MattJ on

    Ok... today I pushed the last IPv6 functionality patches to trunk. They'll be available in nightly #248. To get it working you'll currently need to build a custom LuaSocket from source. Once the code has been proven sane by initial testers then we'll work on something more manageable for a release (like getting it merged into the official LuaSocket). Next add to the global section of your config: interface = { "*", "::" } (the "*" is for IPv4, the "::" is for IPv6) Full information on the latest changes is at: https://groups.google.com/group/prosody-dev/browse_thread/thread/77bab41441ed5b8e Thanks goes to Florian for making most of this work :)

    Changes
    • tags Status-Fixed
  20. bjo.fra81 on

    I'm running now nightly #248, c2s works, but no outgoing s2s.

  21. normanr@google.com on

    The thread mentions that if you use "*" and "::" then IPv4 is preferred. If you explicitly list the addresses (instead of wildcard), then the preference works correctly.

  22. MattJ on

    We just merged a bunch of new code into trunk (see http://blog.prosody.im/tiiiiiiimber/ ). This includes IPv6 enhancements, we now support it for all connections (XMPP and others), both incoming and outgoing. All you need to do are two things: 1) Install an IPv6 version of LuaSocket. An official LuaSocket release with our changes being worked on, and it should be out in time for the 0.9.0 release. In the meantime you can get it from https://github.com/diegonehab/luasocket/tree/unstable (via git or the download links there). 2) Set use_ipv6 = true in the Prosody config. This will tell Prosody to use IPv6 by default for all its services. Since we're on a countdown to the release now, testing and bug reports are very welcome (please open new tickets for specific issues). Thanks all!

  23. adrien.lm on

    some news ? any idea of a date for the integration of IPv6 LuaSocket on Debian ?

  24. MattJ on

    IPv6 support will be released with 0.9, which we are currently packaging. The IPv6 capable version of LuaSocket sadly won't be the next version of Debian (wheezy). It'll be in the next one, so you only have a few years to wait :) We will be releasing a packaged version of the new LuaSocket along with 0.9, that you will be able to install from packages.prosody.im along with Prosody.

  25. bernd.zeimetz on

    well, there are backports. Providing updated packages for wheezy there is not hard.

  26. MattJ on

    Just for anyone subscribed to this bug report but missed the release announcement, or who is reading it at some point in the future... We have released 0.9.0beta1 with full IPv6 support. There is as yet still no official LuaSocket release with IPv6 (it's being worked on). Therefore we have released "lua-socket-prosody" packages for the time being. Latest information on everything IPv6-related can be found here: http://prosody.im/doc/ipv6 Thanks for everyone's patience and support while we worked on this! Hopefully other Lua projects can also now benefit from our work. If you test the beta and find any issues, please report as separate bugs and we'll fix them as soon as we can.

New comment

Not published. Used for spam prevention and optional update notifications.