Permalink
Browse files

Merge pull request #2053 from chn42/master

Fix an issue with ssh -L forwarding (OpenSSL 6.7 onwards only supports ":" as separator to "-L")
  • Loading branch information...
dmoagx committed Jan 13, 2015
2 parents e9b8c38 + 4e3fc71 commit 36c6eeb3a2fd966a810b241eeaaf00ec45f419b4
Showing with 3 additions and 3 deletions.
  1. +3 −3 Source/SPSSHTunnel.m
@@ -373,10 +373,10 @@ - (void)launchTask:(id) dummy
[taskArguments addObject:sshHost];
}
if (useHostFallback) {
[taskArguments addObject:[NSString stringWithFormat:@"-L %ld/127.0.0.1/%ld", (long)localPort, (long)remotePort]];
[taskArguments addObject:[NSString stringWithFormat:@"-L %ld/%@/%ld", (long)localPortFallback, remoteHost, (long)remotePort]];
[taskArguments addObject:[NSString stringWithFormat:@"-L %ld:127.0.0.1:%ld", (long)localPort, (long)remotePort]];
[taskArguments addObject:[NSString stringWithFormat:@"-L %ld:%@:%ld", (long)localPortFallback, remoteHost, (long)remotePort]];
} else {
[taskArguments addObject:[NSString stringWithFormat:@"-L %ld/%@/%ld", (long)localPort, remoteHost, (long)remotePort]];
[taskArguments addObject:[NSString stringWithFormat:@"-L %ld:%@:%ld", (long)localPort, remoteHost, (long)remotePort]];
}
[task setArguments:taskArguments];

0 comments on commit 36c6eeb

Please sign in to comment.