It depends on whether your users need write access to their calendar.
I once wrote a simple (command-line) utility that exports a single (.ics) calendar file. If changed, it uploads the exported .ics file to a web server, where it can be picked up by calendar clients (e.g. Google Calendar, iCalendar, Sunbird, Outlook). Publishing for different users can easily be done by uploading the .ics file to a different folder for each user.
Next, I scheduled this utility to run regularly. Of course, you could have your Delphi service do this regularly.
Many calendar clients understand http://
URLs as well as webdav://
URLs. Authentication can be arranged by using one of the regular HTTP authentication schemes. Of course, you’ll want to use SSL to secure things.
The only limitation of this is approach is that the resulting calendar is, in effect, read-only.
If you wanted to provide write access, you’ll need a real webcal server. A real webcal implementation would mean supporting the webdav protocol (which itself is an extension of the HTTP protocol) on the server, and picking up the changes from your Delphi service. Either that, or writing a WebDav/CalDav server in Delphi (e.g. using the Indy TIdWebdav component by extending the TIdHTTPServer
component, since Indy doesn’t sport a TIdWebdavServer component).
You’d have to process all the webdav-specific commands yourself (using the OnCommandOther
event), according to the WebDAV specs. This question about writing a WebDAV server may provide some pointers...
Alternatively, you could use a 3rd-party webdav server, and pick up any changes from your Delphi service.