• Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 633
  • Last Modified:

ftp using boost regex


Need to ftp a file to directory.  It appears boost regex might be a good library to use to achieve the objective.   Need code that does just that.
0
forums_mp
Asked:
forums_mp
  • 3
  • 2
1 Solution
 
Infinity08Commented:
boost regex is a library that allows you to use regular expressions. So, I'm not sure how you got the idea you could do FTP with it.

Have a look at libcurl instead :

        http://curl.haxx.se/libcurl/

It has support for many (data) transfer protocols, including FTP.

Here's a simple example of how you would use it to upload a file over FTP :

        http://curl.haxx.se/libcurl/c/ftpupload.html
0
 
evilrixSenior Software Engineer (Avast)Commented:
0
 
forums_mpAuthor Commented:

Maybe i misunderstood the link
http://www.boost.org/doc/libs/1_39_0/libs/regex/doc/html/boost_regex/ref/regex_match.html

It's unclear to me how to change directory from the stack overflow example
0
Concerto Cloud for Software Providers & ISVs

Can Concerto Cloud Services help you focus on evolving your application offerings, while delivering the best cloud experience to your customers? From DevOps to revenue models and customer support, the answer is yes!

Learn how Concerto can help you.

 
Infinity08Commented:
>> Maybe i misunderstood the link

There is an example on that page that parses an FTP response by using regular expressions. However, to get that response, you need an implementation of the FTP protocol. libcurl provides an implementation of the FTP protocol, and it looks like boost asio also does (I've never used it for FTP though, so I can't vouch for it heh).
0
 
evilrixSenior Software Engineer (Avast)Commented:
>> I've never used it for FTP though, so I can't vouch for it heh
Personally, I'd use libcurl but I thought I'd try check that it wasn't just confusion over which boost library we were discussing.
0
 
evilrixSenior Software Engineer (Avast)Commented:
This question has been classified as abandoned and is closed as part of the Cleanup Program. See the recommendation for more details.
0

Featured Post

Free Tool: SSL Checker

Scans your site and returns information about your SSL implementation and certificate. Helpful for debugging and validating your SSL configuration.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

  • 3
  • 2
Tackle projects and never again get stuck behind a technical roadblock.
Join Now