sshtunnel: Use -i $IdentityFile instead of -o IdentityFile=$IdentityFile

This makes the sshtunnel compatible with Dropbear.

Signed-off-by: Sergey Ponomarev <stokito@gmail.com>
This commit is contained in:
Sergey Ponomarev 2023-06-03 13:23:35 +03:00 committed by Nuno Goncalves
parent 714c97b012
commit f14dae7bc9
1 changed files with 3 additions and 1 deletions

View File

@ -174,10 +174,12 @@ load_server() {
config_foreach validate_tunnelW_section "tunnelW" load_tunnelW
[ "$count" -eq 0 ] && { _err "tunnels to $server not started - no tunnels defined"; return 1; }
append_params CheckHostIP Compression CompressionLevel IdentityFile \
append_params CheckHostIP Compression CompressionLevel \
LogLevel PKCS11Provider ServerAliveCountMax ServerAliveInterval \
StrictHostKeyChecking TCPKeepAlive VerifyHostKeyDNS
# dropbear doesn't support -o IdentityFile so use -i instead
[ -n "$IdentityFile" ] && ARGS_options="$ARGS_options -i $IdentityFile"
ARGS="$ARGS_options -o ExitOnForwardFailure=yes -o BatchMode=yes -nN $ARGS_tunnels -p $port $user@$hostname"
procd_open_instance "$server"