I want to write a cocoa application that checks if my ftp server is still up and running. So far I learned that CFFTP could be used but this is not object oriented code so a no go for me. Also some people recommend ConnectionKit but that won't build on 10.7. So my idea was to use terminal commands in my application with the help of NSTask. The problem is: there are multiple commands that need to be executed, the first being ftp ftp.foobar.com. Then I need to check if the response is ok or not. After that I will have to put in my username and password and also evaluate that output of that.
Does anyone know how the entire ftp connection handshake can be accomplished in Objective C via NSTask?