From: Job Snijders Subject: Re: httpd: add cache controls for static files To: tech@openbsd.org Date: Wed, 13 May 2026 14:26:01 +0000 On Sun, May 10, 2026 at 01:39:20PM +0200, Kirill A. Korinsky wrote: > +cache : NO CACHE { > + srv_conf->flags &= ~SRVFLAG_CACHE; > + srv_conf->flags |= SRVFLAG_NO_CACHE; > + } > + | CACHE { > + srv_conf->flags &= ~SRVFLAG_NO_CACHE; > + srv_conf->flags |= SRVFLAG_CACHE; > + } > + ; > + Perhaps "[no] cache-control no-cache" ? This way we can add more directives in the future, and also allow location specific configuration. E.g., server "example.com" { listen on * port 80 gzip-static no cache-control no-cache location "/hotstuff/*" { cache-control no-cache } } alternative approach would be to provide some generic mechanism to set HTTP headers (send-header?), then operators can just do whatever they need to do without patching httpd? server "example.com" { listen on * port 80 gzip-static location "/hotstuff/*" { send-header "Cache-Control: no-cache" } }