No list or "OR" options in OpenBSD's HTTPD

Did you know OpenBSD httpd doesn't have a convenient way to give an action to a list of items? Here's what I mean:
location found "*.css"   { pass }
location found "*.js"   { pass }
etc.....

It wold be nice to specify a list of things I want to "pass". A way to say "this or this or this" so to speak. Like this:
location found "*.css" | "*.js" { pass }

Why isn't it an option? Well that is because the options for matching is either shell globbing rules or lua patterns. Both are very simple rulesets that don't have one to one mappings of tools that we have gotten used to in the modern tech world. There are ways of extending both of them, but I haven't looked into the practicality or feasabilty of it on OpenBSD.

 Think it's possible? Let me know!

Comments