Hardcore Programming & Reference Books

Status
Not open for further replies.
Hi,

I am putting great effort into learning C++ and being able to solve problems using my own style. Nonetheless, I am nowhere at the level I feel is worth mentioning. I first began reading and practicing C++ two months go. I am moving at a satisfying rate (one chapter before Inheritance, Virtual Functions) and I have done close of all practice problems in Tony Gaddis' Starting out with C++ Alternate Second Edition.

I have two questions. My goal is to code an entire new and original Win32 FTP server. First, at what point *should* one begin laying the foundation for such a project?

Lastly, although I try again and again to take everything Gaddis' discusses and implement each element in every practice problem, I many times find myself having to go back to previous chapters to look up information. For the hardcore C++ programmer, do you use reference C++ books? How often?

Thanks,
Kuphryn
 

hanser

Ars Legatus Legionis
43,847
Subscriptor++
I have two questions. My goal is to code an entire new and original Win32 FTP server. First, at what point *should* one begin laying the foundation for such a project?

Think it through: as soon as you think you might know enough to start filling in pieces of the puzzle. Even if you can only think through certain parts of how the webserver will function, write them down.

(I'm thinking pre-pseudocode here)

Or maybe I just need sleep.


Probably the latter :oops:
 

earl

Well-known member
3,066
So, I feel obligated to point out that this might not be the best beginning project. This isn't necessarily meant to discourage you: it's just that writing an ftp server not only relies heavily on C++, but is going to hit the Win32 and Socket APIs pretty hard, as well. Thus leaving you with three things that you would simultaneously be learning, which is perhaps not the best thing. I guess my advice would be in general to only try and learn one thing at a time; otherwise, at least I tend to get too frustrated and give up.

Anyway, if you need help, I'm fairly versed in all three of the above. And if you're willing to have some hard going, please don't let the above discourage you.

-earl-
 

earl

Well-known member
3,066
Anyway, I occasionally use the Stroustrup book or my STL book as a quick reference / check. The STL is also well documented on SGI's site, although sometimes lacking in examples. It is pretty easy to use once you get started, though, because it tends to have a very uniform interface.

As for other books, I would pick up a reference on socket programming and perhaps something on the win32 threading / process / security APIs. Make sure that the socket reference deals with newer asynchronous/ overlapped / non-blocking /signal driven APIs.

-earl-
 

esposj

Ars Tribunus Militum
2,983
If it helps at my university (RPI) network programming is a 4000 CS class. One of the projects is a unix ftp server. We all had 3 years of programming classes, CS1,2,data structures,operating systems programming, other personal electives, etc...I don't know much about windows programming but Richards Book's Advanced Programming in the Unix Environment and Network Programming...were and are still great. I'm sure network programming would be helpful anyway.

Also read the RFCs!!!

if you want I could try and dig up some old tarballs, it's been over a year but there may be some laying around..

joe
 
Thanks everyone.

I know I am not ready. I want to get a clearer picture of my level relative to someone who put C++ to good use. According to the responses as well as my intuition, I *should* be ready to at least make a definite decision about the project in two year.

If everything goes as planned, and it should because C++ is my top priority and nothing is more important than thi goal, I will know the foundation of C++ including STL and abstract data in four to five months. So I have a long way to go. I am excited about C++ and I want to move as fast I my brain (and time) allows me to. I should finish Tony Gaddis' book in three weeks. I have no experience programming win32, so that is just another journey.

I have been wanting to asks for recommendation good reference books as well as something that would be a good continuation of Tony Gaddis' text, but I will hold back because I want to finish learning the materials in his text first. Once that happens, I will move onto a recommended text.

Thanks again.
Kuphryn
 
I have two questions. My goal is to code an entire new and original Win32 FTP server. First, at what point *should* one begin laying the foundation for such a project?
You'd better wait a while, or you'll likely find yourself restarting from scratch all the time as you learn new (better) design methods. If you don't mind that, go ahead whenever you feel ready.

For the hardcore C++ programmer, do you use reference C++ books? How often?
Depends what I work on. For day to day work at my current job (old code, pretty basic C++), I'd say about once every few months. When I write new code, I find myself consulting SGI's STL reference quite a bit (but less and less as time goes by). I'd say about once or twice a day when I'm writing some very STL stuff and lots of templates (but I rarely open a book).

it's just that writing an ftp server not only relies heavily on C++, but is going to hit the Win32 and Socket APIs pretty hard, as well.
Not to mention the FTP protocol! From the little I know about it, it's a beast in itself.
 

earl

Well-known member
3,066
See RFC 913: simple file transfer protocol
http://www.faqs.org/rfcs/rfc913.html

RFC 959: File Transfer Protocol (ftp)
http://www.w3.org/Protocols/rfc959/


And here is a fairly complete list of RFCs to read:

Code:
   Bhushan, Abhay, "A File Transfer Protocol", RFC 114 (NIC 5823),
   MIT-Project MAC, 16 April 1971.<P>   Harslem, Eric, and John Heafner, "Comments on RFC 114 (A File
   Transfer Protocol)", RFC 141 (NIC 6726), RAND, 29 April 1971.<P>   Bhushan, Abhay, et al, "The File Transfer Protocol", RFC 172
   (NIC 6794), MIT-Project MAC, 23 June 1971.<P>   Braden, Bob, "Comments on DTP and FTP Proposals", RFC 238 (NIC 7663),
   UCLA/CCN, 29 September 1971.<P>   Bhushan, Abhay, et al, "The File Transfer Protocol", RFC 265
   (NIC 7813), MIT-Project MAC, 17 November 1971.<P>   McKenzie, Alex, "A Suggested Addition to File Transfer Protocol",
   RFC 281 (NIC 8163), BBN, 8 December 1971.<P>   Bhushan, Abhay, "The Use of "Set Data Type" Transaction in File
   Transfer Protocol", RFC 294 (NIC 8304), MIT-Project MAC,
   25 January 1972.<P>   Bhushan, Abhay, "The File Transfer Protocol", RFC 354 (NIC 10596),
   MIT-Project MAC, 8 July 1972.<P>   Bhushan, Abhay, "Comments on the File Transfer Protocol (RFC 354)",
   RFC 385 (NIC 11357), MIT-Project MAC, 18 August 1972.<P>   Hicks, Greg, "User FTP Documentation", RFC 412 (NIC 12404), Utah,
   27 November 1972.<P>   Bhushan, Abhay, "File Transfer Protocol (FTP) Status and Further
   Comments", RFC 414 (NIC 12406), MIT-Project MAC, 20 November 1972.<P>   Braden, Bob, "Comments on File Transfer Protocol", RFC 430
   (NIC 13299), UCLA/CCN, 7 February 1973.<P>   Thomas, Bob, and Bob Clements, "FTP Server-Server Interaction",
   RFC 438 (NIC 13770), BBN, 15 January 1973.<P>   Braden, Bob, "Print Files in FTP", RFC 448 (NIC 13299), UCLA/CCN,
   27 February 1973.<P>   McKenzie, Alex, "File Transfer Protocol", RFC 454 (NIC 14333), BBN,
   16 February 1973.<P>   Bressler, Bob, and Bob Thomas, "Mail Retrieval via FTP", RFC 458
   (NIC 14378), BBN-NET and BBN-TENEX, 20 February 1973.<P>   Neigus, Nancy, "File Transfer Protocol", RFC 542 (NIC 17759), BBN,
   12 July 1973.<P>   Krilanovich, Mark, and George Gregg, "Comments on the File Transfer
   Protocol", RFC 607 (NIC 21255), UCSB, 7 January 1974.<P>   Pogran, Ken, and Nancy Neigus, "Response to RFC 607 - Comments on the
   File Transfer Protocol", RFC 614 (NIC 21530), BBN, 28 January 1974.<P>   Krilanovich, Mark, George Gregg, Wayne Hathaway, and Jim White,
   "Comments on the File Transfer Protocol", RFC 624 (NIC 22054), UCSB,
   Ames Research Center, SRI-ARC, 28 February 1974.<P>   Bhushan, Abhay, "FTP Comments and Response to RFC 430", RFC 463
   (NIC 14573), MIT-DMCG, 21 February 1973.<P>   Braden, Bob, "FTP Data Compression", RFC 468 (NIC 14742), UCLA/CCN,
   8 March 1973.<P>   Bhushan, Abhay, "FTP and Network Mail System", RFC 475 (NIC 14919),
   MIT-DMCG, 6 March 1973.<P>   Bressler, Bob, and Bob Thomas "FTP Server-Server Interaction - II",
   RFC 478 (NIC 14947), BBN-NET and BBN-TENEX, 26 March 1973.<P>   White, Jim, "Use of FTP by the NIC Journal", RFC 479 (NIC 14948),
   SRI-ARC, 8 March 1973.<P>   White, Jim, "Host-Dependent FTP Parameters", RFC 480 (NIC 14949),
   SRI-ARC, 8 March 1973.<P>   Padlipsky, Mike, "An FTP Command-Naming Problem", RFC 506
   (NIC 16157), MIT-Multics, 26 June 1973.<P>   Day, John, "Memo to FTP Group (Proposal for File Access Protocol)",
   RFC 520 (NIC 16819), Illinois, 25 June 1973.<P>   Merryman, Robert, "The UCSD-CC Server-FTP Facility", RFC 532
   (NIC 17451), UCSD-CC, 22 June 1973.<P>   Braden, Bob, "TENEX FTP Problem", RFC 571 (NIC 18974), UCLA/CCN,
   15 November 1973.<P>   McKenzie, Alex, and Jon Postel, "Telnet and FTP Implementation -
   Schedule Change", RFC 593 (NIC 20615), BBN and MITRE,
   29 November 1973.<P>   Sussman, Julie, "FTP Error Code Usage for More Reliable Mail
   Service", RFC 630 (NIC 30237), BBN, 10 April 1974.<P>   Postel, Jon, "Revised FTP Reply Codes", RFC 640 (NIC 30843),
   UCLA/NMC, 5 June 1974.<P>   Harvey, Brian, "Leaving Well Enough Alone", RFC 686 (NIC 32481),
   SU-AI, 10 May 1975.<P>   Harvey, Brian, "One More Try on the FTP", RFC 691 (NIC 32700), SU-AI,
   28 May 1975.<P>   Lieb, J., "CWD Command of FTP", RFC 697 (NIC 32963), 14 July 1975.<P>   Harrenstien, Ken, "FTP Extension: XSEN", RFC 737 (NIC 42217), SRI-KL,
   31 October 1977.<P>   Harrenstien, Ken, "FTP Extension: XRSQ/XRCP", RFC 743 (NIC 42758),
   SRI-KL, 30 December 1977.<P>   Lebling, P. David, "Survey of FTP Mail and MLFL", RFC 751, MIT,
   10 December 1978.<P>   Postel, Jon, "File Transfer Protocol Specification", RFC 765, ISI,
   June 1980.<P>   Mankins, David, Dan Franklin, and Buzz Owen, "Directory Oriented FTP
   Commands", RFC 776, BBN, December 1980.<P>   Padlipsky, Michael, "FTP Unique-Named Store Command", RFC 949, MITRE,
   July 1985.
 

OneFootsTheSame

Smack-Fu Master, in training
70
I use Stroustrup for general C++ stuff, but for Windows programming I found Richters "Advanced Windows" very useful for understanding how Windows/Win32 worked. You'll need to understand that suff to do serious Windows work. However, it's only thorugh NT4, and I'm not sure if there is a new (4th) edition out.

Otherwise, I'm a hands on guy ... Advanced Windows plus generating samples with Visual Studio and hacking them until I understood what was happening was the best eductaion I had. And

http://msdn.microsoft.com/

is your friend (even though it may not seem like it).

Good luck on the FTP server. Putting together a basically functional one might not be *too* hard, but as others have noted, correctly implementing the RFC is gonna be some serious work. I say dig into it though. Learn by doing. Just realize that while your first version(s) will be throw away, they won't be a waste.
 
Thanks for the information everyone.

I appreciate your encouraging words OneFootsTheSame.

There is no doubt win32 FTP server something I have always wanted to work on. I promise I will do everything in my power to make that happens. It will take time, but the time well worth it, not because of the end product, but because of the experience.

Thanks.
Kuphryn
 
Status
Not open for further replies.