|
|
|
@ -9,13 +9,41 @@ You start the server using: |
|
|
|
|
$ ./gosher [<PORT> [<GOPHERDIR>] |
|
|
|
|
|
|
|
|
|
If PORT is not specified, it will bind on port 70. If GOPHERDIR is not |
|
|
|
|
provided, it defaults to "./". |
|
|
|
|
provided, it defaults to "./". Before starting `gosher` you might need |
|
|
|
|
to modify the values of the variables `NETCAT` and `STYLE` in `gosher` |
|
|
|
|
(see "Which netca?" below). |
|
|
|
|
|
|
|
|
|
If the selector is a directory, `gosher` will look for a file named |
|
|
|
|
`gophermap` to render the submenu. If a `gophermap` does not exist, |
|
|
|
|
`gosher` looks for the index.gph gopherfile in the folder and, if it |
|
|
|
|
exists, renders it as a gophermap. |
|
|
|
|
|
|
|
|
|
## Which netcat? |
|
|
|
|
|
|
|
|
|
There are currently several different implementations of `netcat`, and |
|
|
|
|
each of them works in a slightly different way and/or offers a different |
|
|
|
|
set of options. For the sake of using `gosher`, the main issue is |
|
|
|
|
whether your `netcat` implementation does exit or not when its standard |
|
|
|
|
input gets closed. Notably, the original `netcat` implementation by |
|
|
|
|
hobbit@avian.org does **not** exit, while other common implementations |
|
|
|
|
(OpenBSD `netcat`, `ncat` from the nmap project, and GNU `netcat`). The |
|
|
|
|
current version of `gosher` can work with different implementations of |
|
|
|
|
`netcat`, provided that the variable `NETCAT` points to the `netcat` |
|
|
|
|
version you want to use, and that the variable `STYLE` in `gosher` is set |
|
|
|
|
correctly. Please check below what is the recommended combination for |
|
|
|
|
your version of `netcat`: |
|
|
|
|
|
|
|
|
|
+----------------+--------+ |
|
|
|
|
| netcat version | STYLE | |
|
|
|
|
+----------------+--------+ |
|
|
|
|
| traditional | 'fork' | |
|
|
|
|
+----------------+--------+ |
|
|
|
|
| OpenBSD | 'pipe' | |
|
|
|
|
+----------------+--------+ |
|
|
|
|
| ncat | 'pipe' | |
|
|
|
|
+----------------+--------+ |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
## Why `gosher`? |
|
|
|
|
|
|
|
|
|
Just for fun. There are only a few TCP/IP application protocols left |
|
|
|
|