-- Leo's gemini proxy

-- Connecting to ainent.xyz:1965...

-- Connected

-- Sending request

-- Meta line: 20 text/gemini; charset=utf-8; lang=en

smolver development log, part 7


Intro


This is the seventh in a planned series of posts (well, eighth if you count the announcement) where I'll share my experience writing smolver, my Gemini server software, written in Swift.


You can find the previous iterations below.


smolver Devlog


Betas 3, 4 & 5


What's changed?


Fix some SSL hangs that were previously requiring an application restart. For most cases, these are now handled gracefully, logging an error message instead of freezing.

Fix incorrect items in README

Clarify and expand content in README

Add optional configuration item for allowing capsule access via direct IP (gemini://1.2.3.4)

Add requied configuration item for allowing capsule access via intended domain only. This fixed an issue where you could send a request for an invalid domain to the server and it would not care or even notice.

Clarify and cleanup logging and error messages

Add more validation of the config file so that it works as documented

Allow IP logging configuration flag to be optional in some scenarios

More robust request validation and response codes and messages, as a result some odd or potentially malicious requests that would have been allowed before, are now detected and stopped

Schedule the next beta to consist solely of validating the production app as having fixed the SSL problems successfully

Add a backlog item to allow configuration of server maintenance mode, that way you can configure that instead of shutting the server app off, if you don't want content returned while still allowing the server to be accessible

Add backlog items for new ideas for static site generation


Thoughts


I glossed over some things here in the interest of time, but this provides a nice high level overview of the changes.


Getting very close to being ready for an official v1.0.0!


Overall, the total lines of code grew only a little bit this time. Running cloc on v0.2.0 returns:


cloc Sources
      12 text files.
      12 unique files.
       1 file ignored.

github.com/AlDanial/cloc v 1.92  T=0.12 s (101.4 files/s, 13437.6 lines/s)
-------------------------------------------------------------------------------
Language                     files          blank        comment           code
-------------------------------------------------------------------------------
Swift                           12            202            312           1076
-------------------------------------------------------------------------------
SUM:                            12            202            312           1076
-------------------------------------------------------------------------------

Running cloc on v0.5.0 returns


cloc Sources
      12 text files.
      12 unique files.
       1 file ignored.

github.com/AlDanial/cloc v 1.92  T=0.13 s (89.8 files/s, 12515.9 lines/s)
-------------------------------------------------------------------------------
Language                     files          blank        comment           code
-------------------------------------------------------------------------------
Swift                           12            215            311           1146
-------------------------------------------------------------------------------
SUM:                            12            215            311           1146
-------------------------------------------------------------------------------

These numbers do not include dependencies.


That is a growth of 70 lines.

-- Response ended

-- Page fetched on Tue May 21 09:13:20 2024