Blob


1 => contrib.gmi contrib
2 => /gmid.1.txt docs
4 # gmid
6 > A Gemini server
8 ## Features
10 * sandboxed by default on OpenBSD, FreeBSD and Linux
11 * able to reload the configuration on-the-fly without loosing connections
12 * punycode and IRI support
13 * CGI and FastCGI support
14 * virtual hosts and per-location rules
15 * low memory footprint
16 * event-based asynchronous I/O model
17 * rich configuration file
19 => gmid.1.txt Read the manpage.
21 ## Install
23 Some distros provide a package — thanks to the maintainers!
25 => https://repology.org/project/gmid/versions [https] Repology: packaging status for gmid
27 Source code and precompiled binaries for linux are available:
29 => https://github.com/omar-polo/gmid/releases/download/1.7.4/gmid-1.7.4.tar.gz gmid-1.7.4.tar.gz
31 => https://git.omarpolo.com/gmid/ git repository
32 => gemini://git.omarpolo.com/gmid.git/ git repository via Gemini
33 => https://github.com/omar-polo/gmid GitHub mirror
35 => https://github.com/omar-polo/gmid/releases/download/1.7.4/gmid.linux.aarch64 gmid.linux.aarch64
36 => https://github.com/omar-polo/gmid/releases/download/1.7.4/gmid.linux.amd64 gmid.linux.amd64
38 When in doubt, compile from source: it’s easy and takes less than a minute on a raspberry pi 3. The dependencies are:
40 * libevent
41 * OpenSSL/LibreSSL
42 * libtls (from either LibreSSL or LibreTLS)
43 * yacc or GNU bison
45 Once all the dependencies are installed, building is as easy as:
47 ```Example of how to compile from source
48 $ curl -LO https://github.com/omar-polo/gmid/releases/download/1.7.4/gmid-1.7.4.tar.gz
49 $ tar xzvf gmid-1.7.4.tar.gz
50 $ cd gmid-1.7.4
51 $ ./configure
52 $ make
53 $ sudo make install # eventually
54 ```
56 A SHA256 file is available. However, that only checks for accidental corruption: you can use signify (SHA256.sig and the public key gmid-1.7.pub) or GPG. The hash of the signify public key is also included in the SHA256 file and thus signed with my GPG. The signify public key for the next release ‘gmid-1.8.pub’ is also included.
58 => https://github.com/omar-polo/gmid/releases/download/1.7.4/SHA256 SHA256
59 => https://github.com/omar-polo/gmid/releases/download/1.7.4/SHA256 SHA256.gpg
60 => https://github.com/omar-polo/gmid/releases/download/1.7.4/SHA256.sig SHA256.sig
62 To verify the signatures with signify(1)
64 ```Example of how to verify the signature with signify
65 $ signify -C -p gmid-1.7.pub -x SHA256.sig
66 Signature Verified
67 gmid-1.7.pub: OK
68 gmid-1.7.4.tar.gz: OK
69 gmid-1.8.pub: OK
70 gmid.linux.aarch64: OK
71 gmid.linux.amd64: OK
72 ```
74 ## Change log for the last versions
77 1.7.4 “Space-dye Vest” fourth bugfix release — Released September 24, 2021
79 This version incudes the following bugfix:
81 * fix a possible out-of-bound access when handling a request for a non-existent file in the root directory of a vhost that's matched by the cgi option
83 and the relative regression test.
88 1.7.3 “Space-dye Vest” third bugfix release — Released September 19, 2021
90 ### Improvements
92 * follows symlinks
93 * improved documentation and added key generation example (thanks! Anna)
95 ### Bugfix
97 * fix syslog logging on FreeBSD. Reported by Karl Jeacle, thanks!
98 * don't crash if ``-c'' is missing in configtest mode (-n). Reported by heph, thanks!
99 * allow fstat64 on linux (needed by glibc on aarch64). Reported by pine, thanks!
104 1.7.2 “Space-dye Vest” second bugfix release — Released July 19, 2021
106 This version incudes the following bugfix:
108 * an un-initialized field in the configless code path leads to a crash on the first request.
110 and the relative regression test.
114 1.7.1 “Space-dye Vest” bugfix release — Released July 11, 2021
116 This version includes two bugfixes:
117 * use ${MAKE} to recursively call make.
118 * fix the misleading example in the manpage: macros may not be reserved words
122 1.7 “Space-dye Vest” — Released July 10, 2021
124 Starting from this version gmid doesn't depend on lex anymore, but yacc is still needed.
126 ### New features
128 * initial fastcgi support! (it's still young!)
129 * added user-defined macros, either via ‘-Dname=val’ or directly in the configuration file.
130 * new ‘include’ keyword to load additional configuration files.
131 * new ‘env’ rule to define environment vars for CGI scripts.
132 * new ‘alias’ rule to define hostname aliases for a server.
133 * allow ‘root’ to be specified per-location block.
134 * pidfile support with the new ‘-P’ cli flag.
135 * define ‘TLS_VERSION’, ‘TLS_CIPHER’ and ‘TLS_CIPHER_STRENGTH’ for CGI scripts.
137 ### Improvements
139 * remove limits on the number of virtual hosts and location blocks that can be defined.
140 * print the datetime when logging to stderr.
141 * use ‘text/x-patch’ for ‘.patch’ and ‘.diff’ files.
142 * sort the auto index alphabetically.
143 * various improvements to the log management.
144 * drop the dependency on lex.
145 * added ‘--help’ as synonym of ‘-h’ and ‘-V’/‘--version‘ to print the version.
146 * c-like handling of strings in the configuration file: when two or more strings are next to each-others, are automatically joined into a single string. This is particularly useful with $-macros.
148 ### Bug fixes
150 * correctly handle CGI scripts that replies with the maxium header length allowed.
151 * fixed the static target.
152 * fixed recursive mkdirs for configless mode (i.e. create ‘~/.local/share/gmid’)
153 * logs sent to syslog now have proper priority (before every message ended up as LOG_CRIT). Found by Anna “CyberTailor”, thanks!
154 * ensure ‘%p’ (path) is always absolute in ‘block return’ rules.
155 * fix automatic certificate generation, it caused problems on some adroid devices. Found by Gnuserland, thanks!
156 * document the ‘log’ rule.
157 * the seccomp filter was reworked and now it's known to work properly on a vast range of architectures (to be more specific: all the architectures supported by alpine linux), see github issue #4. Prompted and tested by @begss, thanks!
158 * various improvements to the configure script, notified and fixed by Anna “CyberTailor”, thanks!
159 * added a timeout to the regression tests.
161 ### Breaking changes
163 * if duplicate rules are found in the configuration file, an error is now raised instead of silently using only the last value.
164 * (sort of) ‘gg’ moved to ‘regress’ as it's only used in the regression suite.
165 * (notice) the “mime "mime-type" "extension"” rule was deprecated and replaced by the new “map "mime-type" to-ext "extension"”. The ‘mime’ rule will be removed in a future version because its syntax is incompatible with the new string auto-concat mechanism.