multi certificate with curl ftp ssl

"Nico" <[email protected]>
Newsgroups gmane.comp.web.curl.php
Message-ID <[email protected]>

> Hello,
> 
> i want to convert this function curl (work) :
> 
> curl --ftp-ssl --capath /home/data/ --cert /home//data/certif.cer 
            --cacert  /home/data/societe.cer
>       -u username:password ftp://ftpmachin.societe.net:21
> 
> in php curl (v 7.18)
> 
> $ch = curl_init();
> curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, FALSE);
> curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, FALSE);
> curl_setopt($ch, CURLOPT_USE_SSL, CURLUSESSL_ALL );
> curl_setopt($ch, CURLOPT_FTPSSLAUTH, CURLFTPAUTH_SSL );
>>
> curl_setopt($ch, CURLOPT_SSLCERT, $certificat_dir.'certif.cer' );
> curl_setopt($ch, CURLOPT_CAPATH,  $certificat_dir);
> curl_setopt($ch, CURLOPT_PORT, 21);
> curl_setopt($ch, CURLOPT_URL, 'ftp://ftpmachin.societe.net');
>>
> curl_setopt($ch, CURLOPT_USERPWD, "username:password");
> curl_setopt($ch, CURLOPT_FILE, $fp);
> curl_setopt($ch, CURLOPT_FTPASCII, false);
> $ret = curl_exec($ch);
> $info = curl_getinfo($ch);
> curl_close ($ch);
> 
> but my php code don't work, error 530 user login false.
> 
> i think the certificate are not be include correctly.
> 
> Do you have an idea to right code for include the two certificate .
> 
> thank you for help
> 
> Gemelos 
> 
_______________________________________________
http://cool.haxx.se/cgi-bin/mailman/listinfo/curl-and-php
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.