diff options
author | Ingo Bauersachs <ingo@jitsi.org> | 2016-12-27 22:34:59 +0100 |
---|---|---|
committer | Ingo Bauersachs <ingo@jitsi.org> | 2016-12-27 22:34:59 +0100 |
commit | c7bc11749b35e5d0b7ecf1488080f53d5b8d3ea2 (patch) | |
tree | dceb5db51c538a542e822948773d99fb2fdaff78 /src | |
parent | 9ffda8db84eac97151430f95ae0d6ce46fb6a157 (diff) | |
download | jitsi-c7bc11749b35e5d0b7ecf1488080f53d5b8d3ea2.zip jitsi-c7bc11749b35e5d0b7ecf1488080f53d5b8d3ea2.tar.gz jitsi-c7bc11749b35e5d0b7ecf1488080f53d5b8d3ea2.tar.bz2 |
Ignore invalid (empty) Jingle Nodes relay IPs
Diffstat (limited to 'src')
-rw-r--r-- | src/net/java/sip/communicator/impl/protocol/jabber/JingleNodesHarvester.java | 9 |
1 files changed, 8 insertions, 1 deletions
diff --git a/src/net/java/sip/communicator/impl/protocol/jabber/JingleNodesHarvester.java b/src/net/java/sip/communicator/impl/protocol/jabber/JingleNodesHarvester.java index bb7d31b..5c12aa7 100644 --- a/src/net/java/sip/communicator/impl/protocol/jabber/JingleNodesHarvester.java +++ b/src/net/java/sip/communicator/impl/protocol/jabber/JingleNodesHarvester.java @@ -125,7 +125,7 @@ public class JingleNodesHarvester } } - if (ciq != null && ciq.getRemoteport() > 0) + if (ciq != null) { ip = ciq.getHost(); port = ciq.getRemoteport(); @@ -136,6 +136,12 @@ public class JingleNodesHarvester " local port: " + ciq.getLocalport()); } + if (ip == null || ciq.getRemoteport() == 0) + { + logger.warn("JN relay ignored because ip was null or port 0"); + return candidates; + } + /* RTP */ TransportAddress relayedAddress = new TransportAddress(ip, port, Transport.UDP); @@ -160,6 +166,7 @@ public class JingleNodesHarvester candidates.add(local); } } + return candidates; } |