Generates an SSH private key using the specified algorithm and key size.

Namespace:  Rebex.Net
Assembly:  Rebex.Networking (in Rebex.Networking.dll)

Syntax

Visual Basic
Public Shared Function Generate ( _
	algorithm As SshHostKeyAlgorithm, _
	keySize As Integer _
) As SshPrivateKey
C#
public static SshPrivateKey Generate(
	SshHostKeyAlgorithm algorithm,
	int keySize
)

Parameters

algorithm
Type: Rebex.Net..::..SshHostKeyAlgorithm
Key algorithm.
keySize
Type: System..::..Int32
Key size. Specify 0 to use default key size.

Return Value

SSH private key object.

Version Information

.NET Compact Framework

Supported in: 3.9, 3.5

See Also