diff options
author | Tobias Markmann <tm@ayena.de> | 2015-12-09 15:07:28 (GMT) |
---|---|---|
committer | Swift Review <review@swift.im> | 2015-12-17 18:21:38 (GMT) |
commit | 29e8802886c0cb881e08a60cf0ea104e67577253 (patch) | |
tree | f824749084f7eaacac5f0df7bb386414047da149 /Swiften/FileTransfer | |
parent | 2dbf59832c5410e568b72fa908c5f40f24deec64 (diff) | |
download | swift-29e8802886c0cb881e08a60cf0ea104e67577253.zip swift-29e8802886c0cb881e08a60cf0ea104e67577253.tar.bz2 |
Do not advertise link-local IPv6 addresses in FT candidates
Test-Information:
Ran a file-transfer between two Swift instances and verified
no fe80:... addresses are included in the candidates.
Change-Id: I51dedb6aff95686764f74bf61ab2963e51ecbd1c
Diffstat (limited to 'Swiften/FileTransfer')
-rw-r--r-- | Swiften/FileTransfer/LocalJingleTransportCandidateGenerator.cpp | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/Swiften/FileTransfer/LocalJingleTransportCandidateGenerator.cpp b/Swiften/FileTransfer/LocalJingleTransportCandidateGenerator.cpp index fd0e571..f6e6963 100644 --- a/Swiften/FileTransfer/LocalJingleTransportCandidateGenerator.cpp +++ b/Swiften/FileTransfer/LocalJingleTransportCandidateGenerator.cpp @@ -142,6 +142,10 @@ void LocalJingleTransportCandidateGenerator::emitOnLocalTransportCandidatesGener // get direct candidates std::vector<HostAddressPort> directCandidates = s5bServerManager->getHostAddressPorts(); foreach(HostAddressPort addressPort, directCandidates) { + if (addressPort.getAddress().getRawAddress().is_v6() && + addressPort.getAddress().getRawAddress().to_v6().is_link_local()) { + continue; + } JingleS5BTransportPayload::Candidate candidate; candidate.type = JingleS5BTransportPayload::Candidate::DirectType; candidate.jid = ownJID; |