Class SftpEndpointOptions

Namespace: redb.Route.Sftp
Assembly: redb.Route.Sftp.dll

Endpoint options for SFTP transport. All properties are auto-bound from URI query parameters.

URI format: sftp:///remote/path?host=server&port=22&username=admin&password=secret&...


Inherits shared polling, post-processing, idempotency, and producer options from
. Adds SFTP-specific: SSH authentication,
proxy tunneling, chmod, flatten, jail, and more.

public class SftpEndpointOptions : RemoteFileEndpointOptions

Inheritance

Inherited Members

EndpointOptions.BindableOptions(Type),EndpointOptions.BindFromUri(IReadOnlyDictionary<string, string>),EndpointOptions.IsLenient(Type),EndpointOptions.OptionValueHint(string),EndpointOptions.ResolveOption(string?, IExchange),EndpointOptions.RoleOf(PropertyInfo),EndpointOptions.UnknownParameterHint(string),EndpointOptions.UnmappedParameters,EndpointOptions.Validate(),EndpointOptions.WrittenBesideConnectionFactory(Type, EndpointUri),EndpointOptions.WrittenForOtherRole(Type, EndpointUri, EndpointRole),GenericFileEndpointOptions.AllowNullBody,GenericFileEndpointOptions.AntExclude,GenericFileEndpointOptions.AntFilterCaseSensitive,GenericFileEndpointOptions.AntInclude,GenericFileEndpointOptions.AppendChars,GenericFileEndpointOptions.AutoCreate,GenericFileEndpointOptions.BackoffErrorThreshold,GenericFileEndpointOptions.BackoffIdleThreshold,GenericFileEndpointOptions.BackoffMultiplier,GenericFileEndpointOptions.BackoffOnFailedExchanges,GenericFileEndpointOptions.Charset,GenericFileEndpointOptions.Delay,GenericFileEndpointOptions.Delete,GenericFileEndpointOptions.DoneFileName,GenericFileEndpointOptions.EagerDeleteTargetFile,GenericFileEndpointOptions.Exclude,GenericFileEndpointOptions.FileExist,GenericFileEndpointOptions.FileName,GenericFileEndpointOptions.Filter,GenericFileEndpointOptions.FilterDirectory,GenericFileEndpointOptions.FilterFile,GenericFileEndpointOptions.FilterInstance,GenericFileEndpointOptions.Idempotent,GenericFileEndpointOptions.IdempotentKey,GenericFileEndpointOptions.Include,GenericFileEndpointOptions.InitialDelay,GenericFileEndpointOptions.MaxDepth,GenericFileEndpointOptions.MaxMessagesPerPoll,GenericFileEndpointOptions.MinAge,GenericFileEndpointOptions.MinDepth,GenericFileEndpointOptions.MoveExisting,GenericFileEndpointOptions.MoveTo,GenericFileEndpointOptions.Noop,GenericFileEndpointOptions.PreMove,GenericFileEndpointOptions.Recursive,GenericFileEndpointOptions.SortBy,GenericFileEndpointOptions.StreamBody,GenericFileEndpointOptions.TempFileName,GenericFileEndpointOptions.TempPrefix,GenericFileEndpointOptions.ValidateCommon(),RemoteFileEndpointOptions.ConnectionFactory,RemoteFileEndpointOptions.ConnectionTimeout,RemoteFileEndpointOptions.Disconnect,RemoteFileEndpointOptions.Host,RemoteFileEndpointOptions.MaxAge,RemoteFileEndpointOptions.MaximumReconnectAttempts,RemoteFileEndpointOptions.MoveFailed,RemoteFileEndpointOptions.OperationTimeout,RemoteFileEndpointOptions.Password,RemoteFileEndpointOptions.Port,RemoteFileEndpointOptions.ReconnectDelay,RemoteFileEndpointOptions.SendEmptyMessageWhenIdle,RemoteFileEndpointOptions.StartingDirectoryMustExist,RemoteFileEndpointOptions.Username,RemoteFileEndpointOptions.ValidateRemote()

Properties

BufferSize

SSH.NET internal buffer size in bytes. (default: 32768 = 32 KB)

public int BufferSize { get; set; }

Chmod

Set POSIX file permissions after upload (octal string, e.g. "0644").

public string Chmod { get; set; }

ChmodDirectory

Set POSIX permissions on auto-created directories (octal string, e.g. "0755").

public string ChmodDirectory { get; set; }

Compression

Enable zlib compression on the SSH channel. (default: false)

public bool Compression { get; set; }

DirectoryMustExist

If true, each subdirectory must exist when using recursive mode.

public bool DirectoryMustExist { get; set; }

Flatten

If true, flatten nested directory structures — all files are uploaded to the base directory.

public bool Flatten { get; set; }

IgnoreFileNotFoundOrPermissionError

If true, silently ignore FileNotFoundException or permission errors during listing.

public bool IgnoreFileNotFoundOrPermissionError { get; set; }

JailStartingDirectory

If true, prevent the producer from writing outside the base directory.

public bool JailStartingDirectory { get; set; }

KeepAliveInterval

SSH keep-alive interval in milliseconds. 0 = disabled.

public int KeepAliveInterval { get; set; }

KeepLastModified

If true, preserve the CamelFileLastModified header as the remote file's modification time.

public bool KeepLastModified { get; set; }

KnownHostsFile

Path to a known_hosts file (OpenSSH format) for host key verification.

public string KnownHostsFile { get; set; }

MoveExistingFileStrategy

Strategy for moving existing files when FileExist=Move. (default: Timestamp)

public SftpMoveExistingStrategy MoveExistingFileStrategy { get; set; }

Port

SFTP server port. (default: 22)

public override int Port { get; set; }

PreferredAuthentications

Preferred authentication order. Comma-separated: "publickey,password,keyboard-interactive".

public string PreferredAuthentications { get; set; }

PrivateKeyPassphrase

Passphrase for the encrypted private key (if applicable).

public string PrivateKeyPassphrase { get; set; }

PrivateKeyPath

Path to a PEM/OpenSSH private key file for public-key authentication.

public string PrivateKeyPath { get; set; }

ProxyHost

Proxy hostname or IP.

public string ProxyHost { get; set; }

ProxyPassword

Proxy password.

public string ProxyPassword { get; set; }

ProxyPort

Proxy port. (default: 1080)

public int ProxyPort { get; set; }

ProxyType

Proxy type for tunneling the SSH connection. (default: None)

public SftpProxyType ProxyType { get; set; }

ProxyUsername

Proxy username (for SOCKS5 or HTTP proxy auth).

public string ProxyUsername { get; set; }

Separator

Input normalization for remote paths: Auto (default) converts backslashes in configured

public SftpSeparator Separator { get; set; }

ServerFingerprint

Expected server host key fingerprint (MD5 hex, colon-separated, e.g. "AA:BB:CC:...").

public string ServerFingerprint { get; set; }

StrictHostKeyChecking

If true, validate the server's host key against .

public bool StrictHostKeyChecking { get; set; }

UseKeyboardInteractive

Enable keyboard-interactive authentication in addition to password/key.

public bool UseKeyboardInteractive { get; set; }

Methods

Validate()

Validates required parameters and constraints. Called after BindFromUri.

public override void Validate()

Constructors

SftpEndpointOptions()

Creates SFTP endpoint options with protocol-specific defaults.