Results 1 to 4 of 4

Thread: ftp client server on unix?

  1. #1

    Cool ftp client server on unix?

    hey this time no hacking it's time for simple programming

    well in unix os we can easily make our socket and do various things through that socket echo and daytime applications are easy to find in any book on socket programming but ...
    apart from that i can use a socket for file transfer !
    well suppose i wanna make my own ftp client server application i have to make every function
    which is there in an ftp client server applicationlike....

    open pass user get mget
    lcd help remotehelp and so on

    right ...

    but the question is would my ftp client work properly with any server?
    if yes how if no why
    look the main question is if i send ftp server a string "help" would it show help?

    is it all a ftp client needs to do?
    and by the way why is it so difficult to read or write on sockets u simply make a socket client server pair give a condition in server program that if received line ==help then do this.......
    it looks to be a simple program but even this may give u a hard time..
    reason is simple client is sending string help but server is not receiving....lol
    why is that so only an expert can know and i am not an expert.

    i hope newbies will find useful and experts will reply to the questions.and
    i won't get banned

  2. #2
    Senior Member
    Join Date
    Nov 2001
    an ftp client is an ftp client they all follow the ftp protocol. In making an ftp client you dont have to make any of the functions you mentioned. all you have to do is pass the command to the server in the form of an ascii string.

    in other words if you pass the string 'help' to the server you get a help listing from the server no matter what os the server is running on. Why...because thats the protocol.

    as far as writing the server goes im not sure i understand what your saying. but linux is open source. just look at the scr of one of the ftp servers that have already been written to see whats required.

    nothing has changed as far as a simple ftp client goes since it began 30 plus years ago and the gui type clients do nothing more than pass the same old ascii strings as their predessors did.
    Bukhari:V3B48N826 “The Prophet said, ‘Isn’t the witness of a woman equal to half of that of a man?’ The women said, ‘Yes.’ He said, ‘This is because of the deficiency of a woman’s mind.’”

  3. #3
    Senior Member
    Join Date
    Jan 2003
    Hey Hey Ajit...
    something you might want to read if you are looking into making yourself an ftp client or server is reading the related RFC. This might give you a little more indepth look at how the file transfer protocol operates. You can find the RFC here

  4. #4
    Senior Member
    Join Date
    Jan 2002
    FTP is a particularly annoying protocol, and I'd suggest you avoid it - it will complicate things significantly.

    As you probably gather, if you've read the specs, FTP uses two sockets at once - one for control messages, the other for data. Worse still, the data connection is not always initiated by the client. Even worse still, the client sometimes sends its IP address to the server over the control connection.

    All of these things make it highly error prone to program, and incompatible with many modern network (i.e. NAT) - you really don't want to code it if at all possible

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts