Hi Jerry,
Not sure if it’s a ‘nice’ example, but it works for us. We had some trouble to get this going (we didn’t want/were able to buy the add-on Jim mentions) as we have no clue about incorporating SSL certificates on our HP-UX server. So in cooperation with the vendor, we finally managed to do this without certificates.
First you need to load the TclCurl package:
package require TclCurl
This code will take the listing of the root directory and redirect it into $filelist
set tmp_dir /upgdata; keylget uarg TMP_DIR tmp_dir
set filelist “${tmp_dir}/file_list_ftps.txt”
curl::transfer -url ftp://${ip_address}:${ip_port}/ -sslverifypeer 0 -userpwd ${user}:${pwd} -ftpssl all -sslverifyhost 0 -ftplistonly 1 -file $filelist
This code will get the file $inrec and save it to $out_dir/$inrec. After that the file $inrec will be deleted on the FTPS server.
set deletelist [list “dele ${inrec}”]
curl::transfer -url ftp://${ip_address}:${ip_port}/${inrec} -sslverifypeer 0 -userpwd ${user}:${pwd} -ftpssl all -sslverifyhost 0 -file ${out_dir}/${inrec} -postquote $deletelist
Of course these are just fragments of the complete code. I hope you can do something with this.
Zuyderland Medisch Centrum; Heerlen/Sittard; The Netherlands