A simple server to filter events from webcal feeds.
Usage of webcal-proxy:
- -addr string local address:port to bind to (default ":8080")
- -logfile string File to log to
- -log-level string log level (default "info")
- -max-conns maximum total upstream connections
- -dev disables security policies that prevent http://localhost from working
The server should be run behind a reverse proxy which terminates TLS because the webcal:// protocol requires valid TLS. The web interface will also not function on http without the -dev argument, even then some things will not work, such as clipboard interaction.
If the reverse proxy uses a path then provide it in the X-Forwarded-URI header. Example nginx config:
location /webcal-proxy/ {
proxy_pass http://127.0.0.1:8080;
rewrite ^/webcal-proxy/(.*)$ /$1 break;
proxy_set_header Host $host;
proxy_set_header X-Forwarded-URI /webcal-proxy;
proxy_set_header X-Forwarded-For $proxy_add_x_forwarded_for;
proxy_redirect off;
proxy_buffering off;
}This server should be isolated at a network-level from egress to your infrastructure's private network, otherwise an attacker may be able to gain access to private services.
This server's HTTP client which fetches requested calendars does reject connection attempts to non-unicast and private addresses, but not other public unicast address ranges (including RFC 6598) which cloud providers may re-purpose for private networks.
Enter the URL into your webcal client:
webcal://<this_server>/?cal=<webcal_url>[&inc=<query> ...][&exc=<query> ...][&mrg=true]
Where:
- this_server is the address and path hosting this program.
- cal your upstream webcal link, including the protocol scheme (webcal, http, https) (Required).
- inc query for events to include in the form
<FIELD>=<regexp>where FIELD is an iCal event field (egSUMMARY) and regexp is an unbound regular expression. Multiple inc arguments are allowed, (defaultSUMMARY=.*). - exc query for events to exclude in the form
<FIELD>=<regexp>where FIELD is an iCal event field (egSUMMARY) and regexp is an unbound regular expression. Multiple inc arguments are allowed. - mrg optional parameter to merge overlapping events into the one event.
eg:
webcal://webcal-proxy.example.com/webcal-proxy?cal=webcal://example.com/my/calendar&exc=SUMMARY=Boring%20Events