Class SshEndpointJumpHost
- Namespace
- SshSharp.Extensions.DependencyInjection
- Assembly
- SshSharp.Extensions.DependencyInjection.dll
A jump host (bastion) for JumpHosts: where it is, how to log in to it and how to verify its host key,
as ssh -J and ssh_config's ProxyJump reach a server through it. Mutable, so configuration can bind to it
(Ssh:Deploy:JumpHosts:0:Host). Each hop is offered only its own credentials: the endpoint's password and keys never reach a
jump host, and a jump host's never reach the endpoint.
public sealed class SshEndpointJumpHost
- Inheritance
-
SshEndpointJumpHost
- Inherited Members
Properties
- AcceptNewHostKeys
Accept and record the jump host's key when it is not in the known_hosts files yet (
StrictHostKeyChecking accept-new). A hop checked against the endpoint's files also follows the endpoint's AcceptNewHostKeys.
- Host
The jump host's name or address. Required. The first hop's is resolved locally (or by the endpoint's proxy), the others' by the hop before.
- HostKeyFingerprints
Trust only these host keys for the jump host: SHA-256 fingerprints or public key lines, as HostKeyFingerprints takes them. They replace known_hosts for this hop.
- KnownHostsFiles
The known_hosts files that hold the jump host's key. When neither these nor HostKeyFingerprints are set, the hop is checked against the endpoint's KnownHostsFiles (default
~/.ssh/known_hosts), as ssh checks a ProxyJump host against the same files; an endpoint that pins its own fingerprints needs the hop's set here instead.
- Password
A password for the jump host, tried after any keys. Bind it from a secret store.
- Port
The jump host's SSH port (default 22).
- PrivateKeyFiles
Private key files (OpenSSH, PEM or PuTTY format) to log in to the jump host with, tried in order.
- PrivateKeyPassphrase
The passphrase of encrypted PrivateKeyFiles.
- PrivateKeys
Private keys given as values for the jump host, as PrivateKeys are for the endpoint: offered after PrivateKeyFiles, checked when the settings are validated.
- UseAgent
Also offer the keys of the user's SSH agent to the jump host, after PrivateKeyFiles and PrivateKeys (see UseAgent for which agent). Off by default.
- UserName
The user to log in to the jump host as. Required: it is not taken from the endpoint, whose user is the destination's.