Files
netch/Netch/Servers/SSH/SSHForm.cs
Hellojack 77e1d5a80c [Netch] Add SSH protocol support (#875)
* [Netch] Optimize code

* [Netch] Add SSH protocol support
2022-07-12 01:47:23 +08:00

19 lines
710 B
C#

using Netch.Forms;
namespace Netch.Servers;
[Fody.ConfigureAwait(true)]
public class SSHForm : ServerForm
{
public SSHForm(SSHServer? server = default)
{
server ??= new SSHServer();
Server = server;
CreateTextBox("User", "User", s => true, s => server.User = s, server.User);
CreateTextBox("Password", "Password", s => true, s => server.Password = s, server.Password);
CreateTextBox("PrivateKey", "Private Key", s => true, s => server.PrivateKey = s, server.PrivateKey);
CreateTextBox("PublicKey", "Public Key", s => true, s => server.PublicKey = s, server.PublicKey);
}
protected override string TypeName { get; } = "SSH";
}