[tech] Doppio: Gemini server in Java
- 📧 Messages: 3
- 🗣️ Authors: 2
- 📅 First Message: 2021-01-03 03:14
- 📅 Last Message: 2021-01-03 17:57
1. Bill Havanki (desu (a) deszaras.xyz)
- 📅 Sent: 2021-01-03 03:14
- 📧 Message 1 of 3
Greetings,
I?d like to announce my own take on a Gemini server implementation, which
I?ve named Doppio.
https://github.com/bhavanki/doppio/
I implemented it in Java as a fun side coding project, but I hope it?s
useful for others. It supports the usual good stuff:
* static files, including finding index files
* CGI with most meta-variables from RFC 3875, plus a bunch from Apache mod_ssl
* MIME type detection by file name suffix (.gmi or .gemini for text/gemini)
* access logging
* single server configuration file
It mostly passes gemini-diagnostics. :) There?s always more TLS work to do.
The server is licensed with AGPL 3.
Enjoy, and thanks!
Bill Havanki
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.orbitalfox.eu/archives/gemini/attachments/20210103/c609
206e/attachment.htm>
Link to individual message.
2. Sean Conner (sean (a) conman.org)
- 📅 Sent: 2021-01-03 03:43
- 📧 Message 2 of 3
It was thus said that the Great Bill Havanki once stated:
> Greetings,
>
> I?d like to announce my own take on a Gemini server implementation, which
> I?ve named Doppio.
>
> https://github.com/bhavanki/doppio/
Cool!
> I implemented it in Java as a fun side coding project, but I hope it?s
> useful for others. It supports the usual good stuff:
>
> * static files, including finding index files
> * CGI with most meta-variables from RFC 3875, plus a bunch from Apache
> mod_ssl
For CGI support, I set the REQUEST_METHOD to "" (since RFC-3875 madates
it---others have set it to "GET"), and instead of the Apache variables for
TLS, I used:
TLS_CIPHER
TLS_VERSION
TLS_CLIENT_HASH
TLS_CLIENT_ISSUER
TLS_CLIENT_SUBJECT
TLS_CLIENT_NOT_BEFORE
TLS_CLIENT_NOT_AFTER
TLS_CLIENT_REMAIN
and I think others that support CGI have done similar. I like that you used
"Certificate" for AUTH_TYPE (as I have done) and the subject name for
REMOTE_USER (as most others have done). I also added the following:
GEMINI_DOCUMENT_ROOT
GEMINI_SCRIPT_FILENAME
GEMINI_URL_PATH
GEMINI_URL
and again, some others support some of the above. Sadly, the CGI
discussions seem to die out quickly on this list.
Anyway, nice job.
-spc
Link to individual message.
3. Bill Havanki (desu (a) deszaras.xyz)
- 📅 Sent: 2021-01-03 17:57
- 📧 Message 3 of 3
Thank you kindly!
I went ahead and switched Doppio over to using the TLS_* meta-variables
that you listed. It makes sense to prioritize interop among Gemini servers
than between Gemini and Apache httpd. I did leave support for the mod_ssl
variables in there, but disabled by default. Maybe they?ll go away completely, some day.
I also tossed in TLS_CLIENT_VERSION, TLS_CLIENT_SERIAL, and TLS_SESSION_ID
for parity with what I?d already done with the mod_ssl stuff. They seem reasonable.
I?ll take a look at the GEMINI_* meta-variables next. They seem pretty straightforward.
Thanks for the feedback!
Bill
Link to individual message.
---
Previous Thread: [users] Lightweight markup language
Next Thread: [ANN] [Tech] Agunua, yet another Python library to develop Gemini clients