curl / Mailing Lists / curl-users / Single Mail
Buy commercial curl support from WolfSSL. We help you work out your issues, debug your libcurl applications, use the API, port to new platforms, add new features and more. With a team lead by the curl founder himself.

Re: What Am I Doing Wrong With cURL and SFTP?

From: Daniel Stenberg via curl-users <>
Date: Mon, 24 Aug 2020 09:52:32 +0200 (CEST)

On Mon, 24 Aug 2020, Michael Newman via curl-users wrote:

> pi_at_raspsky:~/webcam $ sftp
> Connected to
> sftp> put testxx.jpg
> Uploading testxx.jpg to /home3/mgnewman/testxx.jpg

The SFTP client puts that file in your home directory.

> $ curl -k -u mgnewman: --key ~/.ssh/id_rsa --pubkey ~/.ssh/
> s -T "testxx.jpg"

The SFTP URL here implies the root directory. If you want to put the file in
your home directory you need to specify that. Possibly by using the URL

  / | Commercial curl support up to 24x7 is available!
                   | Private help, bug fixes, support, ports, new features
Received on 2020-08-24