network-programmingcommand-prompttelnethttp-request

GET /HTTP/1.1 not working in command prompt. It's saying "Invalid command"?


Click here to see the image . I tried a lot of time doing this but can't get it.


Solution

  • You haven't made a connection to the host, which is, opera.com, in this case. So you're actually issuing the request which is, GET / HTTP/1.1, in this case to telnet and telnet has no idea what that means. So basically you're not talking to the server or host. If you look at the pic it clearly says that "Connection to host is lost", which is pretty obvious.