Package org.ice4j.ice

Class PeerReflexiveCandidate

  • All Implemented Interfaces:
    java.lang.Comparable

    
    public class PeerReflexiveCandidate
    extends LocalCandidate
                        

    Peer Reflexive Candidates are candidates whose IP address and port are a binding explicitly allocated by a NAT for an agent when it sent a STUN Binding request through the NAT to its peer.

    Peer Reflexive Candidates are generally allocated by NATs with endpoint dependent mapping also known as Symmetric NATs. PeerReflexiveCandidates are generally preferred to relayed ones. RFC 5245 explains this with better security ... although simply avoiding a relay would probably be enough of a reason for many.

    Author:

    Emil Ivov

    • Constructor Detail

      • PeerReflexiveCandidate

        PeerReflexiveCandidate(TransportAddress transportAddress, Component parentComponent, LocalCandidate base, long priority)
        Creates a PeerReflexiveCandidate instance for the specified transport address and properties.
        Parameters:
        transportAddress - the transport address that this candidate is encapsulating.
        parentComponent - the Component that this candidate belongs to.
        base - the base of a peer reflexive candidate base is the local candidate of the candidate pair from which the STUN check was sent.
        priority - the priority of the candidate.