summaryrefslogtreecommitdiffstats
AgeCommit message (Collapse)Author
2016-11-28Correctly handle server initiated closing of streamTobias Markmann
If a server closes the XMPP stream, it sends a </stream:stream> tag. The client is supposed to respond with the same tag and then both parties can close the TLS/TCP socket. Previously Swift(-en) would simply ignore </stream:stream> tag if it was not directly followed by a shutdown of the TCP connection. In addition there is now a timeout timer started as soon as Swiften or the server initiates a shutdown. It will close the socket and cleanup the ClientSession if the server does not respond in time or the network is faulty. Refactored some code in ClientSession in the process. Moved ClientSession::State to a C++11 strongly typed enum class. This also fixes issues where duplicated </stream:stream> tags would be send by Swift. Test-Information: Tested against Prosody ba782a093b14 and M-Link 16.3v6-0, which provide ad-hoc commands to end a user session. Previously this was ignored by Swift. Now it correctly responds to the server, detects it as a disconnect and tries to reconnect afterwards. Added unit test for the case where the server closes the session stream. Change-Id: I59dfde3aa6b50dc117f340e5db6b9e58b54b3c60
2016-04-05Migrate to Boost.Signals2 from Boost.SignalsTobias Markmann
Boost.Signals was deprecated and is not improved further. This patch removes Boost.Signals from 3rdParty and adds Boost.Signals2 and its dependencies. Also removed the Qt signals compatibility file Swiften/Base/boost_bsignals.h. Test-Information: Build and ran unit tests on OS X 10.11.4. Confirmed successful login using Swift client. Change-Id: Ie6e3b2d15aac2462cda95401582f5287a479fb54
2016-04-04Modernize code to use C++11 shared_ptr instead of Boost'sTobias Markmann
This change was done by applying the following 'gsed' replacement calls to all source files: 's/\#include <boost\/shared_ptr\.hpp>/\#include <memory>/g' 's/\#include <boost\/enable_shared_from_this\.hpp>/\#include <memory>/g' 's/\#include <boost\/smart_ptr\/make_shared\.hpp>/\#include <memory>/g' 's/\#include <boost\/make_shared\.hpp>/\#include <memory>/g' 's/\#include <boost\/weak_ptr\.hpp>/\#include <memory>/g' 's/boost::make_shared/std::make_shared/g' 's/boost::dynamic_pointer_cast/std::dynamic_pointer_cast/g' 's/boost::shared_ptr/std::shared_ptr/g' 's/boost::weak_ptr/std::weak_ptr/g' 's/boost::enable_shared_from_this/std::enable_shared_from_this/g' The remaining issues have been fixed manually. Test-Information: Code builds on OS X 10.11.4 and unit tests pass. Change-Id: Ia7ae34eab869fb9ad6387a1348426b71ae4acd5f
2016-03-31Convert tabs to 4 spaces for all source filesTobias Markmann
Removed trailing spaces and whitespace on empty lines in the process. Changed CheckTabs.py tool to disallow hard tabs in source files. Test-Information: Manually checked 30 random files that the conversion worked as expected. Change-Id: I874f99d617bd3d2bb55f02d58f22f58f9b094480
2016-01-15Add missing virtual keyword to some destructorsTobias Markmann
Adds missing virtual keyword to destructors of classes which have a non-empty destructor and are inheriting from other classes and implement virtual functions. Test-Information: Compiles and unit tests pass on Windows 8 with VS 2013. Change-Id: I172b5de8eda63eb8057113fbc979444abde3e0a7
2014-12-15Update Copyright in SwiftenKevin Smith
Change-Id: I94ab4bbb68c603fe872abeb8090575de042f5cb4
2014-10-13Correctly set 'jabber:client' namespace on message/presence/IQ stanzas for ↵Tobias Markmann
BOSH connections. Test-Information: Tested with Swift and interoperability against Psi. Swift debug log now correctly shows the namespace being set. Previously Psi did not display the body of messages due to them being in the worng namespace. Now as they are in the correct namespace messages are displayed correctly by Psi. Change-Id: I547e335100abebfcf170cf7f41b86fd2dbb01692
2014-04-28Create ToplevelElement to replace Element.Richard Maudsley
Change-Id: I3460f6f4a2ffa9b795080664f49d9138440de72d
2012-07-14Initial DLL support for Swiften.Remko Tronçon
All applications succesfully link against Swiften.dll.
2011-12-13BOSH Support for SwiftenKevin Smith
This adds support for BOSH to Swiften. It does not expose it to Swift. Release-Notes: Swiften now allows connects over BOSH, if used appropriately.
2011-10-07Hoist XML parser factory creation out of Swiften.Remko Tronçon
2011-05-18Propagate use of SafeByteArray down to the connection.Remko Tronçon
2011-04-30Replace #icnlude "" by #include <> in Swiften.Remko Tronçon
2011-02-14Removed Swift::String.Remko Tronçon
2010-12-20Fixing unit tests for StreamStackKevin Smith
2010-12-19Refactoring streamstack to not use signal/slots.Remko Tronçon
2010-10-15Added Component parser, serializer, element, and connector.Remko Tronçon
2010-06-02Rename boost_signalslib.h to boost_bsignals.Remko Tronçon
2010-06-02Using Boost workaround for Qt signals keyword clash.Remko Tronçon
This should allow us to link against system boost versions.
2010-04-08Added copyrights to Swiften.Kevin Smith
2010-03-28Moving submodule contents back.Remko Tronçon
2010-03-28Removing submodules.Remko Tronçon
2010-03-28Moved Swiften to a separate module.Remko Tronçon
2009-07-18Implement incoming linklocal connections.Remko Tronçon
2009-07-13Server stream header support.Remko Tronçon
2009-07-12Added ServerFromClientSession.Remko Tronçon
2009-06-01Import.Remko Tronçon