Table of Contents

Property HostCanonicalizer

Namespace
SshSharp.Config
Assembly
SshSharp.dll

HostCanonicalizer

Looks up the canonical name for CanonicalizeHostname: receives the host and the CanonicalDomains and completes with the canonical name, or null when none is found. Null (the default) disables canonicalization, since resolving names is the caller's business (DNS, CanonicalizePermittedCNAMEs policy), unless UseDnsCanonicalizer turns on the built-in one; when set, it is used instead of that. Either way, CanonicalizeHostname yes or always reads the configuration a second time, as ssh does, found name or not. Asynchronous, so a config that needs it resolves with ResolveAsync(string, SshConfigResolveOptions?, CancellationToken).

public Func<string, IReadOnlyList<string>, CancellationToken, ValueTask<string?>>? HostCanonicalizer { get; init; }

Property Value

Func<string, IReadOnlyList<string>, CancellationToken, ValueTask<string>>