mTCP DOS - NC documentation issue (design bug)? (Announce)
Just referenced the mTCP version of NC in this forum reply. To be honest I've been too busy with my own coding/away from the keyboard activities to test mTCP yet.
However I did note the following line in http://brutman.com/mTCP/nc.txt:
"(If you send "GET /" without the quotes and press Enter, you will get a web page back!)"
I don't know if this is the case with the mTCP version of NC but this is wrong you shouldn't get a webpage back on most servers if you do the above. This is an example of a correct basic GET request as per the RFC's:
"GET / HTTP/1.0[CRLF]" where [CRLF] = 0Ah,ODh
or
"GET / HTTP/1.1[LF]" where [CRLF] = 0Ah,ODh
The above should also be case sensitive.
However be aware that some servers are so badly coded (or on purpose) that even this basic test may not work, e.g. "GET / HTTP/1.1" will work but "GET / HTTP/1.0" will NOT work or the server may sit there waiting for a longer url to be requested etc.
Note: 0Ah can often be obtained by [CTRL]+[ENTER]. For anyone interesting in scripting reading this also note many DOS based editors allow you to insert control codes via [CTRL ^P] and followed by [CTRL whatever] where whatever is the appropriate combination required, e.g. [CTRL]+[P] then [CTRL]+[ENTER] or [CTRL]+[P] then [CTRL]+[B] to insert a bell. This is useful to know if for example you wish to feed a text file via redirection to something like netcat.
The vast majority of telnet based servers will tend to respond with a header if you just send a few CRLF or or if that fails a few lineFeeds (CTRL+[ENTER]) or Carriage Returns (ENTER)'s instead, it depends on the server and if the programmer has read the RFC's etc. In the case of HTTP servers, using sending a HEAD request instead of a GET request is also useful.
For anyone needing more info: http://www.google.com/search?q=http+get+telnet
[EDIT]Corrected a technical error that I made whilst quickly writing this reply.
Complete thread:
- mTCP DOS TCP/IP apps for small machines - mbbrutman, 21.01.2010, 18:06
![Open in board view [Board]](img/board_d.gif)
![Open in mix view [Mix]](img/mix_d.gif)
- mTCP DOS TCP/IP apps for small machines - Japheth, 22.01.2010, 09:47
- mTCP DOS TCP/IP apps for small machines - mbbrutman, 22.01.2010, 16:56
- mTCP DOS TCP/IP apps for small machines - mbbrutman, 07.02.2010, 16:35
- Forget the library .. time to open-source the code? - mbbrutman, 14.03.2010, 03:22
- Forget the library .. time to open-source the code? - Rugxulo, 14.03.2010, 03:56
- Forget the library .. time to open-source the code? - mbbrutman, 14.03.2010, 15:01
- mTCP new release 27/June/2010 - now ported to Open Watcom - Arjay, 27.06.2010, 22:27
- mTCP new release 27/June/2010 - now ported to Open Watcom - Rugxulo, 28.06.2010, 06:30
- mTCP new release 27/June/2010 - now ported to Open Watcom - DOS386, 28.06.2010, 12:05
- mTCP new release 27/June/2010 - now ported to Open Watcom - Arjay, 28.06.2010, 14:22
- mTCP new release 27/June/2010 - now ported to Open Watcom - mbbrutman, 01.07.2010, 07:08
- mTCP new release 27/June/2010 - now ported to Open Watcom - Laaca, 01.07.2010, 13:14
- mTCP new release 27/June/2010 - now ported to Open Watcom - mbbrutman, 01.07.2010, 16:06
- mTCP new release 27/June/2010 - now ported to Open Watcom - DOS386, 01.07.2010, 13:20
- mTCP new release 27/June/2010 - now ported to Open Watcom - mbbrutman, 01.07.2010, 16:03
- mTCP new release 27/June/2010 - now ported to Open Watcom - Laaca, 01.07.2010, 19:16
- mTCP new release 27/June/2010 - now ported to Open Watcom - mbbrutman, 03.07.2010, 16:04
- mTCP new release 27/June/2010 - now ported to Open Watcom - DOS386, 14.07.2010, 03:51
- mTCP new release 27/June/2010 - now ported to Open Watcom - Laaca, 01.07.2010, 19:16
- mTCP new release 27/June/2010 - now ported to Open Watcom - mbbrutman, 01.07.2010, 16:03
- mTCP new release 27/June/2010 - now ported to Open Watcom - Laaca, 01.07.2010, 13:14
- mTCP new release 27/June/2010 - now ported to Open Watcom - mbbrutman, 01.07.2010, 07:08
- mTCP new release 27/June/2010 - now ported to Open Watcom - Arjay, 28.06.2010, 14:22
- mTCP new release 27/June/2010 - now ported to Open Watcom - DOS386, 28.06.2010, 12:05
- mTCP new release 27/June/2010 - now ported to Open Watcom - Rugxulo, 28.06.2010, 06:30
- mTCP new release 27/June/2010 - now ported to Open Watcom - Arjay, 27.06.2010, 22:27
- Forget the library .. time to open-source the code? - mbbrutman, 14.03.2010, 15:01
- Forget the library .. time to open-source the code? - Rugxulo, 14.03.2010, 03:56
- mTCP DOS TCP/IP apps for small machines - mbbrutman, 22.01.2010, 16:56
- mTCP interfacing with TINY remote control for DOS? - Arjay, 20.07.2010, 12:41
- mTCP interfacing with TINY remote control for DOS? - mbbrutman, 20.07.2010, 16:09
- mTCP interfacing with TINY remote control for DOS? - Arjay, 20.07.2010, 17:49
- mTCP interfacing with TINY remote control for DOS? - mbbrutman, 20.07.2010, 16:09
- mTCP DOS - NC documentation issue (design bug)? - Arjay, 20.07.2010, 14:07
- mTCP DOS - NC documentation issue (design bug)? - mbbrutman, 20.07.2010, 15:22
- mTCP DOS - NC documentation issue (design bug)? - Arjay, 20.07.2010, 17:30
- mTCP DOS - NC documentation issue (design bug)? - mbbrutman, 20.07.2010, 19:32
- mTCP DOS - NC documentation issue (design bug)? - Arjay, 20.07.2010, 21:56
- FTP ASCII vs binary "image" - DOS386, 23.07.2010, 07:27
- FTP ASCII vs binary "image" - mbbrutman, 24.07.2010, 01:04
- FTP ASCII vs binary "image" - DOS386, 24.07.2010, 12:12
- FTP ASCII vs binary "image" - Japheth, 24.07.2010, 15:31
- FTP ASCII vs binary "image" - DOS386, 24.07.2010, 15:36
- FTP ASCII vs binary "image" - mbbrutman, 24.07.2010, 16:23
- FTP ASCII vs binary "image" - Japheth, 24.07.2010, 16:57
- FTP ASCII vs binary "image" - mbbrutman, 25.07.2010, 01:35
- FTP ASCII vs binary "image" - Rugxulo, 25.07.2010, 05:34
- FTP ASCII vs binary "image" - DOS386, 25.07.2010, 06:16
- FTP ASCII vs binary "image" - mbbrutman, 25.07.2010, 17:17
- FTP ASCII vs binary "image" | NTLFN issues - DOS386, 26.07.2010, 02:03
- FTP ASCII vs binary "image" | NTLFN issues - mbbrutman, 26.07.2010, 03:11
- FTP ASCII vs binary "image" | NTLFN issues - DOS386, 27.07.2010, 02:53
- FTP ASCII vs binary "image" | NTLFN issues - mbbrutman, 27.07.2010, 03:31
- FTP ASCII vs binary "image" | NTLFN issues - DOS386, 27.07.2010, 03:40
- FTP ASCII vs binary "image" | NTLFN issues - mbbrutman, 27.07.2010, 03:31
- FTP ASCII vs binary "image" | NTLFN issues - DOS386, 27.07.2010, 02:53
- FTP ASCII vs binary "image" | NTLFN issues - mbbrutman, 26.07.2010, 03:11
- FTP ASCII vs binary "image" | NTLFN issues - DOS386, 26.07.2010, 02:03
- FTP ASCII vs binary "image" - mbbrutman, 25.07.2010, 17:17
- FTP ASCII vs binary "image" - DOS386, 25.07.2010, 06:16
- FTP ASCII vs binary "image" - Rugxulo, 25.07.2010, 05:34
- FTP ASCII vs binary "image" - mbbrutman, 25.07.2010, 01:35
- FTP ASCII vs binary "image" - Japheth, 24.07.2010, 16:57
- FTP ASCII vs binary "image" - Japheth, 24.07.2010, 15:31
- FTP ASCII vs binary "image" - DOS386, 24.07.2010, 12:12
- FTP ASCII vs binary "image" - mbbrutman, 24.07.2010, 01:04
- mTCP DOS - NC documentation issue (design bug)? - mbbrutman, 20.07.2010, 19:32
- mTCP DOS - NC documentation issue (design bug)? - Arjay, 20.07.2010, 17:30
- mTCP DOS - NC documentation issue (design bug)? - mbbrutman, 20.07.2010, 15:22
- mTCP DOS TCP/IP apps for small machines - Japheth, 22.01.2010, 09:47
Mix view