I’m trying to study for my Computer Science course and I need some help to understand this question.
Write a C++ client program where you:
1. Take in a URL from the user as a command line argument (e.g., https://www.microsoft.com/en-us/windows/features)
2. Make a TCP connection with the server that hosts the URL (e.g., microsoft.com
3. Issue a properly formatted HTTP GET request to the server. Find out how to do that from this source https://www.tutorialspoint.com/http/http_requests....
4. Receive the response, discard the HTTP header part, save the rest (i.e., the HTML content of the page) into disk.
5. To verify that you downloaded the file correctly, download the same page using the linux command wget and save that using another name. Now compare the 2 files (one downloaded using your program and the other downloaded using wget command) using diff command in linux. If there is no difference, you have done it right.