Fork 0

254 lines
5.2 KiB

.Dd April 13, 2020
.Nm gophernicus
.Nd A modern, full-featured and secure gopher server
.Op Fl h Ar hostname
.Op Fl p Ar port
.Op Fl r Ar port
.Op Fl t Ar type
.Op Fl g Ar mapfile
.Op Fl a Ar tagfile
.Op Fl c Ar dir
.Op Fl u Ar dir
.Op Fl l Ar file
.Op Fl w Ar width
.Op Fl o Ar charset
.Op Fl s Ar seconds
.Op Fl i Ar hits
.Op Fl k Ar KiB
.Op Fl e Ar ext Ns = Ns Ar type Oo Fl e Ar ext Ns = Ns Ar type Oc ...
.Op Fl R Ar old Ns = Ns Ar new Oo Fl R Ar old Ns = Ns Ar new Oc ...
.Op Fl D Ar text
.Op Fl L Ar text
.Op Fl U Ar paths
.Op Fl nv
.Op Fl nl
.Op Fl nh
.Op Fl nf
.Op Fl nd
.Op Fl nc
.Op Fl no
.Op Fl nq
.Op Fl ns
.Op Fl na
.Op Fl nt
.Op Fl nm
.Op Fl nr
.Op Fl np
.Op Fl nx
.Op Fl nu
.Op Fl nH
.Op Fl d
.Op Fl b
.Op Fl \&?
is a gopher server.
It serves almost compliant RFC 1436, with small changes to make it more
supports userdirs, executable gophermaps, CGI, and virtual hosting
.Pq in the limits of the RFC .
can log to
.Xr syslog 3
or per-server files in Apache format.
The options are as follows:
.Bl -tag -width Dssmacro=value
.It Fl h Ar hostname
Changes the server hostname shown on the output menu.
The default is the fully qualified domain name of the machine.
.It Fl p Ar port
Changes the server port shown on the output menu.
The default is 70.
.It Fl T Ar port
Changes the SSL/TLS port.
The default is 0 (disabled).
.It Fl r Ar directory
Set the document root of the server.
The default is
.Pa /var/gopher .
.It Fl t Ar type
Set the default gopher filetype.
The default is 0.
.It Fl g Ar mapfile
Set the gophermap file name.
The default is
.Pa gophermap .
.It Fl a Ar tagfile
Set the gophertag file name.
The default is
.Pa gophertag .
.It Fl c Ar directory
Set the CGI script directory, under the document root.
The default is
.Pa /cgi-bin/ .
.It Fl u Ar directory
Set the name of the personal gopherspace directory.
Each user can deploy a personal gopherspace by creating
.Ar directory
in their home directory.
The default is
.Pa public_gopher .
.It Fl l Ar file
Log to
.Ar file
in Apache-compatible combined format.
Disabled by default.
.It Fl w Ar width
Set default page width.
The default is 67.
.It Fl o Ar charset
Select the output charset.
It can be one of
.Ar UTF-8 ,
.Ar ISO-9959-1 .
The default is
.Ar UTF-8 .
.It Fl s Ar seconds
Session timeout in seconds.
The default is 1800.
.It Fl i Ar hits
Maximum hits until throttling.
The default is 4069.
.It Fl k Ar kilobytes
Maximum transfer size in KiB until throttling.
The default is 4194304 (4 GiB).
.It Fl f Ar directory
Set directory where output filters are found.
Disabled by default.
.It Fl e Ar ext Ns = Ns Ar type
Map file extension
.Ar ext
to gopher filetype
.Ar type .
.It Fl R Ar old Ns = Ns Ar new
Rewrite the start of a selector.
.It Fl D Ar description
Set server description to appear in
.Pa /caps.txt .
.Ar description
looks like a filename (starts with a /), use the contents of the file.
.It Fl L Ar location
Set server location to appear in
.Pa /caps.txt .
.Ar location
looks like a filename (starts with a /), use the contents of the file.
.It Fl A Ar email
Set the email of the administrator to appear in
.Pa /caps.txt .
.It Fl U Ar paths
Set a colon-separated list of extra
.Xr unveil 2
.Pq only for Ox .
.It Fl nv
Disable virtual hosting.
.It Fl nl
Disable parent directory links.
.It Fl nh
Disable menu header.
.It Fl nf
Disable menu footer.
.It Fl nd
Don't show date and size of files in menu.
.It Fl nc
Disable file content detection (similar to
.Xr magic 5 Ns ).
.It Fl no
Disable output charset conversion.
.It Fl nq
Disable HTTP-style query strings
.Ql ?foo=bar&baz=quux .
.It Fl ns
Disable logging to
.Xr syslog 3 .
.It Fl na
Disable autogenerated
.Pa /caps.txt .
.It Fl nt
.Pa /server-status .
.It Fl nm
Disable shared memory use (for debugging purposes).
.It Fl nr
Disable root user check (for debugging purposes).
By default,
will refuse to run as root.
.It Fl np
Disable HAProxy proxy protocol.
.It Fl nu
Disable personal gopherspaces.
.It Fl nx
Disable execution of gophermaps and scripts.
.It Fl nH
Disable HTTP response to HTTP GET and POST requests.
.It Fl d
Print debug output in
.Xr syslog 3
.Pa /server-status .
.Fl ns
.Xr syslog 3 )
is used this option has no effect.
.It Fl v
Display version information and build date.
.It Fl b
Display licensing information.
.It Fl \&?
Display help.
Default values may have been changed at compile time by
.Pa gophernicus.env .
mostly conforms to
.Lk https://tools.ietf.org/html/rfc1436 "RFC 1436"
.An -nosplit
.An Kim Holviala
wrote the original implementation (2009\(en2018).
.An fosslinux
.An hb9kns
are the current maintainers (2019\(en).
Code contributed by others.
Developers can be reached at
.Mt gophernicus.AT.gophernicus.DOT.org
Known bugs are listed as issues on
.Nm Ap s GitHub page:
.Lk https://github.com/gophernicus/gophernicus/issues
Please report any bug you might experience there as well.
Copyright \(co
.An Kim Holviala
Copyright \(co
.An gophernicus developers
Licensed to you under the terms of the BSD 2-clause license.
Please see
for the full terms of the license.