Re: Bypass root folder and directly cd to an ftp location
Dan Fandrich via curl-library <[email protected]> Mon, 13 Oct 2025 10:24:42 -0700
| Newsgroups | gmane.comp.web.curl.library |
|---|---|
| Message-ID | <[email protected]> |
On Mon, Oct 13, 2025 at 04:17:42PM +0000, Nimit Dhulekar via curl-library wrote: > We're running into an issue when using libcurl (and curl). If the root folder > of an FTP server denies access for security reasons and we want to directly > connect to a different folder, this fails with a 550 Permission Denied. This is > happening because curl is still making an initial connection to "/", and then > calls cd to change to the requested folder. I'm not seeing any CWD / with a plain "curl -v ftp://site/some/path" call using the current git code. Perhaps this has something to do with other options your code is setting. Try setting CURLOPT_FTP_FILEMETHOD to CURLFTPMETHOD_SINGLECWD or even CURLFTPMETHOD_NOCWD and see if that helps. Dan -- Unsubscribe: https://lists.haxx.se/mailman/listinfo/curl-library Etiquette: https://curl.se/mail/etiquette.html