Timeline


and

11/12/13:

20:26 Changeset in swish [1c56cb0] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Pass provider to non-owning code as a reference.

19:56 Changeset in swish [45982a8] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Give session_pool complete control over the session lifetimes.

Instead of being stored and retrieved using shared_ptr<session_pool>, they are now stored non-copyably. This means when they are removed from the pool the are immediately disconnected.

Part of out effort to allow the user to force-disconnect a connection. See #85.

13:54 Changeset in swish [318061c] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Reduced some of the unnecessary passing around of consumers.

They key was removing it from the CSftpDirectory constructor. They are only used for renaming and authenticating sessions now.

12:18 Changeset in swish [d4dc6c9] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Removed responsibility for connecting from CProvider.

Now this is done outside and an already-connected session is passed to it. Also means most of the methods don't need a consumer any more because they only used it for connecting.

10:51 Changeset in swish [81ad001] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Simplify ProviderFixture?.

The architecture has changed so it's no longer important whether providers are mortal or immortal. Splitting into two files helps prevent VS2005 compiler crashing as we can hide some complexity in the CPP file, which limits its spread.

08:59 Changeset in swish [c09a265] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Revive dead sessions properly.

We lost this once we started fetching sessions from the pool inside the provider. That meant we should have been clearing them from the pool if they died. This wasn't necessary when we were storing providers in the pool because they handled it internally.

07:22 Changeset in swish [f4e54f4] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Stop lazy session creation inside consumer.

The proper way to do it is to lazily-create the provider, not lazily create the session inside the provider. That just overcomplicates the provider's implementation.

10/12/13:

19:18 Changeset in swish [7b7c034] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Removed unused session_from_pidl function.

19:11 Changeset in swish [865677d] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Decoupled session pooling from CProvider.

This is part of getting better control over the session's lifetime, which we need to do to be sure a session is disconnected (see #85).

11:44 Changeset in swish [6706d31] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Testing swapping sessions after connecting filesystem.

11:30 Changeset in swish [4c1917c] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Remove unused (and unwanted) raw_attributes method.

11:23 Changeset in swish [4957fd4] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Make internal state classes non-movable to enforce public class references remaining valid across moves.

Each internal state object is owned by a movable public class. The public class can create other object by passing them non-owning references to the internal state object so, if those object are to remain valid after their creator is moved, the state must remain in the same place. Holding the state in an auto_ptr and making the state non-copyable, non-movable enforces that.

09/12/13:

21:27 Changeset in swish [4ad9ee0] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Make SSH classes non-copyable to better reflect their underlying concepts.

SSH sessions, for instance, are not inherently copyable so making the class that represents the copyable is somewhat misleading. The most important flaw was that a session is not shut down until all _copies_ of the object are destroyed, making it very hard to guarantee a session has been disconnected.

This change fixes that by making the objects non-copyable to their underlying session/channel/handle is destroyed at the same time as the representing object.

21:21 Ticket #252 (connection timeout) closed by alamaison
worksforme
18:55 Changeset in swish [fe88456] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Ensure SSH library classes move correctly.

Includes new unit-tests to exercise this properly.

10:19 Changeset in swish [c2c14ac] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Make non-owning functions take state by reference.

Some functions were session, sftp and file handle state as a shared_ptr. This implied that the functions would need shared ownership of the objects, but they only use the objects and return. This commit makes them take references instead, making clear the role of those parameters.

07/12/13:

17:06 Ticket #259 (HRESULT: E_fail Dynamic exception type: class) created by gf
HRESULT: E_fail Dynamic exception type: class commet::com_error …

06/12/13:

13:58 Ticket #258 (Automatically prompt to add host if none already added) created by jgnell062@googlemail.com
Swish installed in My Win 8 64 bit system, But when I click on the swish …
12:10 Changeset in swish [69b27b6] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Prevent host_key depending on session lifetime.

Instead of storing a reference to the session and copying out data on demand, the commit makes host_key copy all the data from session (actually session_state) on construction. This means host_key doesn't depend on the session being alive afterwards, which will make our planned changes to session lifetime less disruptive.

The performance impact should be minimal. The data is just copied from the session. No extra calculation is needed and certainly no trips to the network.

11:57 Changeset in swish [dec1011] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Encapsulate agent state in RAII class.

Makes the two-stage startup/shutdown much clearer. This will also make it easier to implement the planned changes to the session copy semantics.

07:15 Changeset in swish [ceaf271] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Make sessions create the sftp_filesystem instances to better reflect their relationship.

sftp_filesystem is not implemented using the public interface of session, yet passing the latter to the former's constructor implies that relationship. Really, sftp_filesystem is an extension of session's intrinsic function so it should be up to session to create them using its privates.

06:40 Changeset in swish [3d56a84] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Remove redundant external session locking.

It's no longer needed now that the ssh library handles it internally.

06:08 Changeset in swish [48ef0a8] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Reducing large test data size to speed up unit tests.

Still multiple buffers worth.

05:58 Changeset in swish [742c600] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Fix non-thread-safe SFTP object destruction.

There was a bug in our session locking where the session could be locked during an operation on one thread and meanwhile another thread was destroying a libssh2 file handle or SFTP channel. The destructors weren't locking the session so they would not wait for the operation that had locked the thread to complete. This would corrupt the session and lead to all kinds of nastyness.

This change fixes the problem by giving file handles and SFTP channels their own RAII classes that gracefully handle their shutdown (instead of relying on shared_ptr which makes it less clear what's happening) and lock the session before doing so.

05/12/13:

12:59 Changeset in swish [bf235e9] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Make use of same session from multiple threads safe.

04/12/13:

08:22 Changeset in swish [3dc1e3a] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Manage internal session lifetime with custom RAII class.

This is clearer than using shared_ptr because of the session's two-step startup. Also, this will make it easier to add session locking for thread-safety in the future.

03/12/13:

21:04 Changeset in swish [036f532] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Removed ssh::agent, ssh::host_key and ssh::knownhost namespaces.

Moved their contents to top-level ssh namespace. There was no real reason for these namespaces and they made the implementation more verbose (especially accessing stuff in ssh::detail from within them). Also renames some classes to make them stand along better now their parent namespace no longer describes them.

20:28 Changeset in swish [e80a296] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Fix keyboard-interactive authentication error reporting.

We forgot to pass the error code to ssh::detail::libssh2::userauth::keyboard_interactive_ex, so failures to authenticate were being thrown as exceptions rather than prompting the user to try again (we think). Also we were passing a session parameter to translate_status that we no longer need to process errors.

14:51 Changeset in swish [6fe67e5] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Renamed ssh::sftp namespace to ssh::filesystem to reflect its mirroring of Boost.Filesystem.

14:35 Changeset in swish [03cd357] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Renamed sftp_channel to sftp_filesystem.

The new name better reflects what the class represents. The users couldn't care less that the class is implemented over an SFTP channel, just that it gives access to a remote filesystem.

12:43 Changeset in swish [985db64] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Remove accessors to sftp_channel private members.

The sftp_channel class was exposing its privates publicly via two accessor methods, session and get. Obviously bad.

This commit removes those accessors. A side effect of this is that most SFTP filesystem operations become methods of sftp_channel as they need access to the channels private members. Really they always should have been methods as they are intrinsic to the nature of a filesystem, not higher-level operations implemented in terms of what a filesystem offers.

A similar side effect is that instances of directory_iterator are now created via sftp_channel. This is because the iterator implements intrinsic operations of the channel so it makes sense that the channel creates the iterator as an extension of itself rather than the iterator taking the channel as a parameter. The latter would imply that the iterator operated on the public interface of the channel, which it does not.

The same change should be extended to the SFTP stream classes but that remains for a future commit. For the moment, they are made friends so that can access the channel's privates.

02/12/13:

08:52 Changeset in swish [c2088a5] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Improved error wrapper docs.

08:33 Changeset in swish [5ae8d21] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Replaced remaining references to ssh_error.

08:12 Changeset in swish [88d999f] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Replaced remaining uses of ssh_error in session management.

Replaced it with boost::system::system_error as we are doing for all libssh2 API errors. At the same time we added non-throwing alternatives to the ssh::detail::libssh2::session namespace.

07:52 Changeset in swish [a0cc81f] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Refactored keyboard-interactive authentication to use ssh::detail::libssh2::userauth namespace.

Moved it to the namespace as we are trying to move all calls to the libssh2 library there. This also meant changing the error reporting to use the system_errors used in that namespace.

07:18 Changeset in swish [8a977cc] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Refactored known-host write-line use ssh::detail::libssh2::knownhost namespace.

Moved it to the namespace as we are trying to move all calls to the libssh2 library there. This also meant changing the error reporting to use the system_errors used in that namespace. Made necessary changes to ssh_error_category to distinguish insufficient buffer space from other errors in a portable manner.

06:43 Changeset in swish [d049c76] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Cleaned up use of ssh::detail::libssh2::agent::get_identities.

Eliminates warnings about conversion to bool.

06:39 Changeset in swish [ed4f1c8] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Replaced remaining uses of ssh_error in known-host processing.

Replaced it with boost::system::system_error as we are doing for all libssh2 API errors. At the same time we added non-throwing alternatives to the ssh::detail::libssh2::knownhost namespace.

01/12/13:

20:55 Changeset in swish [f8ad912] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Replaced remaining uses of ssh_error in public-key authentication.

Replaced it with boost::system::system_error as we are doing for all libssh2 API errors.

18:02 Changeset in swish [b026343] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Refactored authentication method negotiation to use ssh::detail::libssh2::userauth namespace.

Moved it to the namespace as we are trying to move all calls to the libssh2 library there.

14:27 Changeset in swish [4d02bc2] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Refactored password authentication to use ssh::detail::libssh2::userauth namespace.

Moved it to the namespace as we are trying to move all calls to the libssh2 library there. This also meant changing the error reporting to use the system_errors used in that namespace. Made necessary changes to ssh_error_category to distinguish authentication failure from other errors in a portable manner.

14:15 Changeset in swish [3fa0071] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Added missing copy commands for ssh project test-fixture files.

The ssh project was depending on the test-common_boost project being built first, which copied the files as well. But the ssh project should be entirely independent.

30/11/13:

07:36 Changeset in swish [28f90ad] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Throwing system_error from sftp code instead of sftp_error.

The main reason is to make it easier to give a non-throwing alternative in the future using error_codes. This commit already adds non-throwing alternatives to the ssh::detail::libssh2::sftp namespace. The rest will follow in due course.

The Boost.System hierarchy is precisely suited to translating library-specific errors to portable abstractions. This commit already supports that for certain FX_* values such as FX_NO_SUCH_FILE translated to errc::no_such_file_or_directory.

29/11/13:

11:25 Ticket #257 (GUI: position of text entry box [foreign language]) created by Bilou Gateux
French language is less concise compared to English. text entry box …

28/11/13:

18:25 Changeset in swish [5325608] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Created exception-wrapper functions for libssh2 knownhost functions.

12:45 Changeset in swish [8078199] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Documented ssh::detail::libssh2 namespace.

12:41 Changeset in swish [7dc3753] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Moved libssh2 userauth exception-wrapper functions into ssh::detail::libssh2 namespace.

12:22 Changeset in swish [9fc53d6] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Moved libssh2 session exception-wrapper functions into ssh::detail::libssh2 namespace.

11:39 Changeset in swish [724db42] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Moved libssh2 agent exception-wrapper functions into ssh::detail::libssh2 namespace.

10:06 Changeset in swish [54e9c8d] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Moved libssh2 SFTP exception-wrapper functions into ssh::detail::libssh2 namespace.

This is the first stage of a refactoring that will eventually have all libssh2 exception wrappers in the ssh::detail::libssh2 namespace. This helps us define a boundary for the yet-to-be-implemented thread locking. Any functions in the ssh::detail::libssh2 namespace must not perform any locking but the session must be locked before they are called. This ensure the exception throw definitely correspond to the function called.

Also removed the requirement that the pointers be supplied as shared_ptrs. These functions should be usable however we finally decide to manage the pointers, which may well not be using a shared_ptr as they make object lifetime difficult to control.

08:34 Changeset in swish [887c485] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Suppressed keyboard-interactive auth tests that will (currently) never pass.

These just produce noise for every build. Yes we do need to find a way to test kb-int auth but, as that is not likely to happen soon, it's not doing any good to be reminded of this on every build.

08:12 Changeset in swish [3671273] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Move sftp_error into separate file.

This will help when we come to separate out all the libssh2 exception-wrapper functions which depends on ssh_error and sftp_error but must depend on nothing else. If sftp_error were still in sftp.hpp, these wrappers would include everything in that file.

07:45 Changeset in swish [34567f1] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Removed #pragma once declarations.

They aren't portable and aren't needed.

07:41 Changeset in swish [9dc3852] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Removed public accessor to raw session pointer from ssh::session.

The class that needs it, sftp_channel is now granted sole access to it via the Attorney-Client idiom.

This improved encapsulation is one small step to getting control of where references to the session are held, which we will need eventually to do thread-safe session locking.

27/11/13:

10:05 Changeset in swish [62550ef] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Make knownhost_iterator constructors private.

When knownhost_iterator required a session or hosts collection (i.e. non-end), it must be created via knownhost_collection. Therefore we make the constructors private and declare knownhost_collection a friend so that it can call them.

09:21 Changeset in swish [218cb7f] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Remove need for session parameter in knownhost class constructors.

The session is only used for memory allocation. It doesn't need to be connected to anything so we just create a new session internally. Saves the caller having to find a session from somewhere when they might not otherwise be using one.

08:11 Changeset in swish [208fa62] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Remove raw session accessor from running_session.

06:08 Ticket #231 (Swish 073 - Error time file) closed by alamaison
fixed: In [a17c4b96a36ab4772e1ef0836bf47961a1fc878f/swish]: […]
06:02 Changeset in swish [da7d436] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Merge branch 'feauture/fix_time_zone' into develop

26/11/13:

21:02 Changeset in swish [3e77464] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Remove CSftpStream which is no longer used.

20:59 Changeset in swish [a42e492] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Remove raw session accessors from authenticated_session.

20:41 Changeset in swish [60e7d94] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Fix authentication test mock setup.

20:38 Changeset in swish [c494707] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Test new SFTP stream instead of CSftpStream.

13:05 Ticket #256 (Improve write performance with larger COPY_CHUNK_SIZE) created by alamaison
We can copy files to server faster with a bigger COPY_CHUNK_SIZE (and …
06:09 Changeset in swish [24480af] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Allow the user to set SFTP stream buffer size.

Also uses a better default that gives better performance.

25/11/13:

08:16 Ticket #255 (Opening corrupt EXE gives double error message) created by alamaison
Double-clicking an EXE that Windows can't execute causes two error message …
08:05 Changeset in swish [ed83dcd] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Fix lost data during SFTP stream read/write.

The SFTP devices were simply calling the libssh2 read/write functions directly. These functions can return 'short' to allow non-blocking read/write but the Boost.IOStreams stream template requires _blocking_ devices.

This commit makes sure the devices complete the requested read/write before returning.

29/10/13:

19:44 Changeset in swish [fa1709f] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Overloaded constructors to open SFTP streams using std::ios_base flags.

We use our own flags to provide extra features (nocreate, noreplace) not provided by the standard flags, but we shouldn't force users to use them when the behaviour they need is already covered by the standard flags.

This change adds overloads to allow them to use the standard flags.

18:58 Changeset in swish [b2c5d42] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Test SFTP file stream handling of read-only files.

23/10/13:

17:34 Changeset in swish [69b11a4] by alamaison
mastercmakedevelopfeature/vs2015release/0.8.0wip_vs_2015

Use libssh2 wrapper streams instead of CSftpStream

The streams are adapted to the necessary IStream interface using the Comet C++-stream-to-COM-IStream wrapper.

The libssh2 thread wrappers are _not yet thread safe_ so we still need to work on that.

Note: See TracTimeline for information about the timeline view.