Browse Source

Remove documention content and move code examples into test and code comments

olegkap_cp 12 years ago
parent
commit
6d2604948d
53 changed files with 674 additions and 2354 deletions
  1. 1 16
      Renci.SshClient/Renci.SshNet.NET35/Renci.SshNet.NET35.csproj
  2. 1 1
      Renci.SshClient/Renci.SshNet.Silverlight/Renci.SshNet.Silverlight.csproj
  3. 1 1
      Renci.SshClient/Renci.SshNet.Silverlight5/Renci.SshNet.Silverlight5.csproj
  4. 27 0
      Renci.SshClient/Renci.SshNet.Tests/Classes/ForwardedPortLocalTest.cs
  5. 29 0
      Renci.SshClient/Renci.SshNet.Tests/Classes/ForwardedPortRemoteTest.cs
  6. 36 0
      Renci.SshClient/Renci.SshNet.Tests/Classes/KeyboardInteractiveConnectionInfoTest.cs
  7. 67 4
      Renci.SshClient/Renci.SshNet.Tests/Classes/PasswordConnectionInfoTest.cs
  8. 49 1
      Renci.SshClient/Renci.SshNet.Tests/Classes/PrivateKeyConnectionInfoTest.cs
  9. 100 3
      Renci.SshClient/Renci.SshNet.Tests/Classes/SshClientTest.cs
  10. 38 0
      Renci.SshClient/Renci.SshNet.Tests/Classes/SshCommandTest.NET40.cs
  11. 160 15
      Renci.SshClient/Renci.SshNet.Tests/Classes/SshCommandTest.cs
  12. 27 0
      Renci.SshClient/Renci.SshNet.Tests/Data/Key.RSA.txt
  13. 3 1
      Renci.SshClient/Renci.SshNet.Tests/Renci.SshNet.Tests.csproj
  14. 1 1
      Renci.SshClient/Renci.SshNet.WindowsPhone/Renci.SshNet.WindowsPhone.csproj
  15. 1 1
      Renci.SshClient/Renci.SshNet.WindowsPhone8/Renci.SshNet.WindowsPhone8.csproj
  16. 8 2
      Renci.SshClient/Renci.SshNet/BaseClient.cs
  17. 6 0
      Renci.SshClient/Renci.SshNet/ConnectionInfo.cs
  18. 0 55
      Renci.SshClient/Renci.SshNet/Documentation/Content/About.aml
  19. 0 59
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/Interactive.aml
  20. 0 311
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/Overview.aml
  21. 0 140
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/Password.aml
  22. 0 201
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/PrivateKey.aml
  23. 0 49
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Errors.aml
  24. 0 82
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/NetConfClient/Overview.aml
  25. 0 103
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Overview.aml
  26. 0 82
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/ScpClient/Overview.aml
  27. 0 82
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/Overview.aml
  28. 0 82
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/SftpFile.aml
  29. 0 82
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/SftpFileStream.aml
  30. 0 145
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/SftpOperations.aml
  31. 0 41
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Asynchronous.aml
  32. 0 36
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Errors.aml
  33. 0 70
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Execute.aml
  34. 0 38
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Multitasking.aml
  35. 0 327
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Overview.aml
  36. 0 31
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/StatusCode.aml
  37. 0 32
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Timeout.aml
  38. 0 31
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Overview.aml
  39. 0 30
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/PortForwarding/Local.aml
  40. 0 17
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/PortForwarding/Overview.aml
  41. 0 30
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/PortForwarding/Remote.aml
  42. 0 82
      Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Shell/Overview.aml
  43. 0 16
      Renci.SshClient/Renci.SshNet/Documentation/Content/Reference.aml
  44. 3 0
      Renci.SshClient/Renci.SshNet/ForwardedPortLocal.cs
  45. 3 0
      Renci.SshClient/Renci.SshNet/ForwardedPortRemote.cs
  46. 6 0
      Renci.SshClient/Renci.SshNet/KeyboardInteractiveConnectionInfo.cs
  47. 13 7
      Renci.SshClient/Renci.SshNet/PasswordConnectionInfo.cs
  48. 6 3
      Renci.SshClient/Renci.SshNet/PrivateKeyConnectionInfo.cs
  49. 1 2
      Renci.SshClient/Renci.SshNet/PrivateKeyFile.cs
  50. 0 31
      Renci.SshClient/Renci.SshNet/Renci.SshNet.csproj
  51. 19 8
      Renci.SshClient/Renci.SshNet/SshClient.cs
  52. 66 0
      Renci.SshClient/Renci.SshNet/SshCommand.cs
  53. 2 3
      Renci.SshClient/Renci.SshNet/SubsystemSession.cs

+ 1 - 16
Renci.SshClient/Renci.SshNet.NET35/Renci.SshNet.NET35.csproj

@@ -222,21 +222,6 @@
     <Compile Include="..\Renci.SshNet\ConnectionInfo.cs">
       <Link>ConnectionInfo.cs</Link>
     </Compile>
-    <Compile Include="..\Renci.SshNet\Examples\PasswordConnectionInfo.cs">
-      <Link>Examples\PasswordConnectionInfo.cs</Link>
-    </Compile>
-    <Compile Include="..\Renci.SshNet\Examples\PrivateKeyConnectionInfo.cs">
-      <Link>Examples\PrivateKeyConnectionInfo.cs</Link>
-    </Compile>
-    <Compile Include="..\Renci.SshNet\Examples\PrivateKeyFile.cs">
-      <Link>Examples\PrivateKeyFile.cs</Link>
-    </Compile>
-    <Compile Include="..\Renci.SshNet\Examples\SshClient.cs">
-      <Link>Examples\SshClient.cs</Link>
-    </Compile>
-    <Compile Include="..\Renci.SshNet\Examples\SshCommand.cs">
-      <Link>Examples\SshCommand.cs</Link>
-    </Compile>
     <Compile Include="..\Renci.SshNet\ExpectAction.cs">
       <Link>ExpectAction.cs</Link>
     </Compile>
@@ -845,7 +830,7 @@
   <Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
   <ProjectExtensions>
     <VisualStudio>
-      <UserProperties ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" />
+      <UserProperties ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" />
     </VisualStudio>
   </ProjectExtensions>
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 

+ 1 - 1
Renci.SshClient/Renci.SshNet.Silverlight/Renci.SshNet.Silverlight.csproj

@@ -797,7 +797,7 @@
       <FlavorProperties GUID="{A1591282-1198-4647-A2B1-27E5FF5F6F3B}">
         <SilverlightProjectProperties />
       </FlavorProperties>
-      <UserProperties ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" />
+      <UserProperties ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" />
     </VisualStudio>
   </ProjectExtensions>
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 

+ 1 - 1
Renci.SshClient/Renci.SshNet.Silverlight5/Renci.SshNet.Silverlight5.csproj

@@ -807,7 +807,7 @@
       <FlavorProperties GUID="{A1591282-1198-4647-A2B1-27E5FF5F6F3B}">
         <SilverlightProjectProperties />
       </FlavorProperties>
-      <UserProperties ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" />
+      <UserProperties ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" />
     </VisualStudio>
   </ProjectExtensions>
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 

+ 27 - 0
Renci.SshClient/Renci.SshNet.Tests/Classes/ForwardedPortLocalTest.cs

@@ -5,6 +5,7 @@ using Renci.SshNet.Tests.Properties;
 using System;
 using System.Diagnostics;
 using System.Net;
+using System.Threading;
 
 namespace Renci.SshNet.Tests.Classes
 {
@@ -103,6 +104,32 @@ namespace Renci.SshNet.Tests.Classes
             }
         }
 
+        /// <summary>
+        ///A test for ForwardedPortRemote Constructor
+        ///</summary>
+        [TestMethod()]
+        public void Test_ForwardedPortRemote()
+        {
+            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
+            {
+                #region Example SshClient AddForwardedPort Start Stop ForwardedPortLocal
+                client.Connect();
+                var port = new ForwardedPortLocal(8082, "www.cnn.com", 80);
+                client.AddForwardedPort(port);
+                port.Exception += delegate(object sender, ExceptionEventArgs e)
+                {
+                    Console.WriteLine(e.Exception.ToString());
+                };
+                port.Start();
+
+                Thread.Sleep(1000 * 60 * 20); //	Wait 20 minutes for port to be forwarded
+
+                port.Stop();
+                #endregion
+            }
+            Assert.Inconclusive("TODO: Implement code to verify target");
+        }
+
         /// <summary>
         ///A test for ForwardedPortLocal Constructor
         ///</summary>

+ 29 - 0
Renci.SshClient/Renci.SshNet.Tests/Classes/ForwardedPortRemoteTest.cs

@@ -1,8 +1,10 @@
 using Microsoft.VisualStudio.TestTools.UnitTesting;
+using Renci.SshNet.Common;
 using Renci.SshNet.Tests.Common;
 using Renci.SshNet.Tests.Properties;
 using System;
 using System.Net;
+using System.Threading;
 
 namespace Renci.SshNet.Tests.Classes
 {
@@ -40,6 +42,33 @@ namespace Renci.SshNet.Tests.Classes
             }
         }
 
+        /// <summary>
+        ///A test for ForwardedPortRemote Constructor
+        ///</summary>
+        [TestMethod()]
+        public void Test_ForwardedPortRemote()
+        {
+            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
+            {
+                #region Example SshClient AddForwardedPort Start Stop ForwardedPortRemote
+                client.Connect();
+                var port = new ForwardedPortRemote(8082, "www.cnn.com", 80);
+                client.AddForwardedPort(port);
+                port.Exception += delegate(object sender, ExceptionEventArgs e)
+                {
+                    Console.WriteLine(e.Exception.ToString());
+                };
+                port.Start();
+
+                Thread.Sleep(1000 * 60 * 20); //	Wait 20 minutes for port to be forwarded
+
+                port.Stop();
+                #endregion
+            }
+            Assert.Inconclusive("TODO: Implement code to verify target");
+        }
+
+
         /// <summary>
         ///A test for Stop
         ///</summary>

+ 36 - 0
Renci.SshClient/Renci.SshNet.Tests/Classes/KeyboardInteractiveConnectionInfoTest.cs

@@ -1,5 +1,8 @@
 using Microsoft.VisualStudio.TestTools.UnitTesting;
+using Renci.SshNet.Common;
 using Renci.SshNet.Tests.Common;
+using Renci.SshNet.Tests.Properties;
+using System;
 
 namespace Renci.SshNet.Tests.Classes
 {
@@ -9,6 +12,39 @@ namespace Renci.SshNet.Tests.Classes
     [TestClass]
     public class KeyboardInteractiveConnectionInfoTest : TestBase
     {
+        [TestMethod]
+        [TestCategory("KeyboardInteractiveConnectionInfo")]
+        public void Test_KeyboardInteractiveConnectionInfo()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example KeyboardInteractiveConnectionInfo AuthenticationPrompt
+            var connectionInfo = new KeyboardInteractiveConnectionInfo(host, username);
+            connectionInfo.AuthenticationPrompt += delegate(object sender, AuthenticationPromptEventArgs e)
+            {
+                System.Console.WriteLine(e.Instruction);
+
+                foreach (var prompt in e.Prompts)
+                {
+                    Console.WriteLine(prompt.Request);
+                    prompt.Response = Console.ReadLine();
+                }
+            };
+
+            using (var client = new SftpClient(connectionInfo))
+            {
+                client.Connect();
+                //  Do something here
+                client.Disconnect();
+            }
+            #endregion
+
+            Assert.AreEqual(connectionInfo.Host, Resources.HOST);
+            Assert.AreEqual(connectionInfo.Username, Resources.USERNAME);
+        }
+
         /// <summary>
         ///A test for Dispose
         ///</summary>

+ 67 - 4
Renci.SshClient/Renci.SshNet.Tests/Classes/PasswordConnectionInfoTest.cs

@@ -1,4 +1,5 @@
 using Microsoft.VisualStudio.TestTools.UnitTesting;
+using Renci.SshNet.Common;
 using Renci.SshNet.Tests.Common;
 using Renci.SshNet.Tests.Properties;
 using System;
@@ -14,17 +15,79 @@ namespace Renci.SshNet.Tests.Classes
     {
         [TestMethod]
         [TestCategory("PasswordConnectionInfo")]
-        [ExpectedException(typeof(ArgumentException))]
-        public void Test_ConnectionInfo()
+        public void Test_PasswordConnectionInfo()
         {
-            #region ExampleConnectionInfo
-            var connectionInfo = new PasswordConnectionInfo(Resources.HOST, Resources.USERNAME, Resources.PASSWORD);
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example PasswordConnectionInfo
+            var connectionInfo = new PasswordConnectionInfo(host, username, password);
+            using (var client = new SftpClient(connectionInfo))
+            {
+                client.Connect();
+                //  Do something here
+                client.Disconnect();
+            }
             #endregion
 
             Assert.AreEqual(connectionInfo.Host, Resources.HOST);
             Assert.AreEqual(connectionInfo.Username, Resources.USERNAME);
         }
 
+        [TestMethod]
+        [TestCategory("PasswordConnectionInfo")]
+        public void Test_PasswordConnectionInfo_PasswordExpired()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example PasswordConnectionInfo PasswordExpired
+            var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
+            var encoding = new Renci.SshNet.Common.ASCIIEncoding();
+            connectionInfo.PasswordExpired += delegate(object sender, AuthenticationPasswordChangeEventArgs e)
+            {
+                e.NewPassword = encoding.GetBytes("123456");
+            };
+
+            using (var client = new SshClient(connectionInfo))
+            {
+                client.Connect();
+
+                client.Disconnect();
+            }
+            #endregion
+
+            Assert.Inconclusive();
+        }
+        [TestMethod]
+        [TestCategory("PasswordConnectionInfo")]
+        public void Test_PasswordConnectionInfo_AuthenticationBanner()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example PasswordConnectionInfo AuthenticationBanner
+            var connectionInfo = new PasswordConnectionInfo(host, username, password);
+            connectionInfo.AuthenticationBanner += delegate(object sender, AuthenticationBannerEventArgs e)
+            {
+                Console.WriteLine(e.BannerMessage);
+            };
+            using (var client = new SftpClient(connectionInfo))
+            {
+                client.Connect();
+                //  Do something here
+                client.Disconnect();
+            }
+            #endregion
+
+            Assert.AreEqual(connectionInfo.Host, Resources.HOST);
+            Assert.AreEqual(connectionInfo.Username, Resources.USERNAME);
+        }
+
+
         [WorkItem(703), TestMethod]
         [TestCategory("PasswordConnectionInfo")]
         [ExpectedException(typeof(ArgumentException))]

+ 49 - 1
Renci.SshClient/Renci.SshNet.Tests/Classes/PrivateKeyConnectionInfoTest.cs

@@ -1,5 +1,8 @@
 using Microsoft.VisualStudio.TestTools.UnitTesting;
 using Renci.SshNet.Tests.Common;
+using Renci.SshNet.Tests.Properties;
+using System.IO;
+using System.Text;
 
 namespace Renci.SshNet.Tests.Classes
 {
@@ -8,7 +11,52 @@ namespace Renci.SshNet.Tests.Classes
     /// </summary>
     [TestClass]
     public class PrivateKeyConnectionInfoTest : TestBase
-    {        
+    {
+        [TestMethod]
+        [TestCategory("PrivateKeyConnectionInfo")]
+        public void Test_PrivateKeyConnectionInfo()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            MemoryStream keyFileStream = new MemoryStream(Encoding.ASCII.GetBytes(Resources.RSA_KEY_WITHOUT_PASS));
+
+            #region Example PrivateKeyConnectionInfo PrivateKeyFile
+            var connectionInfo = new PrivateKeyConnectionInfo(host, username, new PrivateKeyFile(keyFileStream));
+            using (var client = new SshClient(connectionInfo))
+            {
+                client.Connect();
+                client.Disconnect();
+            }
+            #endregion
+
+            Assert.AreEqual(connectionInfo.Host, Resources.HOST);
+            Assert.AreEqual(connectionInfo.Username, Resources.USERNAME);
+        }
+
+        [TestMethod]
+        [TestCategory("PrivateKeyConnectionInfo")]
+        public void Test_PrivateKeyConnectionInfo_MultiplePrivateKey()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            MemoryStream keyFileStream1 = new MemoryStream(Encoding.ASCII.GetBytes(Resources.RSA_KEY_WITHOUT_PASS));
+            MemoryStream keyFileStream2 = new MemoryStream(Encoding.ASCII.GetBytes(Resources.RSA_KEY_WITHOUT_PASS));
+
+            #region Example PrivateKeyConnectionInfo PrivateKeyFile Multiple
+            var connectionInfo = new PrivateKeyConnectionInfo(host, username, 
+                new PrivateKeyFile(keyFileStream1), 
+                new PrivateKeyFile(keyFileStream2));
+            using (var client = new SshClient(connectionInfo))
+            {
+                client.Connect();
+                client.Disconnect();
+            }
+            #endregion
+
+            Assert.AreEqual(connectionInfo.Host, Resources.HOST);
+            Assert.AreEqual(connectionInfo.Username, Resources.USERNAME);
+        }
+
         /// <summary>
         ///A test for Dispose
         ///</summary>

+ 100 - 3
Renci.SshClient/Renci.SshNet.Tests/Classes/SshClientTest.cs

@@ -2,9 +2,11 @@
 using Renci.SshNet.Common;
 using Renci.SshNet.Tests.Common;
 using Renci.SshNet.Tests.Properties;
+using System;
 using System.Collections.Generic;
 using System.IO;
 using System.Text;
+using System.Linq;
 
 namespace Renci.SshNet.Tests.Classes
 {
@@ -18,11 +20,95 @@ namespace Renci.SshNet.Tests.Classes
         [TestCategory("Authentication")]
         public void Test_Connect_Using_Correct_Password()
         {
-            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example SshClient(host, username) Connect
+            using (var client = new SshClient(host, username, password))
+            {
+                client.Connect();
+                //  Do something here
+                client.Disconnect();
+            }
+            #endregion
+        }
+
+        [TestMethod]
+        [TestCategory("Authentication")]
+        public void Test_Connect_Handle_HostKeyReceived()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example SshClient Connect HostKeyReceived
+            using (var client = new SshClient(host, username, password))
             {
+                client.HostKeyReceived += delegate(object sender, HostKeyEventArgs e)
+                {
+                    if (e.FingerPrint.SequenceEqual(new byte[] { 0x00, 0x01, 0x02, 0x03 }))
+                    {
+                        e.CanTrust = true;
+                    }
+                    else
+                    {
+                        e.CanTrust = false;
+                    }
+                };
                 client.Connect();
+                //  Do something here
                 client.Disconnect();
             }
+            #endregion
+            Assert.Inconclusive();
+        }
+
+        [TestMethod]
+        [TestCategory("Authentication")]
+        public void Test_Connect_Timeout()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example SshClient Connect Timeout
+            var connectionInfo = new PasswordConnectionInfo(host, username, password);
+
+            connectionInfo.Timeout = TimeSpan.FromSeconds(30);
+
+            using (var client = new SshClient(connectionInfo))
+            {
+                client.Connect();
+                //  Do something here
+                client.Disconnect();
+            }
+            #endregion
+            Assert.Inconclusive();
+        }
+
+        [TestMethod]
+        [TestCategory("Authentication")]
+        public void Test_Connect_Handle_ErrorOccurred()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            #region Example SshClient Connect ErrorOccurred
+            using (var client = new SshClient(host, username, password))
+            {
+                client.ErrorOccurred += delegate(object sender, ExceptionEventArgs e)
+                {
+                    Console.WriteLine("Error occured: " + e.Exception.ToString());
+                };
+
+                client.Connect();
+                //  Do something here
+                client.Disconnect();
+            }
+            #endregion
+            Assert.Inconclusive();
         }
 
         [TestMethod]
@@ -41,24 +127,35 @@ namespace Renci.SshNet.Tests.Classes
         [TestCategory("Authentication")]
         public void Test_Connect_Using_Rsa_Key_Without_PassPhrase()
         {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
             MemoryStream keyFileStream = new MemoryStream(Encoding.ASCII.GetBytes(Resources.RSA_KEY_WITHOUT_PASS));
-            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, new PrivateKeyFile(keyFileStream)))
+
+            #region Example SshClient(host, username) Connect PrivateKeyFile
+            using (var client = new SshClient(host, username, new PrivateKeyFile(keyFileStream)))
             {
                 client.Connect();
                 client.Disconnect();
             }
+            #endregion
         }
 
         [TestMethod]
         [TestCategory("Authentication")]
         public void Test_Connect_Using_RsaKey_With_PassPhrase()
         {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var passphrase = Resources.PASSWORD;
             MemoryStream keyFileStream = new MemoryStream(Encoding.ASCII.GetBytes(Resources.RSA_KEY_WITH_PASS));
-            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, new PrivateKeyFile(keyFileStream, Resources.PASSWORD)))
+
+            #region Example SshClient(host, username) Connect PrivateKeyFile PassPhrase
+            using (var client = new SshClient(host, username, new PrivateKeyFile(keyFileStream, passphrase)))
             {
                 client.Connect();
                 client.Disconnect();
             }
+            #endregion
         }
 
         [TestMethod]

+ 38 - 0
Renci.SshClient/Renci.SshNet.Tests/Classes/SshCommandTest.NET40.cs

@@ -8,6 +8,44 @@ namespace Renci.SshNet.Tests.Classes
 {
     public partial class SshCommandTest
     {
+
+        public void Test_MultipleThread_Example_MultipleConnections()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            try
+            {
+                #region Example SshCommand RunCommand Parallel
+                System.Threading.Tasks.Parallel.For(0, 10000,
+                    () =>
+                    {
+                        var client = new SshClient(host, username, password);
+                        client.Connect();
+                        return client;
+                    },
+                    (int counter, ParallelLoopState pls, SshClient client) =>
+                    {
+                        var result = client.RunCommand("echo 123");
+                        Debug.WriteLine(string.Format("TestMultipleThreadMultipleConnections #{0}", counter));
+                        return client;
+                    },
+                    (SshClient client) =>
+                    {
+                        client.Disconnect();
+                        client.Dispose();
+                    }
+                );
+                #endregion
+
+            }
+            catch (Exception exp)
+            {
+                Assert.Fail(exp.ToString());
+            }
+        }
+
         //[TestMethod]
         public void Test_MultipleThread_10000_MultipleConnections()
         {

+ 160 - 15
Renci.SshClient/Renci.SshNet.Tests/Classes/SshCommandTest.cs

@@ -27,16 +27,114 @@ namespace Renci.SshNet.Tests.Classes
             }
         }
 
+        [TestMethod]
+        public void Test_Run_SingleCommand()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            using (var client = new SshClient(host, username, password))
+            {
+                #region Example SshCommand RunCommand Result
+                client.Connect();
+
+                var testValue = Guid.NewGuid().ToString();
+                var command = client.RunCommand(string.Format("echo {0}", testValue));
+                var result = command.Result;
+                result = result.Substring(0, result.Length - 1);    //  Remove \n character returned by command
+
+                client.Disconnect();
+                #endregion
+
+                Assert.IsTrue(result.Equals(testValue));
+            }
+        }
+
         [TestMethod]
         public void Test_Execute_SingleCommand()
         {
-            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            using (var client = new SshClient(host, username, password))
             {
+                #region Example SshCommand CreateCommand Execute
                 client.Connect();
-                var result = ExecuteTestCommand(client);
+
+                var testValue = Guid.NewGuid().ToString();
+                var command = string.Format("echo {0}", testValue);
+                var cmd = client.CreateCommand(command);
+                var result = cmd.Execute();
+                result = result.Substring(0, result.Length - 1);    //  Remove \n character returned by command
+
                 client.Disconnect();
+                #endregion
 
-                Assert.IsTrue(result);
+                Assert.IsTrue(result.Equals(testValue));
+            }
+        }
+
+        [TestMethod]
+        public void Test_Execute_OutputStream()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            using (var client = new SshClient(host, username, password))
+            {
+                #region Example SshCommand CreateCommand Execute OutputStream
+                client.Connect();
+
+                var cmd = client.CreateCommand("ls -l");   //  very long list
+                var asynch = cmd.BeginExecute();
+
+                var reader = new StreamReader(cmd.OutputStream);
+
+                while (!asynch.IsCompleted)
+                {
+                    var result = reader.ReadToEnd();
+                    if (string.IsNullOrEmpty(result))
+                        continue;
+                    Console.Write(result);
+                }
+                cmd.EndExecute(asynch);
+
+                client.Disconnect();
+                #endregion
+
+                Assert.Inconclusive();
+            }
+        }
+
+        [TestMethod]
+        public void Test_Execute_ExtendedOutputStream()
+        {
+            var host = Resources.HOST;
+            var username = Resources.USERNAME;
+            var password = Resources.PASSWORD;
+
+            using (var client = new SshClient(host, username, password))
+            {
+                #region Example SshCommand CreateCommand Execute ExtendedOutputStream
+
+                client.Connect();
+                var cmd = client.CreateCommand("echo 12345; echo 654321 >&2");
+                var result = cmd.Execute();
+
+                Console.Write(result);
+
+                var reader = new StreamReader(cmd.ExtendedOutputStream);
+                Console.WriteLine("DEBUG:");
+                Console.Write(reader.ReadToEnd());
+
+                client.Disconnect();
+
+                #endregion
+
+                Assert.Inconclusive();
             }
         }
 
@@ -46,11 +144,13 @@ namespace Renci.SshNet.Tests.Classes
         {
             using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
             {
+                #region Example SshCommand CreateCommand Execute CommandTimeout
                 client.Connect();
                 var cmd = client.CreateCommand("sleep 10s");
                 cmd.CommandTimeout = TimeSpan.FromSeconds(5);
                 cmd.Execute();
                 client.Disconnect();
+                #endregion
             }
         }
 
@@ -147,12 +247,17 @@ namespace Renci.SshNet.Tests.Classes
         {
             using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
             {
+                #region Example SshCommand RunCommand ExitStatus
                 client.Connect();
 
                 var cmd = client.RunCommand("exit 128");
-                Assert.IsTrue(cmd.ExitStatus == 128);
+                
+                Console.WriteLine(cmd.ExitStatus);
 
                 client.Disconnect();
+                #endregion
+
+                Assert.IsTrue(cmd.ExitStatus == 128);
             }
         }
 
@@ -318,19 +423,59 @@ namespace Renci.SshNet.Tests.Classes
         [TestMethod()]
         public void BeginExecuteTest()
         {
-            Session session = null; // TODO: Initialize to an appropriate value
-            string commandText = string.Empty; // TODO: Initialize to an appropriate value
-            Encoding encoding = null; // TODO: Initialize to an appropriate value
-            SshCommand target = new SshCommand(session, commandText, encoding); // TODO: Initialize to an appropriate value
-            AsyncCallback callback = null; // TODO: Initialize to an appropriate value
-            object state = null; // TODO: Initialize to an appropriate value
-            IAsyncResult expected = null; // TODO: Initialize to an appropriate value
-            IAsyncResult actual;
-            actual = target.BeginExecute(callback, state);
-            Assert.AreEqual(expected, actual);
-            Assert.Inconclusive("Verify the correctness of this test method.");
+            string expected = "123\n";
+            string result;
+
+            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
+            {
+                #region Example SshCommand CreateCommand BeginExecute IsCompleted EndExecute
+
+                client.Connect();
+
+                var cmd = client.CreateCommand("sleep 15s;echo 123"); // Perform long running task
+
+                var asynch = cmd.BeginExecute();
+
+                while (!asynch.IsCompleted)
+                {
+                    //  Waiting for command to complete...
+                    Thread.Sleep(2000);
+                }
+                result = cmd.EndExecute(asynch);
+                client.Disconnect();
+
+                #endregion
+
+                Assert.IsNotNull(asynch);
+                Assert.AreEqual(expected, result);
+            }
+        }
+
+        [TestMethod]
+        public void Test_Execute_Invalid_Command()
+        {
+            using (var client = new SshClient(Resources.HOST, Resources.USERNAME, Resources.PASSWORD))
+            {
+                #region Example SshCommand CreateCommand Error
+
+                client.Connect();
+
+                var cmd = client.CreateCommand(";");
+                cmd.Execute();
+                if (!string.IsNullOrEmpty(cmd.Error))
+                {
+                    Console.WriteLine(cmd.Error);
+                }
+
+                client.Disconnect();
+
+                #endregion
+
+                Assert.Inconclusive();
+            }
         }
 
+
         /// <summary>
         ///A test for BeginExecute
         ///</summary>

+ 27 - 0
Renci.SshClient/Renci.SshNet.Tests/Data/Key.RSA.txt

@@ -0,0 +1,27 @@
+-----BEGIN RSA PRIVATE KEY-----
+MIIEoQIBAAKCAQEAuTtXn+BatX1oJuvhqfJZw5jc/pcIxJUPmuoFCH3+bXfKBJ/9
+4ixNETzZBasyvT/ozboAbCG3qcJOYxf2BEeTAIXe1jLAoTd1GKCwMvZOyjnsPN95
+/lChwfdnBbMzpZYTGfoUylXme/mzjjLu/J0qXgR5lyk9HFT+x5YEtRl8VSHiDkLK
+TZ37dwhsqgcs+PkfvYMUK+C8evnfE0tgWgKZk0Eatl87nLWyVXB4LzhSDtGKLCPA
+OgrX7fYfplDwJ2WK1N6nG0FnxW1HhDeSK7e2TbAa2vZQgvFXMWnO4O/NZKp4COpO
+ReyliWhdtKAjr/+cD4yDfPjhjjKOYfxbvdRG4QIBIwKCAQAqVrTxV9o4HKoXhl93
+TVZYl/f/rX5Y0Z0quSW4zFdpendRg6e+qwpNFTjrWlS9ivNiOSSrAGR+ktAWpmQe
+PD7bjFAw9ahfXSIUQfxja3+5Mc+Y4p+KlhZYOIyTlqy4Ik2CR8o84G8yR7QDPteK
+Mo1XUXrguPgGedPV2SWlvK60XyAXqsewDhi7SeImZomKzbh33SXjVxakzHfa8BEU
+eIIeR9oFlQMuYdo4GrHhFO2T+g/gqw/kVd1zkeEwt06fZVDErVwp+twewxxvwrk4
+CKUCzavfhDfi5sJ5YdzhDBRgkyBgJI+f15dKyqqOiAparV9+uzrD6vIuNnlVoqQA
+iugLAoGBAPBliy32e83nshBknBn5HOK2rO3a1zHxvYr/NzITXtdZOjatNyfXtkwi
+Ll/el5tZhJvKe9nItSI/4w7mvlvXZfW8h3MR0qb8at4jWa8ya2hwEerqaJonqjjb
++eBhg27ltZIQRk8Bv6ApXTAWkc+dFGhEIysokDQX7V72Bdrizup1AoGBAMVBLHK0
+5IFb8x7danlAmDX6bqCObId4Pce2OeONFIj1jIowvCXaE0t9zU4X5SdN5ujqu4Dq
+XgzUdNeKcJxWpFO74MDRxT3CbMz36fikJnvxWl/+q0HalYuCY8gm14VYcThUBAro
+3c941INueybGNLIA9jc7RMnsFtyVTvNYpaU9AoGAFJr9TRUgjf3qsPKuS15+0Zqh
+G7OsC5hgtCSBEuu3rA72XHU/Pe3rDdcLSgvD2h2dpvQZPo2L3l0/WQx2t2o78H3f
+uWftfAcB2Iav6nIJNNZn75BvXaug4E1ej5NUaJdYtL+Q/3UtrqR1s6opwVabWWTt
+ElPvGmhzboodwk30en8CgYAyuPzNCfGdm00lMZ8JPH7pTwaBDq4xdrDM9FgHUCna
+E0FlXP0uTgT2J6nSQKijtPI75JadfhgvL1E+vTLmX2wViBU45XvcrlZ92Vlr0nBL
+wbgnUB1otIzauyD49AuIsFegxSWcZ8QCJmKIMlouir0X1FyR3Apfzv6Qfio+kyNH
+vwKBgQCtwxojkzUSfV3zDt6bYSLBzgXgo/Zr9lS+gSggP72DzINmW2gbA0fkM2Zu
+JltcfakKv4gVX/1zooz+7t+4bj6dqt+bl7hYz0VnTSDZGuo5LKDif/4gSGrdblC2
+QLTuX2HjWCZdsue7mRwL7cXR4zlIoE99+Ryhdxvc5wHSfYr/JA==
+-----END RSA PRIVATE KEY-----

+ 3 - 1
Renci.SshClient/Renci.SshNet.Tests/Renci.SshNet.Tests.csproj

@@ -308,7 +308,9 @@
       <SubType>Designer</SubType>
     </EmbeddedResource>
   </ItemGroup>
-  <ItemGroup />
+  <ItemGroup>
+    <Content Include="Data\Key.RSA.txt" />
+  </ItemGroup>
   <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 
        Other similar extension points exist, see Microsoft.Common.targets.

+ 1 - 1
Renci.SshClient/Renci.SshNet.WindowsPhone/Renci.SshNet.WindowsPhone.csproj

@@ -797,7 +797,7 @@
   <Import Project="$(MSBuildExtensionsPath)\Microsoft\Silverlight for Phone\$(TargetFrameworkVersion)\Microsoft.Silverlight.CSharp.targets" />
   <ProjectExtensions>
     <VisualStudio>
-      <UserProperties ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" />
+      <UserProperties ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" />
     </VisualStudio>
   </ProjectExtensions>
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 

+ 1 - 1
Renci.SshClient/Renci.SshNet.WindowsPhone8/Renci.SshNet.WindowsPhone8.csproj

@@ -840,7 +840,7 @@
   <Import Project="$(MSBuildExtensionsPath)\Microsoft\$(TargetFrameworkIdentifier)\$(TargetFrameworkVersion)\Microsoft.$(TargetFrameworkIdentifier).CSharp.targets" />
   <ProjectExtensions>
     <VisualStudio>
-      <UserProperties ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" />
+      <UserProperties ProjectLinkerExcludeFilter="\\?desktop(\\.*)?$;\\?silverlight(\\.*)?$;\.desktop;\.silverlight;\.xaml;^service references(\\.*)?$;\.clientconfig;^web references(\\.*)?$" ProjectLinkReference="2f5f8c90-0bd1-424f-997c-7bc6280919d1" />
     </VisualStudio>
   </ProjectExtensions>
   <!-- To modify your build process, add your task inside one of the targets below and uncomment it. 

+ 8 - 2
Renci.SshClient/Renci.SshNet/BaseClient.cs

@@ -59,7 +59,7 @@ namespace Renci.SshNet
 
                 if (this._keepAliveTimer == null)
                 {
-                    this._keepAliveTimer = new Timer((state) => 
+                    this._keepAliveTimer = new Timer((state) =>
                     {
                         this.SendKeepAlive();
                     });
@@ -72,11 +72,17 @@ namespace Renci.SshNet
         /// <summary>
         /// Occurs when an error occurred.
         /// </summary>
+        /// <example>
+        ///   <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient Connect ErrorOccurred" language="C#" title="Handle ErrorOccurred event" />
+        /// </example>
         public event EventHandler<ExceptionEventArgs> ErrorOccurred;
 
         /// <summary>
         /// Occurs when host key received.
         /// </summary>
+        /// <example>
+        ///   <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient Connect HostKeyReceived" language="C#" title="Handle HostKeyReceived event" />
+        /// </example>
         public event EventHandler<HostKeyEventArgs> HostKeyReceived;
 
         /// <summary>
@@ -173,7 +179,7 @@ namespace Renci.SshNet
         {
 
         }
-        
+
         /// <summary>
         /// Ensures that client is connected.
         /// </summary>

+ 6 - 0
Renci.SshClient/Renci.SshNet/ConnectionInfo.cs

@@ -114,6 +114,9 @@ namespace Renci.SshNet
         /// <value>
         /// Connection timeout.
         /// </value>
+        /// <example>
+        ///   <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient Connect Timeout" language="C#" title="Specify connection timeout" />
+        /// </example>
         public TimeSpan Timeout { get; set; }
 
         /// <summary>
@@ -135,6 +138,9 @@ namespace Renci.SshNet
         /// <summary>
         /// Occurs when authentication banner is sent by the server.
         /// </summary>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo AuthenticationBanner" language="C#" title="Display authentication banner" />
+        /// </example>
         public event EventHandler<AuthenticationBannerEventArgs> AuthenticationBanner;
 
         /// <summary>

+ 0 - 55
Renci.SshClient/Renci.SshNet/Documentation/Content/About.aml

@@ -1,55 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="43d0362a-d340-4c2e-acc8-96d666ec2727" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <para>This preliminary documentation. I will add more information later so if you have any feedback as far as what missing or what need to be corrected please let me know.</para>
-		<para>At this moment SFTP documentation not yet available.</para>      
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 59
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/Interactive.aml

@@ -1,59 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="281ac0c3-0d6c-4bf2-ae64-db6862d6fff5" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>
-        This section will describe how to establish connection using interactive authentication method.
-      </para>
-      <list class="bullet">
-        <listItem>
-          <para>
-            <link xlink:href="#UseKeyboardInteractiveConnectionInfoSection">Use KeyboardInteractiveConnectionInfo to connect.</link>
-          </para>
-        </listItem>
-      </list>
-    </introduction>
-    <section address="UseKeyboardInteractiveConnectionInfoSection">
-      <title>Use KeyboardInteractiveConnectionInfo to connect</title>
-      <content>
-        <para>
-          Some server support only interactive method of authentication, even if they still use username and password.
-          For this scenario you must use <codeEntityReference>T:Renci.SshNet.KeyboardInteractiveConnectionInfo</codeEntityReference> object.
-          For this case you need to handle <codeEntityReference>E:Renci.SshNet.KeyboardInteractiveConnectionInfo.AuthenticationPrompt</codeEntityReference> event.
-          This event can be raised more then once if server needs to. For example, first time to ask you for yousername and second for the password but there could be other scenarious where more questions will need to be answered for authentication to complete.
-        </para>
-        <code language="cs" title="Use username and password to connect example">
-          <![CDATA[  
-
-							var connectionInfo = new KeyboardInteractiveConnectionInfo("host", "username");
-							connectionInfo.AuthenticationPrompt += delegate(object sender, AuthenticationPromptEventArgs e)
-							{
-							Console.WriteLine(e.Instruction);
-
-							foreach (var prompt in e.Prompts)
-							{
-							Console.WriteLine(prompt.Request);
-							prompt.Response = Console.ReadLine();
-							}
-							};
-
-							using (var client = new SshClient(connectionInfo))
-							{
-							client.Connect();
-							
-							...
-							
-							client.Disconnect();
-							}
-      
-]]>
-        </code>
-      </content>
-    </section>
-    <relatedTopics>
-      <codeEntityReference>T:Renci.SshNet.KeyboardInteractiveConnectionInfo</codeEntityReference>
-      <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference>
-      <codeEntityReference>M:Renci.SshNet.SshBaseClient.Connect()</codeEntityReference>
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 311
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/Overview.aml

@@ -1,311 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="356eeabc-aafa-4a2a-a9ab-5247b9658296" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>
-        This topic describes how to establish connection to the remote host and handle different events that can occur while connecting.
-      </para>
-      <list class="bullet">
-        <listItem>
-          <para>
-            <link xlink:href="#ConnectionOverviewSection">Connection overview.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#ConnectionEventsSection">Connection events.</link>
-          </para>
-          <list class="bullet">
-            <listItem>
-              <para>
-                <link xlink:href="#AuthenticationBannerSection">Authentication Banner.</link>
-              </para>
-            </listItem>
-            <listItem>
-              <para>
-                <link xlink:href="#HostKeyVerificationSection">Host Key Verification.</link>
-              </para>
-            </listItem>            
-          </list>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#ConnectionTimeoutSection">Connection timeout.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="b7b599b2-8bc2-4276-b9a2-d73eee2426ab">Pasword authentication.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="c233e412-0ea1-422f-8337-e5d1231b71e5">Private key authentication.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="281ac0c3-0d6c-4bf2-ae64-db6862d6fff5">Interactive authentication.</link>
-          </para>
-        </listItem>
-      </list>
-    </introduction>
-
-    <section address="ConnectionOverviewSection">
-      <title>Connection overview</title>
-      <content>
-        <para>
-          To work with any server you need to establish a connection first.
-          To establish connection you need to provide <codeEntityReference>T:Renci.SshNet.SshBaseClient</codeEntityReference> inherited class with right credential.
-          All <codeEntityReference>T:Renci.SshNet.SshBaseClient</codeEntityReference> inherited classes can accept <codeEntityReference>T:Renci.SshNet.ConnectionInfo</codeEntityReference> inherited class as parameter that contains authentication information.
-          You can also provide authentication information to <codeEntityReference>T:Renci.SshNet.SshBaseClient</codeEntityReference> inherited class directly, but in this case you won't be able to handle any connection specific events that might occur and need your attention.
-        </para>
-      </content>
-    </section>
-
-    <section address="ConnectionEventsSection">
-      <title>Connection events</title>
-      <content>
-        <para>
-          Different events can occur while you establishing connection.
-          Some events are specific to connection method you using, private key or password for example,
-          and some are generic to all types of authentication method.
-        </para>
-
-      </content>
-      <sections>
-
-        <section address="AuthenticationBannerSection">
-          <title>Authentication Banner</title>
-          <content>
-            <para>
-              Some server might display a text when user logs in. If you want to display or analyze this text you need to handle <codeEntityReference>E:Renci.SshNet.ConnectionInfo.AuthenticationBanner</codeEntityReference> event.
-            </para>
-            <code language="cs" title="Handle AuthenticationBanner event example">
-            <![CDATA[  
-              
-              var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
-              
-              connectionInfo.AuthenticationBanner += delegate(object sender, AuthenticationBannerEventArgs e)
-              {
-                  Console.WriteLine(e.BannerMessage);
-              };
-
-              using (var client = new SshClient(connectionInfo))
-              {
-                client.Connect();
-                
-                ....
-                
-                client.Disconnect();
-              }              
-              
-            ]]>
-            </code>
-          </content>
-        </section>
-        <section address="HostKeyVerificationSection">
-          <title>Host Key Verification</title>
-          <content>
-            <para>
-              If host key need to be verified then you need to handle <codeEntityReference>E:Renci.SshNet.BaseClient.HostKeyReceived</codeEntityReference> event.
-            </para>
-            <code language="cs" title="Handle HostKeyReceived event example">
-              <![CDATA[  
-            
-          var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
-          
-			    using (var ssh = new SshClient(connectionInfo))
-			    {
-				      ssh.HostKeyReceived += delegate(object sender, HostKeyEventArgs e)
-				      {
-					        var sb = new StringBuilder();
-					        foreach (var b in e.FingerPrint)
-					        {
-						          sb.AppendFormat("{0:x}:", b);
-					        }
-                  
-					        Console.WriteLine("Can trust this fingerprint: {0}", sb);
-                  
-					        var key = Console.ReadKey();
-					        if (key.KeyChar == 'Y')
-						          e.CanTrust = true;
-					        else
-						          e.CanTrust = false;
-				      };
-
-				      ssh.Connect();
-        
-              ...
-        
-				      ssh.Disconnect();
-			    }
-
-]]>
-            </code>
-          </content>
-        </section>
-      </sections>
-    </section>
-
-    <section address="ConnectionTimeoutSection">
-      <title>Connection timeout</title>
-      <content>
-        <para>
-          When connection is too slow or operation that you about to run will take a long time then you neen to change default timeout value.
-          To change that you need to set <codeEntityReference>P:Renci.SshNet.ConnectionInfo.Timeout</codeEntityReference> property.
-        </para>
-        <code language="cs" title="Handle HostKeyReceived event example">
-<![CDATA[  
-
-          var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
-          
-          connectionInfo.Timeout = TimeSpan.FromSeconds(30);
-          
-          using (var client = new SshClient(connectionInfo))
-          {
-              client.Connect();
-          
-              ...
-          
-              client.Disconnect();
-          }
-]]>
-        </code>
-
-      </content>
-    </section>
-
-
-
-
-    <!--    
-    <content>
-      <para>
-      To perform any operation you need to establish the connection first. This library supports <b>password</b>, <b>private key</b> and <b>ineractive</b> authentication methods.
-	  All authentication methods inherit from <codeEntityReference>T:Renci.SshNet.ConnectionInfo</codeEntityReference> class and therefore share common set of features.
-	</para>
-    </content>  
-    
-    <section>
-      <title>Establish connection</title>
-      <content>
-        To establish connection you need to provide valid credentials. Both <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference> and <codeEntityReference>T:Renci.SshNet.SftpClient</codeEntityReference> accept same paramters. See examples below:
-        <codeExample>
-          <list class="ordered">
-            <listItem>
-              <para>Connecting using username and password to server's default port</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", "password"))
-                {
-                  client.Connect();
-                  client.Disconnect();
-                }
-              </code>
-            </listItem>
-            <listItem>
-              <para>Connecting using username and password to server's port 1234</para>
-              <code language="cs">
-                using (var client = new SftpClient("host", 1234, "username", "password"))
-                {
-                  client.Connect();
-                  client.Disconnect();
-                }
-              </code>
-            </listItem>
-
-            <listItem>
-              <para>Connecting using username and private key to server's default port</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", new PrivateKeyFile(File.OpenRead(@"private.key"))))
-                {
-                  client.Connect();
-                  client.Disconnect();
-                }
-              </code>
-            </listItem>
-            <listItem>
-              <para>Connecting using username and private key to server's port 1234</para>
-              <code language="cs">
-                using (var client = new SftpClient("host", 1234, "username", new PrivateKeyFile(File.OpenRead(@"private.key"))))
-                {
-                  client.Connect();
-                  client.Disconnect();
-                }
-              </code>
-            </listItem>
-
-          </list>
-        </codeExample>
-      </content>
-    </section>
-
-    <section>
-      <title>
-        Using ConnectionInfo object to connect.
-      </title>
-      <content>
-        <para>
-          In more complex scenarious when additional parameters are needed during connection phase you can use <codeEntityReference>T:Renci.SshNet.ConnectionInfo</codeEntityReference> inherited object.
-          <codeEntityReference>T:Renci.SshNet.ConnectionInfo</codeEntityReference> is an abstact class and you need to use one of the inhertied classes.
-          Which class to use depends on how you want to connect to the server.
-          To connect using private key you need to use <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference> object.
-          To connect using username and password combination use <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference>.
-          If you have an interactive scenario you need to use <codeEntityReference>T:Renci.SshNet.KeyboardInteractiveConnectionInfo</codeEntityReference>.
-        </para>
-        <para>See some usage examples below:</para>
-        <codeExample>
-          <list class="ordered">
-            <listItem>
-              <para>
-                Use <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference> objet to provide username and password.
-              </para>
-              <code language="cs">
-                var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
-                using (var client = new SshClient(connectionInfo))
-                {
-                  client.Connect();
-                  client.Disconnect();
-                }
-              </code>
-            </listItem>
-            <listItem>
-              <para>
-                Use <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference> objet to provide username and private key file
-              </para>
-              <code language="cs">
-                var connectionInfo = new PrivateKeyConnectionInfo("host", "username", new PrivateKeyFile(File.OpenRead(@"private.key")));
-                using (var client = new SshClient(connectionInfo))
-                {
-                  client.Connect();
-                  client.Disconnect();
-                }
-              </code>
-            </listItem>
-            <listItem>
-              <para>
-                Use <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference> objet to provide username and private key file with passphrase.
-              </para>
-              <code language="cs">
-                var connectionInfo = new PrivateKeyConnectionInfo("host", "username", new PrivateKeyFile(File.OpenRead(@"private.key"), "passphrase"));
-                using (var client = new SshClient(connectionInfo))
-                {
-                  client.Connect();
-                  client.Disconnect();
-                }
-              </code>
-            </listItem>
-          </list>
-        </codeExample>
-      </content>
-    </section>
--->
-    <relatedTopics>
-      <codeEntityReference>T:Renci.SshNet.ConnectionInfo</codeEntityReference>
-      <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference>
-      <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference>
-      <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference>
-      <codeEntityReference>M:Renci.SshNet.SshBaseClient.Connect</codeEntityReference>
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 140
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/Password.aml

@@ -1,140 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="b7b599b2-8bc2-4276-b9a2-d73eee2426ab" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>
-        This section will describe how to establish connection using username and password combination.
-        You can provide username/password combination either directly in the client constractor using <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference> class.
-        You use <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference> object when you need to provide additional such as timeout or simple to handle different events that can occur when establishing connection.
-      </para>
-      <list class="bullet">
-        <listItem>
-          <para>
-            <link xlink:href="#UseUsernamePasswordSection">Use username and password to connect.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#UsePasswordConnectionInfoSection">Use PasswordConnectionInfo to connect.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#HandleExpiredPasswordSection">Handle expired password.</link>
-          </para>
-        </listItem>
-      </list>
-    </introduction>
-
-    <section address="UseUsernamePasswordSection">
-      <title>Use username and password to connect</title>
-      <content>
-        <para>
-          In many scenarious all you need to know is host, username and password to establish connection, in this case you can provide this information directly to the client object.
-        </para>
-        <code language="cs" title="Use username and password to connect example">
-          <![CDATA[  
-
-      using (var client = new SshClient("host", "username", "password"))
-      {
-      client.Connect();
-      
-      ....
-      
-      client.Disconnect();
-      }
-      
-]]>
-        </code>
-      </content>
-    </section>
-
-    <section address="UsePasswordConnectionInfoSection">
-      <title>Use PasswordConnectionInfo to connect</title>
-      <content>
-        <para>
-          To get more control over connection proccess when using username and password combination you need to use <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference> object.
-        </para>
-        <code language="cs" title="How to use PasswordConnectionInfo example">
-          <![CDATA[  
-
-      var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
-      using (var client = new SftpClient(connectionInfo))
-      {
-      client.Connect();
-      
-      ...
-      
-      client.Disconnect();
-      }
-      
-]]>
-        </code>
-      </content>
-    </section>
-
-    <section address="UsePasswordConnectionInfoSection">
-      <title>Use PasswordConnectionInfo to connect</title>
-      <content>
-        <para>
-          To get more control over connection proccess when using username and password combination you need to use <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference> object.
-        </para>
-        <code language="cs" title="How to use PasswordConnectionInfo example">
-          <![CDATA[  
-
-      var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
-      // Attach to connection event if needed here
-      using (var client = new SftpClient(connectionInfo))
-      {
-      client.Connect();
-      
-      ...
-      
-      client.Disconnect();
-      }
-      
-]]>
-        </code>
-      </content>
-    </section>
-
-    <section address="HandleExpiredPasswordSection">
-      <title>Handle expired password</title>
-      <content>
-        <para>
-          When user logs on and his password is expired you can ask user for a new passowrd and change it.
-          <alert class="note">
-            <para>The event handler will be executed on new thread</para>
-          </alert>
-        </para>
-        <code language="cs" title="How to change expired password example">
-          <![CDATA[  
-
-              var connectionInfo = new PasswordConnectionInfo("host", "username", "password");
-              connectionInfo.PasswordExpired += delegate(object sender, AuthenticationPasswordChangeEventArgs e)
-              {
-                e.NewPassword = "123456";
-              };
-
-              using (var client = new SshClient(connectionInfo))
-              {
-                client.Connect();
-                
-                ....
-                
-                client.Disconnect();
-              }
-      
-]]>
-        </code>
-      </content>
-    </section>
-
-
-    <relatedTopics>
-      <codeEntityReference>T:Renci.SshNet.PasswordConnectionInfo</codeEntityReference>
-      <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference>
-      <codeEntityReference>M:Renci.SshNet.SshBaseClient.Connect</codeEntityReference>
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 201
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Connection/PrivateKey.aml

@@ -1,201 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="c233e412-0ea1-422f-8337-e5d1231b71e5" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>
-        This topic describes hot to connect to the remote host using private key file.
-        <!--
-        To connect to remote server using private key you need to provide <codeEntityReference>T:Renci.SshNet.PrivateKeyFile</codeEntityReference> object which points to file that contains private key information.-->
-      </para>
-      <list class="bullet">
-        <listItem>
-          <para>
-            <link xlink:href="#PrivateKeyGenerationSection">Private Key file generation.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#PrivateKeyExamplesSection">Private Key file examples.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#CreatePrivateKeyFileInstanceSection">Create PrivateKeyFile instance.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#UsePrivateKeyFileInstanceSection">Using PrivateKeyFile instance.</link>
-          </para>
-        </listItem>
-        <listItem>
-          <para>
-            <link xlink:href="#MultiplePrivateKeyFilesSection">Using multiple private key files.</link>
-          </para>
-        </listItem>
-      </list>
-    </introduction>
-
-
-    <section address="PrivateKeyGenerationSection">
-      <title>Private Key file generation</title>
-      <content>
-        <para>
-          Before using private key for authentication you need to create one and configure remote host to accept it.
-          Typically it can be done by executing following command on the remote host.
-        </para>
-        <code language="text" title="Private key generation example">
-          ssh-keygen -t rsa
-        </code>
-      </content>
-    </section>
-
-    <section address="PrivateKeyExamplesSection">
-      <title>Private Key file examples</title>
-      <content>
-        <para>
-          To use private key for authentication, private key must be generated. Typecally it can be done un remote host by issue <command>ssh-keygen -t rsa</command> command.
-          Below are some private key examples:
-        </para>
-        <code language="text" title="Private RSA key example">
-            <![CDATA[
------BEGIN RSA PRIVATE KEY-----
-MIIEoQIBAAKCAQEAuTtXn+BatX1oJuvhqfJZw5jc/pcIxJUPmuoFCH3+bXfKBJ/9
-4ixNETzZBasyvT/ozboAbCG3qcJOYxf2BEeTAIXe1jLAoTd1GKCwMvZOyjnsPN95
-/lChwfdnBbMzpZYTGfoUylXme/mzjjLu/J0qXgR5lyk9HFT+x5YEtRl8VSHiDkLK
-TZ37dwhsqgcs+PkfvYMUK+C8evnfE0tgWgKZk0Eatl87nLWyVXB4LzhSDtGKLCPA
-OgrX7fYfplDwJ2WK1N6nG0FnxW1HhDeSK7e2TbAa2vZQgvFXMWnO4O/NZKp4COpO
-ReyliWhdtKAjr/+cD4yDfPjhjjKOYfxbvdRG4QIBIwKCAQAqVrTxV9o4HKoXhl93
-TVZYl/f/rX5Y0Z0quSW4zFdpendRg6e+qwpNFTjrWlS9ivNiOSSrAGR+ktAWpmQe
-PD7bjFAw9ahfXSIUQfxja3+5Mc+Y4p+KlhZYOIyTlqy4Ik2CR8o84G8yR7QDPteK
-Mo1XUXrguPgGedPV2SWlvK60XyAXqsewDhi7SeImZomKzbh33SXjVxakzHfa8BEU
-eIIeR9oFlQMuYdo4GrHhFO2T+g/gqw/kVd1zkeEwt06fZVDErVwp+twewxxvwrk4
-CKUCzavfhDfi5sJ5YdzhDBRgkyBgJI+f15dKyqqOiAparV9+uzrD6vIuNnlVoqQA
-iugLAoGBAPBliy32e83nshBknBn5HOK2rO3a1zHxvYr/NzITXtdZOjatNyfXtkwi
-Ll/el5tZhJvKe9nItSI/4w7mvlvXZfW8h3MR0qb8at4jWa8ya2hwEerqaJonqjjb
-+eBhg27ltZIQRk8Bv6ApXTAWkc+dFGhEIysokDQX7V72Bdrizup1AoGBAMVBLHK0
-5IFb8x7danlAmDX6bqCObId4Pce2OeONFIj1jIowvCXaE0t9zU4X5SdN5ujqu4Dq
-XgzUdNeKcJxWpFO74MDRxT3CbMz36fikJnvxWl/+q0HalYuCY8gm14VYcThUBAro
-3c941INueybGNLIA9jc7RMnsFtyVTvNYpaU9AoGAFJr9TRUgjf3qsPKuS15+0Zqh
-G7OsC5hgtCSBEuu3rA72XHU/Pe3rDdcLSgvD2h2dpvQZPo2L3l0/WQx2t2o78H3f
-uWftfAcB2Iav6nIJNNZn75BvXaug4E1ej5NUaJdYtL+Q/3UtrqR1s6opwVabWWTt
-ElPvGmhzboodwk30en8CgYAyuPzNCfGdm00lMZ8JPH7pTwaBDq4xdrDM9FgHUCna
-E0FlXP0uTgT2J6nSQKijtPI75JadfhgvL1E+vTLmX2wViBU45XvcrlZ92Vlr0nBL
-wbgnUB1otIzauyD49AuIsFegxSWcZ8QCJmKIMlouir0X1FyR3Apfzv6Qfio+kyNH
-vwKBgQCtwxojkzUSfV3zDt6bYSLBzgXgo/Zr9lS+gSggP72DzINmW2gbA0fkM2Zu
-JltcfakKv4gVX/1zooz+7t+4bj6dqt+bl7hYz0VnTSDZGuo5LKDif/4gSGrdblC2
-QLTuX2HjWCZdsue7mRwL7cXR4zlIoE99+Ryhdxvc5wHSfYr/JA==
------END RSA PRIVATE KEY-----
-]]>
-          </code>
-      </content>
-    </section>
-
-
-    <section address="CreatePrivateKeyFileInstanceSection">
-      <title>Create PrivateKeyFile instance</title>
-      <content>
-        <para>
-          To specify private key you need to intsantiate <codeEntityReference>T:Renci.SshNet.PrivateKeyFile</codeEntityReference> object.
-          Some private key require passphrase to be specified.
-          <alert class="note">
-            <para>
-              If private key requires a passphrase but it was not specified then <codeEntityReference>T:Renci.SshNet.Common.SshPassPhraseNullOrEmptyException</codeEntityReference> exception will be thrown.
-            </para>
-          </alert>
-        </para>
-        <code language="cs" title="Create PrivateKeyFile without providing passphrase">
-            var keyFile = new PrivateKeyFile(File.OpenRead(@"rsa_pass_key.txt"));
-          </code>
-
-          <code language="cs" title="Create PrivateKeyFile by providing passphrase">
-            var keyFile = new PrivateKeyFile(File.OpenRead(@"rsa_pass_key.txt"), "tester")
-          </code>
-      </content>
-    </section>
-
-    <section address="UsePrivateKeyFileInstanceSection">
-      <title>Using PrivateKeyFile instance</title>
-      <content>
-        <para>
-          You can pass <codeEntityReference>T:Renci.SshNet.PrivateKeyFile</codeEntityReference> object to client constructor or when creating <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference> object.
-        </para>
-        <code language="cs" title="Provide PrivateKeyFile instance to PrivateKeyConnectionInfo example">
-            var keyFile = new PrivateKeyFile(File.OpenRead(@"rsa_pass_key.txt"));
-            var connectionInfo = new PrivateKeyConnectionInfo("server", 22, "tester", keyFile);
-          </code>
-
-          <code language="cs" title="Provide PrivateKeyFile instance to SshClient example">
-            var keyFile = new PrivateKeyFile(File.OpenRead(@"rsa_pass_key.txt"), "tester")
-            using (var client = new SshClient("host", "username", keyFile))
-            {
-            }
-          </code>
-      </content>
-    </section>
-
-    <section address="MultiplePrivateKeyFilesSection">
-      <title>Using multiple private key files</title>
-      <content>
-        <para>
-          In some scenarious you might want to provide multiple private key to authenticate user. In this case you create PrivateKeyFile as described <link xlink:href="#CreatePrivateKeyFileInstanceSection">here</link> and then pass those file to either client or <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference> constructor.
-        </para>
-        <code language="cs" title="Provide multiple PrivateKeyFile instances example">
-            var keyFile1 = new PrivateKeyFile(File.OpenRead(@"rsa_pass_key1.txt"));
-            var keyFile2 = new PrivateKeyFile(File.OpenRead(@"rsa_pass_key2.txt"));
-            var connectionInfo = new PrivateKeyConnectionInfo("server", 22, "tester", keyFile1, keyFile2);
-          </code>
-      </content>
-    </section>
-
-
-    <!--    <content>
-      <para>
-      
-      Some private key are encrypted using passphrase. You can specify passphrase by creating private key using <codeEntityReference qualifyHint="true" autoUpgrade="true">M:Renci.SshNet.PrivateKeyFile.#ctor(Stream, String)</codeEntityReference> or <codeEntityReference qualifyHint="true" autoUpgrade="true">M:Renci.SshNet.PrivateKeyFile.#ctor(System.String, System.String)</codeEntityReference> constructors.
-      Test <codeEntityReference qualifyHint="true" autoUpgrade="true">M:Renci.SshNet.PrivateKeyFile.#ctor</codeEntityReference>      
-      </para>
-      <codeExample>
-        <list class="ordered">
-          <listItem>
-            <para>Providing private key directly in the client constructor</para>
-            <code language="cs">
-              using (var client = new SshClient("host", "username", new PrivateKeyFile(File.OpenRead(@"private.key"))))
-              {
-              client.Connect();
-              client.Disconnect();
-              }
-            </code>
-          </listItem>
-          <listItem>
-            <para>Providing private key and passphrase directly in the client constructor</para>
-            <code language="cs">
-              using (var client = new SshClient("host", "username", new PrivateKeyFile(File.OpenRead(@"private.key"), "passphrase")))
-              {
-              client.Connect();
-              client.Disconnect();
-              }
-            </code>
-          </listItem>
-          <listItem>
-            <para>Providing private key and passphrase directly using <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference> object.</para>
-            <code language="cs">
-              var connectionInfo = new PrivateKeyConnectionInfo("host", 1234, "username", new PrivateKeyFile(File.OpenRead(@"rsa_pass_key.txt"), "tester"));
-              using (var client = new SshClient(connectionInfo))
-              {
-              client.Connect();
-              client.Disconnect();
-              }
-            </code>
-          </listItem>
-        </list>
-      </codeExample>
-    </content>
--->
-    <relatedTopics>
-      <codeEntityReference>T:Renci.SshNet.PrivateKeyConnectionInfo</codeEntityReference>
-      <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference>
-      <codeEntityReference>M:Renci.SshNet.SshBaseClient.Connect()</codeEntityReference>
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 49
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Errors.aml

@@ -1,49 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="bb9dec7b-fe99-46f4-8ee9-92936a976730" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>
-        Most of the errors are handled by the library and throw as <codeEntityReference>T:Renci.SshNet.Common.SshException</codeEntityReference> based exception. But sometimes there are errors that could occur on internal lister thread.
-        If such error occurs then <codeEntityReference>E:Renci.SshNet.BaseClient.ErrorOccurred</codeEntityReference> event is raised.
-      </para>
-      <list class="bullet">
-        <listItem>
-          <para>
-            <link xlink:href="#HandleErrorOccurredSection">Handle ErrorOccurred event.</link>
-          </para>
-        </listItem>
-      </list>
-    </introduction>
-
-    <section address="HandleErrorOccurredSection">
-      <title>Handle ErrorOccurred event</title>
-      <content>
-        <para>
-          Below is an example of how to handle <codeEntityReference>E:Renci.SshNet.BaseClient.ErrorOccurred</codeEntityReference> event.
-        </para>
-        <code language="cs" title="Display unhandled errors to console example">
-          <![CDATA[  
-
-              using (var client = new SshClient(connectionInfo))
-              {
-				client.ErrorOccurred += delegate(object sender, ExceptionEventArgs e)
-		        {
-			        Console.WriteLine("Error occured: " + e.Exception.ToString());
-		        };
-		        
-                client.Connect();
-		        
-		        ...
-
-                client.Disconnect();
-              }
-              
-]]>
-        </code>
-      </content>
-    </section>
-    <relatedTopics>
-     
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 82
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/NetConfClient/Overview.aml

@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="9aff6aff-8781-481c-be0c-132e1391f01d" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <!-- Uncomment this to generate an outline of the section and sub-section
-           titles.  Specify a numeric value as the inner text to limit it to
-           a specific number of sub-topics when creating the outline.  Specify
-           zero (0) to limit it to top-level sections only.  -->
-      <!-- <autoOutline /> -->
-      <para>Required introduction</para>
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="Section1">
-      <title>Optional section title</title>
-      <content>
-        <!-- Uncomment this to create a sub-section outline
-        <autoOutline /> -->
-        <para>Add one or more sections with content</para>
-      </content>
-      <!-- If a section contains a sections element, its content creates
-           sub-sections.  These are not collapsible.
-      <sections>
-          <section address="SubSection1">
-              <title>Sub-section 1</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-          <section address="SubSection2">
-              <title>Sub-section 2</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-      </sections> -->
-    </section>
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 103
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/Overview.aml

@@ -1,103 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="ef6ffc84-f410-4682-9366-e9fe2a73ea52" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <!-- Uncomment this to generate an outline of the section and sub-section
-           titles.  Specify a numeric value as the inner text to limit it to
-           a specific number of sub-topics when creating the outline.  Specify
-           zero (0) to limit it to top-level sections only.  -->
-      <!-- <autoOutline /> -->
-      <para>This programming guide will provide guides on how to achive different SSH task using SSH Library </para>
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="ConnectionSection">
-      <title>Connection</title>
-      <content>
-        <para>This section will describe how to establish SSH connection using different authentication methods.</para>
-      </content>
-    </section>
-    
-	<section address="ErrorHandlingSection">
-      <title>Error Handling</title>
-      <content>
-        <para>This section will describe how handle differnt errors that can occure during SSH session.</para>
-      </content>
-    </section>
-    
-	<section address="SshClientSection">
-      <title>SSH Client</title>
-      <content>
-        <para>This section will describe how to execute commands on connected host. This section will also descibe hot to anaylize output produced by executed commands.</para>
-        <autoOutline />
-        <para>This section also will cover other SSH features such local and remote port forwarding.</para>
-      </content>
-    </section>   
-        
-	<section address="SftpClientSection">
-      <title>Sftp Client</title>
-      <content>
-        <para>This section will describe to use SFTP features, upload and download files using SFTP protocol.</para>
-      </content>
-    </section>
-        
-	<section address="ScpClientSection">
-      <title>Scp Client</title>
-      <content>
-        <para>This section will cover SCP features to copy fles to and from remote host.</para>
-      </content>
-    </section>
-        
-	<section address="NetConfSection">
-      <title>NetConf Client</title>
-      <content>
-        <para>This is exeprimental feature and currently will not be covered here.</para>
-      </content>
-    </section>
-
-
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 82
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/ScpClient/Overview.aml

@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="09cd9117-2327-423a-8952-cf6d6f56b71d" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <!-- Uncomment this to generate an outline of the section and sub-section
-           titles.  Specify a numeric value as the inner text to limit it to
-           a specific number of sub-topics when creating the outline.  Specify
-           zero (0) to limit it to top-level sections only.  -->
-      <!-- <autoOutline /> -->
-      <para>Required introduction</para>
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="Section1">
-      <title>Optional section title</title>
-      <content>
-        <!-- Uncomment this to create a sub-section outline
-        <autoOutline /> -->
-        <para>Add one or more sections with content</para>
-      </content>
-      <!-- If a section contains a sections element, its content creates
-           sub-sections.  These are not collapsible.
-      <sections>
-          <section address="SubSection1">
-              <title>Sub-section 1</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-          <section address="SubSection2">
-              <title>Sub-section 2</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-      </sections> -->
-    </section>
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 82
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/Overview.aml

@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="20a326ed-82f7-4586-844c-b3da4a82c2cd" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <!-- Uncomment this to generate an outline of the section and sub-section
-           titles.  Specify a numeric value as the inner text to limit it to
-           a specific number of sub-topics when creating the outline.  Specify
-           zero (0) to limit it to top-level sections only.  -->
-      <!-- <autoOutline /> -->
-      <para>Required introduction</para>
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="Section1">
-      <title>Optional section title</title>
-      <content>
-        <!-- Uncomment this to create a sub-section outline
-        <autoOutline /> -->
-        <para>Add one or more sections with content</para>
-      </content>
-      <!-- If a section contains a sections element, its content creates
-           sub-sections.  These are not collapsible.
-      <sections>
-          <section address="SubSection1">
-              <title>Sub-section 1</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-          <section address="SubSection2">
-              <title>Sub-section 2</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-      </sections> -->
-    </section>
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 82
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/SftpFile.aml

@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="4f283f0d-d2b7-4927-ae65-f08910756d5c" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <!-- Uncomment this to generate an outline of the section and sub-section
-           titles.  Specify a numeric value as the inner text to limit it to
-           a specific number of sub-topics when creating the outline.  Specify
-           zero (0) to limit it to top-level sections only.  -->
-      <!-- <autoOutline /> -->
-      <para>Required introduction</para>
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="Section1">
-      <title>Optional section title</title>
-      <content>
-        <!-- Uncomment this to create a sub-section outline
-        <autoOutline /> -->
-        <para>Add one or more sections with content</para>
-      </content>
-      <!-- If a section contains a sections element, its content creates
-           sub-sections.  These are not collapsible.
-      <sections>
-          <section address="SubSection1">
-              <title>Sub-section 1</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-          <section address="SubSection2">
-              <title>Sub-section 2</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-      </sections> -->
-    </section>
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 82
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/SftpFileStream.aml

@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="9f109050-db57-43a3-a1ab-866e0de5dc10" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <!-- Uncomment this to generate an outline of the section and sub-section
-           titles.  Specify a numeric value as the inner text to limit it to
-           a specific number of sub-topics when creating the outline.  Specify
-           zero (0) to limit it to top-level sections only.  -->
-      <!-- <autoOutline /> -->
-      <para>Required introduction</para>
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="Section1">
-      <title>Optional section title</title>
-      <content>
-        <!-- Uncomment this to create a sub-section outline
-        <autoOutline /> -->
-        <para>Add one or more sections with content</para>
-      </content>
-      <!-- If a section contains a sections element, its content creates
-           sub-sections.  These are not collapsible.
-      <sections>
-          <section address="SubSection1">
-              <title>Sub-section 1</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-          <section address="SubSection2">
-              <title>Sub-section 2</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-      </sections> -->
-    </section>
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 145
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SftpClient/SftpOperations.aml

@@ -1,145 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="96751e69-1f9f-417f-8532-c8344b9e98c8" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-		<introduction>
-			<para>
-				This topic describes how transfer file using <codeEntityReference>T:Renci.SshNet.SftpClient</codeEntityReference>.
-			</para>
-			<list class="bullet">
-				<listItem>
-					<para>
-						<link xlink:href="#PathSection">Path resolution.</link>
-					</para>
-				</listItem>					
-				<listItem>
-					<para>
-						<link xlink:href="#DirectoryOperationsSection">Directory operations.</link>
-					</para>
-					<list class="bullet">
-						<listItem>
-							<para>
-								<link xlink:href="#CreateDirectorySection">Create directory.</link>
-							</para>
-						</listItem>					
-						<listItem>
-							<para>
-								<link xlink:href="#DeleteDirectorySection">Delete directory.</link>
-							</para>
-						</listItem>					
-						<listItem>
-							<para>
-								<link xlink:href="#ChangeDirectorySection">Change directory.</link>
-							</para>
-						</listItem>					
-						<listItem>
-							<para>
-								<link xlink:href="#ListDirectorySection">List directory.</link>
-							</para>
-						</listItem>					
-					</list>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#FileOperationSection">File operations.</link>
-					</para>
-					<list class="bullet">
-						<listItem>
-							<para>
-								<link xlink:href="#UploadFileSection">Upload file.</link>
-							</para>
-						</listItem>					
-						<listItem>
-							<para>
-								<link xlink:href="#DownloadFileSection">Download file.</link>
-							</para>
-						</listItem>					
-					</list>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#CreateSymbolicLinkSection">Create symbolic link.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#SftpFileSection">SftpFile class.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#SftpFileStreamSection">SftpFileStream class.</link>
-					</para>
-				</listItem>
-
-			</list>
-		</introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="Section1">
-      <title>Optional section title</title>
-      <content>
-        <!-- Uncomment this to create a sub-section outline
-        <autoOutline /> -->
-        <para>Add one or more sections with content</para>
-      </content>
-      <!-- If a section contains a sections element, its content creates
-           sub-sections.  These are not collapsible.
-      <sections>
-          <section address="SubSection1">
-              <title>Sub-section 1</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-          <section address="SubSection2">
-              <title>Sub-section 2</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-      </sections> -->
-    </section>
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 41
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Asynchronous.aml

@@ -1,41 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="3e7487ed-9a0c-4442-8b31-14e291a7c648" revisionNumber="1">
-  <developerSDKTechnologyOverviewOrientationDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-      <title>Execut command asynchronously</title>
-      <content>
-      	If you need to execute long running command you might want to execute it in asynchronously.
-      	To execute command asynchronously you need to create command first and then call <codeEntityReference>M:Renci.SshNet.SshCommand.BeginExecute(System.AsyncCallback, System.Object)</codeEntityReference> method
-			<alert class="note">
-			  <para>If an exception occures while command is being executed it will be thrown when <codeEntityReference>M:Renci.SshNet.SshCommand.EndExecute(System.IAsyncResult)</codeEntityReference> is called.</para>
-			</alert>
-        <para>See examples below:</para>
-        <codeExample>
-          <list class="ordered">
-            <listItem>
-              <para>Display exit status when command is executed.</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", "password"))
-                {
-                client.Connect();
-                var cmd = client.CreateCommand("sleep 30s;date"); // Perform long running task
-                var asynch = cmd.BeginExecute(null, null);
-                while (!asynch.IsCompleted)
-                {
-                    Console.WriteLine("Waiting for command to complete...");
-                    Thread.Sleep(2000);
-                }
-                cmd.EndExecute(asynch);
-                client.Disconnect();
-                }
-              </code>
-            </listItem>
-          </list>
-        </codeExample>
-      </content>
-    <relatedTopics>
-	    <codeEntityReference>M:Renci.SshNet.SshCommand.BeginExecute(System.AsyncCallback, System.Object)</codeEntityReference>
-	    <codeEntityReference>M:Renci.SshNet.SshCommand.EndExecute(System.IAsyncResult)</codeEntityReference>
-		<codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference>
-    </relatedTopics>
-  </developerSDKTechnologyOverviewOrientationDocument>
-</topic>

+ 0 - 36
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Errors.aml

@@ -1,36 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="6df8e431-0da0-4fd3-9e26-3871030ab3af" revisionNumber="1">
-  <developerOrientationDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-      <title>Execution errors</title>
-      <content>
-      	When command is executed and error occured you can access to errir description by accessing <codeEntityReference>P:Renci.SshNet.SshCommand.Error</codeEntityReference> property.
-      	You can also check <codeEntityReference>P:Renci.SshNet.SshCommand.ExitStatus</codeEntityReference> which is in case of error should not be 0.
-        <para>See examples below:</para>
-        <codeExample>
-          <list class="ordered">
-            <listItem>
-              <para>Execute invalid command and display execution error.</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", "password"))
-                {
-	                client.Connect();
-	                var cmd = client.CreateCommand(";");
-	                cmd.Execute();
-	                if (!string.IsNullOrEmpty(cmd.Error))
-	                {
-	                    Console.WriteLine(cmd.Error);
-	                }
-	                client.Disconnect();
-                }
-              </code>
-            </listItem>
-          </list>
-        </codeExample>
-      </content>
-    <relatedTopics>
-	    <codeEntityReference>P:Renci.SshNet.SshCommand.ExitStatus</codeEntityReference>
-	    <codeEntityReference>P:Renci.SshNet.SshCommand.Error</codeEntityReference>
-		<codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference>
-    </relatedTopics>
-  </developerOrientationDocument>
-</topic>

+ 0 - 70
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Execute.aml

@@ -1,70 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="c8a66a6b-b82a-4b61-93ea-82e281c345df" revisionNumber="1">
-  <developerHowToDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <para>Required introduction</para>
-    </introduction>
-    <!-- Optional procedures followed by optional code example but must have
-         at least one procedure or code example -->
-    <procedure>
-      <title>Procedure title</title>
-      <steps class="ordered">
-        <step>
-          <content>
-            <para>First step</para>
-          </content>
-        </step>
-        <step>
-          <content>
-            <para>Second step</para>
-          </content>
-        </step>
-      </steps>
-      <!-- <conclusion>Optional conclusion</conclusion> -->
-    </procedure>
-    <!-- <codeExample>Optional code example</codeExample> -->
-    <!-- <buildInstructions>Optional instructions for building a
-         code example.</buildInstructions> -->
-    <!-- <robustProgramming>Optional discussion of error handling and other
-         issues related to writing solid code.</robustProgramming> -->
-    <!-- <security>Optional discussion of security issues.</security> -->
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID">Link text</link>
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerHowToDocument>
-</topic>

+ 0 - 38
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Multitasking.aml

@@ -1,38 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="eb8e4d77-8fc9-42e9-b8e8-c152b595d5c9" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>Library support multiple command execution at once. However there are some limitation to be aware of.
-      While you can run multiple commands on multiple threads at the same time usually only 10 commands are executed at the same time.
-      This is due to server default limitation which allows only 10 session channels top be open at the same time.
-      This limitation can be change on the server level, if so you can you <codeEntityReference>T:Renci.SshNet.ConnectionInfo</codeEntityReference> object to increase or decrease this value.
-      This rule is only true when you try to run multiple commands on the same connection.
-      Of course if you will be using multiple connection this rul does not apply.
-      </para>
-    </introduction>
-            <codeExample>
-              <para>Running multiple command using one connection.</para>
-              <code language="cs">
-                System.Threading.Tasks.Parallel.For(0, 10000,
-                    () =>
-                    {
-                        var client = new SshClient("host", "username", "password");
-                        client.Connect();
-                        return client;
-                    },
-                    (int counter, ParallelLoopState pls, SshClient client) =>
-                    {
-		                var cmd = client.RunCommand(string.Format("echo {0}}", counter));
-		                Console.WriteLine(cmd.Result);
-                        return client;
-                    },
-                    (SshClient client) =>
-                    {
-                        client.Disconnect();
-                        client.Dispose();
-                    }
-              </code>
-        </codeExample>
-
-  </developerConceptualDocument>
-</topic>

+ 0 - 327
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Overview.aml

@@ -1,327 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="2337d96d-7638-438e-b980-96e87b807265" revisionNumber="1">
-	<developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-		<introduction>
-			<para>
-				This topic describes how execute commands on remote host using <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference>.
-			</para>
-			<list class="bullet">
-				<listItem>
-					<para>
-						<link xlink:href="#CommandExecutionOverviewSection">Command execution overview.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#SimpleCommandExecutionSection">Simple command execution.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#UsingSshCommandSection">Using SshCommand object.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#ReuseSshCommandSection">Reuse SshCommand object.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#CommandExecutionTimeoutSection">Command execution timeout.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#HandleCommandOutputSection">Handle command output.</link>
-					</para>
-					<list class="bullet">
-						<listItem>
-							<para>
-								<link xlink:href="#GetExecutionResultSection">Get execution result.</link>
-							</para>
-						</listItem>
-						<listItem>
-							<para>
-								<link xlink:href="#ReadOutputStreamSection">Read OutputStream.</link>
-							</para>
-						</listItem>
-
-						<listItem>
-							<para>
-								<link xlink:href="#ReadExtendedOutputStreamSection">Read ExtendedOutputStream.</link>
-							</para>
-						</listItem>
-						<listItem>
-							<para>
-								<link xlink:href="#HandleExitStatusSection">Handle exit status.</link>
-							</para>
-						</listItem>
-					</list>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#CommandExecutionTimeoutSection">Asynchronous command execution.</link>
-					</para>
-				</listItem>
-
-				<listItem>
-					<para>
-						<link xlink:href="#CommandExecutionTimeoutSection">Cancel asynchronous command execution.</link>
-					</para>
-				</listItem>
-
-			</list>
-		</introduction>
-
-		<section address="CommandExecutionOverviewSection">
-			<title>Command execution overview</title>
-			<content>
-				<para>
-					Command execution feature simulates scenario where single command line can be executed on the remote host.
-					SshClient takes command text as it is and passes it to the remote host for execution.
-					If command cannot be executed on the remote host the <codeEntityReference>P:Renci.SshNet.SshCommand.Error</codeEntityReference> property will have a description why the execution failed and <codeEntityReference>P:Renci.SshNet.SshCommand.ExitStatus</codeEntityReference> property will have value other then 0.
-					One command execution is not aware of previouse executions so if you execute first "cd /etc" and then next command "ls -l", it will not list you the content of "etc" folder.
-					This is due to the fact that only one command can be executed on one channel.
-					Command execution running in the context of default shell specified by remote host.
-				</para>
-			</content>
-		</section>
-
-		<section address="SimpleCommandExecutionSection">
-			<title>Simple command execution</title>
-			<content>
-				<para>
-					To run simple command you dont have to use <codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference> but simply provide command text to <codeEntityReference>M:Renci.SshNet.SshClient.RunCommand(System.String)</codeEntityReference> method.
-				</para>
-				<code language="cs" title="Execute simple command example">
-					<![CDATA[  
-
-			using (var client = new SshClient("host", "username", "password"))
-			{
-					client.Connect();
-			
-					client.RunCommand("touch abc.txt");
-			
-					client.Disconnect();
-			}
-			
-]]>
-				</code>
-			</content>
-		</section>
-
-		<section address="UsingSshCommandSection">
-			<title>Using SshCommand object</title>
-			<content>
-				<para>
-					For more complex scenarious where you need more control over command execution you need will need to create <codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference> to execute a command.
-					You can create a command without executing it by calling <codeEntityReference>M:Renci.SshNet.SshClient.CreateCommand(System.String)</codeEntityReference> method.
-				</para>
-				<code language="cs" title="Create SshCommand object example">
-					<![CDATA[  
-					
-					var command = ssh.CreateCommand("touch abc.txt");
-					
-]]>
-				</code>
-				<para>
-					Once <codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference> object  is created you can execute a command by calling <codeEntityReference>M:Renci.SshNet.SshCommand.Execute</codeEntityReference> method.
-				</para>
-				<code language="cs" title="Execute SshCommand object example">
-					<![CDATA[  
-					
-					
-					var command = ssh.CreateCommand("touch abc.txt");
-					
-					command.Execute();
-										
-]]>
-				</code>
-			</content>
-		</section>
-
-		<section address="ReuseSshCommandSection">
-			<title>Reuse SshCommand object</title>
-			<content>
-				<para>
-					Once <codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference> object is created you can use it multiple times to run either same command or new one.
-					<alert class="note">
-						<para>Even so the object is the same, it still will not remeber prior command execution.</para>
-					</alert>
-
-				</para>
-				<code language="cs" title="Execute simple command example">
-					<![CDATA[  
-
-			using (var client = new SshClient("host", "username", "password"))
-			{
-					client.Connect();
-			
-					var cmd = client.CreateCommand("date");
-					
-					cmd.Execute();
-					
-					Console.WriteLine(cmd.Result);
-					
-					cmd.Execute("ls -l");
-					
-					Console.WriteLine(cmd.Result);
-
-					client.Disconnect();
-			}
-			
-]]>
-				</code>
-			</content>
-		</section>
-		
-		<section address="CommandExecutionTimeoutSection">
-			<title>Command execution timeout</title>
-			<content>
-				<para>
-				</para>
-				<code language="cs" title="Execute simple command example">
-					<![CDATA[  
-			
-]]>
-				</code>
-			</content>
-		</section>
-
-		<section address="HandleCommandOutputSection">
-			<title>Handle command output</title>
-			<content>
-				<para>
-					When command executes the result execution stored in <codeEntityReference>P:Renci.SshNet.SshCommand.Result</codeEntityReference> property.
-					If you execute command asynchronously then you can access command result as it becomes available using <codeEntityReference>P:Renci.SshNet.SshCommand.OutputStream</codeEntityReference> property.
-				</para>
-			</content>
-			<sections>
-
-				<section address="GetExecutionResultSection">
-					<title>Get execution result</title>
-					<content>
-						<para>
-							To get command execution output you can get <codeEntityReference>P:Renci.SshNet.SshCommand.Result</codeEntityReference> property value after command finished execution.
-						</para>
-						<code language="cs" title="Using Result property example">
-							<![CDATA[  
-			
-							using (var client = new SshClient("host", "username", "password"))
-							{
-									client.Connect();
-									
-									var cmd = client.RunCommand("ls -l");
-									
-									Console.WriteLine(cmd.Result);
-									
-									client.Disconnect();
-							
-							}
-							
-]]>
-						</code>
-					</content>
-				</section>
-
-				<section address="ReadOutputStreamSection">
-					<title>Read OutputStream</title>
-					<content>
-						<para>
-							In asynchronous scenrio you can access avaialble command execution output by reading <codeEntityReference>P:Renci.SshNet.SshCommand.OutputStream</codeEntityReference> property.
-							This stream will have data as it becomes available.
-							This output stream will contain command raw output as it returned by the remote host so it will require some proccessing before it can be presented to the user.
-						</para>
-						<code language="cs" title="Read OutputStream property example">
-							<![CDATA[  
-			
-							using (var ssh = new SshClient(connectionInfo))
-							{
-									ssh.Connect();
-									var cmd = ssh.CreateCommand("ls -l");   //  very long list
-									var asynch = cmd.BeginExecute(delegate(IAsyncResult ar)
-									{
-											Console.WriteLine("Finished.");
-									}, null);
-
-									var reader = new StreamReader(cmd.OutputStream);
-
-									while (!asynch.IsCompleted)
-									{
-											var result = reader.ReadToEnd();
-											if (string.IsNullOrEmpty(result))
-													continue;
-											Console.Write(result);
-									}
-									cmd.EndExecute(asynch);
-							}
-							
-]]>
-						</code>
-					</content>
-				</section>
-
-				<section address="ReadExtendedOutputStreamSection">
-					<title>Read ExtendedOutputStream</title>
-					<content>
-						<para>
-              If some command that you execute writes any debug output then it can be retreived by reading <codeEntityReference>P:Renci.SshNet.SshCommand.ExtendedOutputStream</codeEntityReference> property similar to <codeEntityReference>P:Renci.SshNet.SshCommand.OutputStream</codeEntityReference>.
-            </para>
-            <code language="cs" title="Read ExtendedOutputStream property example">
-              <![CDATA[  
-			
-            using (var ssh = new SshClient(connectionInfo))
-            {
-                ssh.Connect();
-                var cmd = ssh.CreateCommand("echo 12345; echo 654321 >&2");
-                var result = cmd.Execute();
-
-                Console.Write(result);
-
-                var reader = new StreamReader(cmd.ExtendedOutputStream);
-                Console.WriteLine("DEBUG:");
-                Console.Write(reader.ReadToEnd());
-            }							
-]]>
-            </code>
-          </content>
-				</section>
-
-				<section address="HandleExitStatusSection">
-					<title>Handle exit status</title>
-					<content>
-						<para>
-              All commands, after execution report execution status back to the client. Usually zero value means that executed succesfully and otherwise not zero.
-              In some cases return code need to be analized to perform further action. Command execution exit return code located in <codeEntityReference>P:Renci.SshNet.SshCommand.ExtendedOutputStream</codeEntityReference> property similar to <codeEntityReference>P:Renci.SshNet.SshCommand.ExitStatus</codeEntityReference> property.
-						</para>
-            <code language="cs" title="Use ExitStatus property example">
-              <![CDATA[  
-			
-            using (var ssh = new SshClient(connectionInfo))
-            {
-                ssh.Connect();
-                var cmd = ssh.CreateCommand("echo 'debug output test';exit 12");
-                var result = cmd.Execute();
-
-                Console.Write(result);
-                Console.Write(cmd.ExitStatus);
-            }
-]]>
-            </code>
-          </content>
-				</section>
-			</sections>
-		</section>
-    
-		<relatedTopics>
-			<codeEntityReference qualifyHint="true" autoUpgrade="true">M:Renci.SshNet.SshClient.RunCommand(System.String)</codeEntityReference>
-		</relatedTopics>
-	</developerConceptualDocument>
-</topic>

+ 0 - 31
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/StatusCode.aml

@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="8fdc3979-5d00-4749-8dd4-a0e66d14a976" revisionNumber="1">
-  <developerWhitePaperDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-      <title>Execution errors</title>
-      <content>
-      	When command is executed you can retrive command execution exit status by accessing <codeEntityReference>P:Renci.SshNet.SshCommand.ExitStatus</codeEntityReference> property.
-        <para>See examples below:</para>
-        <codeExample>
-          <list class="ordered">
-            <listItem>
-              <para>Display exit status when command is executed.</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", "password"))
-                {
-	                client.Connect();
-	                var cmd = client.RunCommand("exit 128");
-	                cmd.Execute();
-	                Console.WriteLine(cmd.ExitStatus);	// Should display 128
-	                client.Disconnect();
-                }
-              </code>
-            </listItem>
-          </list>
-        </codeExample>
-      </content>
-    <relatedTopics>
-	    <codeEntityReference>P:Renci.SshNet.SshCommand.ExitStatus</codeEntityReference>
-		<codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference>
-    </relatedTopics>
-  </developerWhitePaperDocument>
-</topic>

+ 0 - 32
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Commands/Timeout.aml

@@ -1,32 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="b9451bd3-f759-4964-8f42-b48b06c19dca" revisionNumber="1">
-  <developerHowToDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-      <title>Command execution</title>
-      <content>
-      	When you need to terminte the command after specific time has passed you can use <codeEntityReference>P:Renci.SshNet.SshCommand.CommandTimeout</codeEntityReference> property.
-      	To specify time out property you must to create <codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference> first.
-        <para>See examples below:</para>
-        <codeExample>
-          <list class="ordered">
-            <listItem>
-              <para>Execute command and specify 10 sec timeout</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", "password"))
-                {
-	                client.Connect();
-	                var cmd = client.CreateCommand("sleep 10s");
-	                cmd.CommandTimeout = TimeSpan.FromSeconds(5);
-	                cmd.Execute();
-	                client.Disconnect();
-                }
-              </code>
-            </listItem>
-          </list>
-        </codeExample>
-      </content>
-    <relatedTopics>
-		<codeEntityReference>P:Renci.SshNet.SshCommand.CommandTimeout</codeEntityReference>
-		<codeEntityReference>T:Renci.SshNet.SshCommand</codeEntityReference>
-    </relatedTopics>
-  </developerHowToDocument>
-</topic>

+ 0 - 31
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Overview.aml

@@ -1,31 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="37443441-b0d5-444f-a2d0-330ad8b95995" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>
-        This topic describes how to perform different operations using <codeEntityReference>E:Renci.SshNet.SshClient</codeEntityReference>.
-      </para>
-      <list class="bullet">
-        <listItem>
-          <para>
-            <link xlink:href="2337d96d-7638-438e-b980-96e87b807265">Command execution.</link>
-          </para>
-        </listItem>
-
-        <listItem>
-          <para>
-            <link xlink:href="f4ce1bdd-403f-45ec-a622-86c05a4bd913">Port Forwarding.</link>
-          </para>
-        </listItem>
-
-        <listItem>
-          <para>
-            <link xlink:href="86bd5fce-2370-4730-b956-364885f7ed6a">Shell functionality.</link>
-          </para>
-        </listItem>
-	</list>
-    </introduction>
-    <relatedTopics>
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 30
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/PortForwarding/Local.aml

@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="07e8ea92-89dd-45ab-a35f-34a3202243e1" revisionNumber="1">
-  <developerHowToDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-      <content>
-        <codeExample>
-              <para>Start and stop local port forwarding.</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", "password"))
-                {
-                	client.Connect();
-	                var port = client.AddForwardedPort&lt;ForwardedPortLocal&gt;(8084, "host to be forwarded", 80);
-	                port.Exception += delegate(object sender, ExceptionEventArgs e)
-	                {
-	                    Console.WriteLine(e.Exception.ToString());
-	                };
-	                port.Start();
-	                
-	                Thread.Sleep(1000 * 60 * 20); //	Wait 20 minutes for port to be forwarded
-	                
-	                port.Stop();
-                }
-              </code>
-        </codeExample>
-      </content>
-    <relatedTopics>
-	    <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference>
-		<codeEntityReference>T:Renci.SshNet.ForwardedPortLocal</codeEntityReference>
-    </relatedTopics>
-  </developerHowToDocument>
-</topic>

+ 0 - 17
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/PortForwarding/Overview.aml

@@ -1,17 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="f4ce1bdd-403f-45ec-a622-86c05a4bd913" revisionNumber="1">
-  <developerHowToDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <introduction>
-      <para>Port forwarding supported for remote and local ports.</para>
-      <para>Multiple port can be forwarded simultaneously.</para>
-      <para>To start port forwarding you need to create an <codeEntityReference>T:Renci.SshNet.ForwardedPortLocal</codeEntityReference> or <codeEntityReference>T:Renci.SshNet.ForwardedPortRemote </codeEntityReference> object.
-      Once port object is created you can use <codeEntityReference>M:Renci.SshNet.ForwardedPort.Start</codeEntityReference> start port forwarding or <codeEntityReference>M:Renci.SshNet.ForwardedPort.Stop</codeEntityReference> to stop it.
-      </para>
-      
-<alert class="tip">
-  <para>An exception can be thrown while port is forwarded. When this happens an <codeEntityReference>E:Renci.SshNet.ForwardedPort.Exception</codeEntityReference> event is raised.</para>
-</alert>
-
-    </introduction>
-  </developerHowToDocument>
-</topic>

+ 0 - 30
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/PortForwarding/Remote.aml

@@ -1,30 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="a28b7535-bc8c-4635-a60a-d9067e60f1c9" revisionNumber="1">
-  <developerOrientationDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-      <content>
-        <codeExample>
-              <para>Start and stop local port forwarding.</para>
-              <code language="cs">
-                using (var client = new SshClient("host", "username", "password"))
-                {
-                	client.Connect();
-	                var port = client.AddForwardedPort&lt;ForwardedPortRemote&gt;(8082, "host to be forwarded", 80);
-	                port.Exception += delegate(object sender, ExceptionEventArgs e)
-	                {
-	                    Console.WriteLine(e.Exception.ToString());
-	                };
-	                port.Start();
-	                
-	                Thread.Sleep(1000 * 60 * 20); //	Wait 20 minutes for port to be forwarded
-	                
-	                port.Stop();
-                }
-              </code>
-        </codeExample>
-      </content>
-    <relatedTopics>
-	    <codeEntityReference>T:Renci.SshNet.SshClient</codeEntityReference>
-		<codeEntityReference>T:Renci.SshNet.ForwardedPortLocal</codeEntityReference>
-    </relatedTopics>
-  </developerOrientationDocument>
-</topic>

+ 0 - 82
Renci.SshClient/Renci.SshNet/Documentation/Content/Guide/SshClient/Shell/Overview.aml

@@ -1,82 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="86bd5fce-2370-4730-b956-364885f7ed6a" revisionNumber="1">
-  <developerConceptualDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!--
-    <summary>
-      <para>Optional summary abstract</para>
-    </summary>
-    -->
-    <introduction>
-      <!-- Uncomment this to generate an outline of the section and sub-section
-           titles.  Specify a numeric value as the inner text to limit it to
-           a specific number of sub-topics when creating the outline.  Specify
-           zero (0) to limit it to top-level sections only.  -->
-      <!-- <autoOutline /> -->
-      <para>Required introduction</para>
-    </introduction>
-    <!-- Add one or more top-level section elements.  These are collapsible.
-         If using <autoOutline />, add an address attribute to identify it
-         and specify a title so that it can be jumped to with a hyperlink. -->
-    <section address="Section1">
-      <title>Optional section title</title>
-      <content>
-        <!-- Uncomment this to create a sub-section outline
-        <autoOutline /> -->
-        <para>Add one or more sections with content</para>
-      </content>
-      <!-- If a section contains a sections element, its content creates
-           sub-sections.  These are not collapsible.
-      <sections>
-          <section address="SubSection1">
-              <title>Sub-section 1</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-          <section address="SubSection2">
-              <title>Sub-section 2</title>
-              <content>
-                  <para>Sub-section content.</para>
-              </content>
-          </section>
-      </sections> -->
-    </section>
-    <relatedTopics>
-      <!-- One or more of the following:
-           - A local link
-           - An external link
-           - A code entity reference
-
-      <link xlink:href="Other Topic's ID"/>
-      <link xlink:href="Other Topic's ID">Link inner text</link>
-
-      <externalLink>
-          <linkText>Link text</linkText>
-          <linkAlternateText>Optional alternate link text</linkAlternateText>
-          <linkUri>URI</linkUri>
-      </externalLink>
-
-      <codeEntityReference>API member ID</codeEntityReference>
-
-      Examples:
-
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8270" />
-      <link xlink:href="00e97994-e9e6-46e0-b420-5be86b2f8278">Some other topic</link>
-
-      <externalLink>
-          <linkText>SHFB on CodePlex</linkText>
-          <linkAlternateText>Go to CodePlex</linkAlternateText>
-          <linkUri>http://shfb.codeplex.com</linkUri>
-      </externalLink>
-
-      <codeEntityReference>T:TestDoc.TestClass</codeEntityReference>
-      <codeEntityReference>P:TestDoc.TestClass.SomeProperty</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.#ctor(System.String,System.Int32)</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.ToString</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.FirstMethod</codeEntityReference>
-      <codeEntityReference>M:TestDoc.TestClass.SecondMethod(System.Int32,System.String)</codeEntityReference>
-      -->
-    </relatedTopics>
-  </developerConceptualDocument>
-</topic>

+ 0 - 16
Renci.SshClient/Renci.SshNet/Documentation/Content/Reference.aml

@@ -1,16 +0,0 @@
-<?xml version="1.0" encoding="utf-8"?>
-<topic id="8e553ec7-3a42-4bd1-9252-b9b3c957b454" revisionNumber="1">
-  <codeEntityDocument xmlns="http://ddue.schemas.microsoft.com/authoring/2003/5" xmlns:xlink="http://www.w3.org/1999/xlink">
-    <!-- NOTE: This is similar to the API reference documentation which is
-         produced by the reference build.  You should probably just use that
-         instead of this. -->
-    <assembly>
-      <assemblyName>Assembly name</assemblyName>
-    </assembly>
-    <codeEntities>
-      <codeEntity>
-        <codeEntityReference>API member ID</codeEntityReference>
-      </codeEntity>
-    </codeEntities>
-  </codeEntityDocument>
-</topic>

+ 3 - 0
Renci.SshClient/Renci.SshNet/ForwardedPortLocal.cs

@@ -36,6 +36,9 @@ namespace Renci.SshNet
         /// <param name="boundPort">The bound port.</param>
         /// <param name="host">The host.</param>
         /// <param name="port">The port.</param>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\ForwardedPortLocalTest.cs" region="Example SshClient AddForwardedPort Start Stop ForwardedPortLocal" language="C#" title="Local port forwarding" />
+        /// </example>
         public ForwardedPortLocal(uint boundPort, string host, uint port)
             : this(string.Empty, boundPort, host, port)
         {

+ 3 - 0
Renci.SshClient/Renci.SshNet/ForwardedPortRemote.cs

@@ -43,6 +43,9 @@ namespace Renci.SshNet
         /// <param name="boundPort">The bound port.</param>
         /// <param name="host">The host.</param>
         /// <param name="port">The port.</param>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\ForwardedPortRemoteTest.cs" region="Example SshClient AddForwardedPort Start Stop ForwardedPortRemote" language="C#" title="Remote port forwarding" />
+        /// </example>
         public ForwardedPortRemote(uint boundPort, string host, uint port)
             : this(string.Empty, boundPort, host, port)
         {

+ 6 - 0
Renci.SshClient/Renci.SshNet/KeyboardInteractiveConnectionInfo.cs

@@ -9,11 +9,17 @@ namespace Renci.SshNet
     /// <summary>
     /// Provides connection information when keyboard interactive authentication method is used
     /// </summary>
+    /// <example>
+    ///     <code source="..\..\Renci.SshNet.Tests\Classes\KeyboardInteractiveConnectionInfoTest.cs" region="Example KeyboardInteractiveConnectionInfo AuthenticationPrompt" language="C#" title="Connect using interactive method" />
+    /// </example>
     public class KeyboardInteractiveConnectionInfo : ConnectionInfo, IDisposable
     {
         /// <summary>
         /// Occurs when server prompts for more authentication information.
         /// </summary>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\KeyboardInteractiveConnectionInfoTest.cs" region="Example KeyboardInteractiveConnectionInfo AuthenticationPrompt" language="C#" title="Connect using interactive method" />
+        /// </example>
         public event EventHandler<AuthenticationPromptEventArgs> AuthenticationPrompt;
 
         //  TODO: DOCS Add exception documentation for this class.

+ 13 - 7
Renci.SshClient/Renci.SshNet/PasswordConnectionInfo.cs

@@ -9,27 +9,33 @@ namespace Renci.SshNet
     /// <summary>
     /// Provides connection information when password authentication method is used
     /// </summary>
-    /// <remarks>
-    /// Connect to the server using PasswordConnectionInfo object
-    /// <code source="..\Examples\PasswordConnectionInfo.cs" region="ConnectUsingPasswordConnectionInfo" language="C#" title="Connect using PasswordConnectionInfo object" />
-    /// </remarks>
+    /// <example>
+    ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo" language="C#" title="Connect using username and password" />
+    ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo PasswordExpired" language="C#" title="Change password when connecting" />
+    ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo AuthenticationBanner" language="C#" title="Display authentication banner" />
+    /// </example>
     public class PasswordConnectionInfo : ConnectionInfo, IDisposable
     {
         /// <summary>
         /// Occurs when user's password has expired and needs to be changed.
         /// </summary>
         /// <example>
-        ///     This is an example of how to change expired password during connection phase.
-        ///     <code source="..\Examples\PasswordConnectionInfo.cs" region="ChangePasswordWhenConnecting" language="C#" title="Change password when connecting" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo PasswordExpired" language="C#" title="Change password when connecting" />
         /// </example>
         public event EventHandler<AuthenticationPasswordChangeEventArgs> PasswordExpired;
 
         /// <summary>
-        /// Initializes a new instance of the <see cref="PasswordConnectionInfo"/> class.
+        /// Initializes a new instance of the <see cref="PasswordConnectionInfo" /> class.
         /// </summary>
         /// <param name="host">Connection host.</param>
         /// <param name="username">Connection username.</param>
         /// <param name="password">Connection password.</param>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo" language="C#" title="Connect using username and password" />
+        /// </example>
+        /// <exception cref="ArgumentNullException"><paramref name="password"/> is null.</exception>
+        /// <exception cref="ArgumentException"><paramref name="host"/> is invalid, or <paramref name="username"/> is null or contains whitespace characters.</exception>
+        /// <exception cref="ArgumentOutOfRangeException"><paramref name="port"/> is not within <see cref="F:System.Net.IPEndPoint.MinPort"/> and <see cref="F:System.Net.IPEndPoint.MaxPort"/>.</exception>
         public PasswordConnectionInfo(string host, string username, string password)
             : this(host, ConnectionInfo.DEFAULT_PORT, username, Encoding.UTF8.GetBytes(password))
         {

+ 6 - 3
Renci.SshClient/Renci.SshNet/PrivateKeyConnectionInfo.cs

@@ -10,9 +10,8 @@ namespace Renci.SshNet
     /// Provides connection information when private key authentication method is used
     /// </summary>
     /// <example>
-    ///     Key examples
-    ///     <code source="..\Examples\PrivateKeyConnectionInfo.cs" region="ConnectUsingPrivateKeyConnectionInfo" language="C#" title="Connection example" />
-    /// </example>
+    ///   <code source="..\..\Renci.SshNet.Tests\Classes\PrivateKeyConnectionInfoTest.cs" region="Example PrivateKeyConnectionInfo PrivateKeyFile" language="C#" title="Connect using private key" />
+    ///   </example>
     public class PrivateKeyConnectionInfo : ConnectionInfo, IDisposable
     {
         /// <summary>
@@ -26,6 +25,10 @@ namespace Renci.SshNet
         /// <param name="host">Connection host.</param>
         /// <param name="username">Connection username.</param>
         /// <param name="keyFiles">Connection key files.</param>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PrivateKeyConnectionInfoTest.cs" region="Example PrivateKeyConnectionInfo PrivateKeyFile" language="C#" title="Connect using private key" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PrivateKeyConnectionInfoTest.cs" region="Example PrivateKeyConnectionInfo PrivateKeyFile Multiple" language="C#" title="Connect using multiple private key" />
+        /// </example>
         public PrivateKeyConnectionInfo(string host, string username, params PrivateKeyFile[] keyFiles)
             : this(host, ConnectionInfo.DEFAULT_PORT, username, ProxyTypes.None, string.Empty, 0, string.Empty, string.Empty, keyFiles)
         {

+ 1 - 2
Renci.SshClient/Renci.SshNet/PrivateKeyFile.cs

@@ -21,8 +21,7 @@ namespace Renci.SshNet
     /// Represents private key information
     /// </summary>
     /// <example>
-    ///     Key examples
-    ///     <code source="..\Examples\PrivateKeyFile.cs" region="RSAKeyExample" language="C#" title="Private RSA key example" />
+    ///     <code source="..\..\Renci.SshNet.Tests\Data\Key.RSA.txt" language="Text" title="Private RSA key example" />
     /// </example>
     public class PrivateKeyFile : IDisposable
     {

+ 0 - 31
Renci.SshClient/Renci.SshNet/Renci.SshNet.csproj

@@ -131,10 +131,6 @@
       <SubType>Code</SubType>
     </Compile>
     <Compile Include="ConnectionInfo.cs" />
-    <Compile Include="Examples\PasswordConnectionInfo.cs" />
-    <Compile Include="Examples\PrivateKeyConnectionInfo.cs" />
-    <Compile Include="Examples\PrivateKeyFile.cs" />
-    <Compile Include="Examples\SshClient.cs" />
     <Compile Include="ShellStream.NET40.cs" />
     <Compile Include="ExpectAsyncResult.cs" />
     <Compile Include="Security\KeyExchangeDiffieHellmanGroupSha1.cs" />
@@ -436,37 +432,10 @@
     </Compile>
     <Compile Include="SshClient.cs" />
     <Compile Include="SshCommand.cs" />
-    <Compile Include="Examples\SshCommand.cs" />
     <Compile Include="SshCommand.NET40.cs" />
     <Compile Include="SubsystemSession.cs" />
   </ItemGroup>
   <ItemGroup>
-    <None Include="Documentation\Content\About.aml" />
-    <None Include="Documentation\Content\Guide\Connection\Interactive.aml" />
-    <None Include="Documentation\Content\Guide\Connection\Overview.aml" />
-    <None Include="Documentation\Content\Guide\Connection\Password.aml" />
-    <None Include="Documentation\Content\Guide\Connection\PrivateKey.aml" />
-    <None Include="Documentation\Content\Guide\Errors.aml" />
-    <None Include="Documentation\Content\Guide\NetConfClient\Overview.aml" />
-    <None Include="Documentation\Content\Guide\Overview.aml" />
-    <None Include="Documentation\Content\Guide\ScpClient\Overview.aml" />
-    <None Include="Documentation\Content\Guide\SftpClient\Overview.aml" />
-    <None Include="Documentation\Content\Guide\SftpClient\SftpFile.aml" />
-    <None Include="Documentation\Content\Guide\SftpClient\SftpFileStream.aml" />
-    <None Include="Documentation\Content\Guide\SftpClient\SftpOperations.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Commands\Asynchronous.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Commands\Errors.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Commands\Execute.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Commands\Multitasking.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Commands\Overview.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Commands\StatusCode.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Commands\Timeout.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Overview.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\PortForwarding\Local.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\PortForwarding\Overview.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\PortForwarding\Remote.aml" />
-    <None Include="Documentation\Content\Guide\SshClient\Shell\Overview.aml" />
-    <None Include="Documentation\Content\Reference.aml" />
     <None Include="Documentation\Renci.SshNet.content" />
   </ItemGroup>
   <ItemGroup>

+ 19 - 8
Renci.SshClient/Renci.SshNet/SshClient.cs

@@ -43,8 +43,10 @@ namespace Renci.SshNet
         /// </summary>
         /// <param name="connectionInfo">The connection info.</param>
         /// <example>
-        ///     Connect to the server using PasswordConnectionInfo object
-        ///     <code source="..\Examples\PasswordConnectionInfo.cs" region="ConnectUsingPasswordConnectionInfo" language="C#" title="Connect using PasswordConnectionInfo object" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo" language="C#" title="Connect using PasswordConnectionInfo object" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PasswordConnectionInfoTest.cs" region="Example PasswordConnectionInfo PasswordExpired" language="C#" title="Connect using PasswordConnectionInfo object with passwod change option" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\PrivateKeyConnectionInfoTest.cs" region="Example PrivateKeyConnectionInfo PrivateKeyFile" language="C#" title="Connect using PrivateKeyConnectionInfo" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient Connect Timeout" language="C#" title="Specify connection timeout when connecting" />
         /// </example>
         /// <exception cref="ArgumentNullException"><paramref name="connectionInfo"/> is null.</exception>
         public SshClient(ConnectionInfo connectionInfo)
@@ -76,8 +78,7 @@ namespace Renci.SshNet
         /// <param name="username">Authentication username.</param>
         /// <param name="password">Authentication password.</param>
         /// <example>
-        ///     Connect to server using username and password combination
-        ///     <code source="..\Examples\SshClient.cs" region="CreateSshClientWithUsernamePassword" language="C#" title="Connect using username and password" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient(host, username) Connect" language="C#" title="Connect using username and password" />
         /// </example>
         /// <exception cref="ArgumentNullException"><paramref name="password"/> is null.</exception>
         /// <exception cref="ArgumentException"><paramref name="host"/> is invalid, or <paramref name="username"/> is null or contains whitespace characters.</exception>
@@ -93,6 +94,10 @@ namespace Renci.SshNet
         /// <param name="port">Connection port.</param>
         /// <param name="username">Authentication username.</param>
         /// <param name="keyFiles">Authentication private key file(s) .</param>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient(host, username) Connect PrivateKeyFile" language="C#" title="Connect using username and private key" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient(host, username) Connect PrivateKeyFile PassPhrase" language="C#" title="Connect using username and private key and pass phrase" />
+        /// </example>
         /// <exception cref="ArgumentNullException"><paramref name="keyFiles"/> is null.</exception>
         /// <exception cref="ArgumentException"><paramref name="host"/> is invalid, -or- <paramref name="username"/> is null or contains whitespace characters.</exception>
         /// <exception cref="ArgumentOutOfRangeException"><paramref name="port"/> is not within <see cref="F:System.Net.IPEndPoint.MinPort"/> and <see cref="System.Net.IPEndPoint.MaxPort"/>.</exception>
@@ -110,10 +115,8 @@ namespace Renci.SshNet
         /// <param name="username">Authentication username.</param>
         /// <param name="keyFiles">Authentication private key file(s) .</param>
         /// <example>
-        ///     Connect to server using private key
-        ///     <code source="..\Examples\SshClient.cs" region="ConnectUsingPrivateKey" language="C#" title="Connect using private key" />
-        ///     Connect to server using private key and pass phrase
-        ///     <code source="..\Examples\SshClient.cs" region="ConnectUsingPrivateKeyAndPassphrase" language="C#" title="Connect using private key and pass phrase" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient(host, username) Connect PrivateKeyFile" language="C#" title="Connect using private key" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshClientTest.cs" region="Example SshClient(host, username) Connect PrivateKeyFile PassPhrase" language="C#" title="Connect using private key and pass phrase" />
         /// </example>
         /// <exception cref="ArgumentNullException"><paramref name="keyFiles"/> is null.</exception>
         /// <exception cref="ArgumentException"><paramref name="host"/> is invalid, -or- <paramref name="username"/> is null or contains whitespace characters.</exception>
@@ -141,6 +144,10 @@ namespace Renci.SshNet
         /// Adds the forwarded port.
         /// </summary>
         /// <param name="port">The port.</param>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\ForwardedPortRemoteTest.cs" region="Example SshClient AddForwardedPort Start Stop ForwardedPortRemote" language="C#" title="Remote port forwarding" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\ForwardedPortLocalTest.cs" region="Example SshClient AddForwardedPort Start Stop ForwardedPortLocal" language="C#" title="Local port forwarding" />
+        /// </example>
         /// <exception cref="InvalidOperationException">Forwarded port is already added to a different client.</exception>
         /// <exception cref="ArgumentNullException"><paramref name="port"/> is null.</exception>
         /// <exception cref="SshConnectionException">Client is not connected.</exception>
@@ -211,6 +218,10 @@ namespace Renci.SshNet
         /// <param name="commandText">The command text.</param>
         /// <returns>Returns an instance of <see cref="SshCommand"/> with execution results.</returns>
         /// <remarks>This method internally uses asynchronous calls.</remarks>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand RunCommand Result" language="C#" title="Running simple command" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.NET40.cs" region="Example SshCommand RunCommand Parallel" language="C#" title="Run many commands in parallel" />
+        /// </example>
         /// <exception cref="ArgumentException">CommandText property is empty.</exception>
         /// <exception cref="T:Renci.SshNet.Common.SshException">Invalid Operation - An existing channel was used to execute this command.</exception>
         /// <exception cref="InvalidOperationException">Asynchronous operation is already in progress.</exception>

+ 66 - 0
Renci.SshClient/Renci.SshNet/SshCommand.cs

@@ -46,27 +46,42 @@ namespace Renci.SshNet
         /// <value>
         /// The command timeout.
         /// </value>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand Execute CommandTimeout" language="C#" title="Specify command execution timeout" />
+        /// </example>
         public TimeSpan CommandTimeout { get; set; }
 
         /// <summary>
         /// Gets the command exit status.
         /// </summary>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand RunCommand ExitStatus" language="C#" title="Get command execution exit status" />
+        /// </example>
         public int ExitStatus { get; private set; }
 
         /// <summary>
         /// Gets the output stream.
         /// </summary>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand Execute OutputStream" language="C#" title="Use OutputStream to get command execution output" />
+        /// </example>
         public Stream OutputStream { get; private set; }
 
         /// <summary>
         /// Gets the extended output stream.
         /// </summary>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand Execute ExtendedOutputStream" language="C#" title="Use ExtendedOutputStream to get command debug execution output" />
+        /// </example>
         public Stream ExtendedOutputStream { get; private set; }
 
         private StringBuilder _result;
         /// <summary>
         /// Gets the command execution result.
         /// </summary>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand RunCommand Result" language="C#" title="Running simple command" />
+        /// </example>
         public string Result
         {
             get
@@ -92,6 +107,9 @@ namespace Renci.SshNet
         /// <summary>
         /// Gets the command execution error.
         /// </summary>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand Error" language="C#" title="Display command execution error" />
+        /// </example>
         public string Error
         {
             get
@@ -142,6 +160,46 @@ namespace Renci.SshNet
             this._session.ErrorOccured += Session_ErrorOccured;
         }
 
+        /// <summary>
+        /// Begins an asynchronous command execution.
+        /// </summary>
+        /// <returns>
+        /// An <see cref="System.IAsyncResult" /> that represents the asynchronous command execution, which could still be pending.
+        /// </returns>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand BeginExecute IsCompleted EndExecute" language="C#" title="Asynchronous Command Execution" />
+        /// </example>
+        /// <exception cref="System.InvalidOperationException">Asynchronous operation is already in progress.</exception>
+        /// <exception cref="SshException">Invalid operation.</exception>
+        /// <exception cref="System.ArgumentException">CommandText property is empty.</exception>
+        /// <exception cref="Renci.SshNet.Common.SshConnectionException">Client is not connected.</exception>
+        /// <exception cref="Renci.SshNet.Common.SshOperationTimeoutException">Operation has timed out.</exception>
+        /// <exception cref="InvalidOperationException">Asynchronous operation is already in progress.</exception>
+        /// <exception cref="ArgumentException">CommandText property is empty.</exception>
+        public IAsyncResult BeginExecute()
+        {
+            return this.BeginExecute(null, null);
+        }
+
+        /// <summary>
+        /// Begins an asynchronous command execution.
+        /// </summary>
+        /// <param name="callback">An optional asynchronous callback, to be called when the command execution is complete.</param>
+        /// <returns>
+        /// An <see cref="System.IAsyncResult" /> that represents the asynchronous command execution, which could still be pending.
+        /// </returns>
+        /// <exception cref="System.InvalidOperationException">Asynchronous operation is already in progress.</exception>
+        /// <exception cref="SshException">Invalid operation.</exception>
+        /// <exception cref="System.ArgumentException">CommandText property is empty.</exception>
+        /// <exception cref="Renci.SshNet.Common.SshConnectionException">Client is not connected.</exception>
+        /// <exception cref="Renci.SshNet.Common.SshOperationTimeoutException">Operation has timed out.</exception>
+        /// <exception cref="InvalidOperationException">Asynchronous operation is already in progress.</exception>
+        /// <exception cref="ArgumentException">CommandText property is empty.</exception>
+        public IAsyncResult BeginExecute(AsyncCallback callback)
+        {
+            return this.BeginExecute(callback, null);
+        }
+
         /// <summary>
         /// Begins an asynchronous command execution.
         /// </summary>
@@ -217,6 +275,9 @@ namespace Renci.SshNet
         /// </summary>
         /// <param name="asyncResult">The reference to the pending asynchronous request to finish.</param>
         /// <returns>Command execution result.</returns>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand BeginExecute IsCompleted EndExecute" language="C#" title="Asynchronous Command Execution" />
+        /// </example>
         /// <exception cref="System.ArgumentException">Either the IAsyncResult object did not come from the corresponding async method on this type, or EndExecute was called multiple times with the same IAsyncResult.</exception>
         /// <exception cref="ArgumentException">Either the IAsyncResult object did not come from the corresponding async method on this type, or EndExecute was called multiple times with the same IAsyncResult.</exception>
         public string EndExecute(IAsyncResult asyncResult)
@@ -253,6 +314,11 @@ namespace Renci.SshNet
         /// Executes command specified by <see cref="CommandText"/> property.
         /// </summary>
         /// <returns>Command execution result</returns>
+        /// <example>
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand Execute" language="C#" title="Simple command execution" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand Error" language="C#" title="Display command execution error" />
+        ///     <code source="..\..\Renci.SshNet.Tests\Classes\SshCommandTest.cs" region="Example SshCommand CreateCommand Execute CommandTimeout" language="C#" title="Specify command execution timeout" />
+        /// </example>
         /// <exception cref="Renci.SshNet.Common.SshConnectionException">Client is not connected.</exception>
         /// <exception cref="Renci.SshNet.Common.SshOperationTimeoutException">Operation has timed out.</exception>
         public string Execute()

+ 2 - 3
Renci.SshClient/Renci.SshNet/SubsystemSession.cs

@@ -190,7 +190,7 @@ namespace Renci.SshNet.Sftp
         #region IDisposable Members
 
         private bool _isDisposed = false;
-
+        
         /// <summary>
         /// Performs application-defined tasks associated with freeing, releasing, or resetting unmanaged resources.
         /// </summary>
@@ -245,8 +245,7 @@ namespace Renci.SshNet.Sftp
         }
 
         /// <summary>
-        /// Releases unmanaged resources and performs other cleanup operations before the
-        /// <see cref="SftpSession"/> is reclaimed by garbage collection.
+        /// Finalizes an instance of the <see cref="SubsystemSession" /> class.
         /// </summary>
         ~SubsystemSession()
         {