GithubHelp home page GithubHelp logo

Comments (4)

enobufs avatar enobufs commented on September 27, 2024

Incoming packages should be demux/parsed like this:

Screen Shot 2019-07-08 at 12 43 56 AM

from ice.

enobufs avatar enobufs commented on September 27, 2024

In order to make this possible, we will need to modify pion/stun and pion/turnc to use net.UDPConn which is not bound to a specific remote address, meaning, we should use net.ListenPacket(or net.ListenUDP). NOT net.DialUDP! (it creates a "connected" udp socket!)

Here's a demo

from ice.

enobufs avatar enobufs commented on September 27, 2024

The new TURN Client (in pion/turn) is almost ready. (see pion/turn#75).

The new client will allow achieving what this PR is aiming for, but let's do it after pion/webrtc#712 successfully lands. (This does not strictly affect connectivity)

Here's what we need to do...
Since currently, all Candidate (concrete) classes share the parent (or embedded in a go's sense) struct, candidateBase which invokes a read-loop (goroutine) on start() - this needs to be changed.

Here's my plan:

  • Create a candidateBase per local IP address
  • candidataBase also has an instance of turn.Client.
  • Let candidateBase creates actuall candidates such as CandidateHost, CandidateServerReflexive, etc. In another word, candidataBase works as a "candidate factory". For instance, candidateBase would have these methods:
    • createCandidateHost()
    • createCandidateSrflx()
    • createCandidatePrflx()
    • createCandidateRelay()
  • When createCandidateRelay() is called, candidateBase also allocates a relay port on the TURN server.

from ice.

enobufs avatar enobufs commented on September 27, 2024

At this point, we will have a proper STUN transaction (and with retransmits) with STUN server, as well as connectivity checking all done by the new turn.Client.

from ice.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.