New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Can't make SFTP with proxy tunnel in HTTPS #4295
Comments
I cannot reproduce using plain curl from Debian:
|
Although I note now that I didn't use a HTTPS proxy, just a plain HTTP.... Does that make a difference to you @Koaxiel ? |
Exactly, the issue occurs only when I connect to the proxy via HTTPS. |
|
Reproduced with stunnel, a local HTTP proxy (on port 80) and a local SFTP server:
|
I am facing similar problem. Was there any resolution to this? |
This issue is still open because it has not been resolved, and in fact there hasn't even been a PR filed for it... |
Possibly naive observation: it looks like the problem here is that the socket passed to the SSH library with an HTTPS proxy is a TLS socket. There's code intended to override Lines 3019 to 3026 in 842f73d
Lines 3354 to 3402 in 842f73d
But that wouldn't take into account TLS on the underlying socket. The basic send/recv functions in libssh2, at least, expect to be able to just use send/recv in order to send/receive packets. In theory it seems like what we would have to do here is:
I did try doing that with very limited success, so I'm probably missing something here. |
I have an issue when I use
curl
to fetch some files with usingSFTP
protocol via the usage of aHTTP
proxy via https (when I use http I don't have this issue):The same but I connect to the proxy via http:
I haven't issue when I connect to the proxy via https and I replace
SFTP
byFTP
orFTPS
.curl/libcurl version
operating system
Arch Linux
The text was updated successfully, but these errors were encountered: