httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Dean Gaudet <>
Subject Re: regex syntax
Date Thu, 26 Jun 1997 04:00:14 GMT
On Wed, 25 Jun 1997, Alexei Kosut wrote:
> Does anyone have any thoughts on the matter?

I've been trying to figure out how to implement the Alias regex thing
by using a Location that matches the regex... but I haven't been satisifed
with the syntax or the implications... i.e.

<Location ~ /foobar(.*)>
    Alias /path/to/$1

The ()-pairs set $-values for the entire block.  But this poses so many
problems it's not worth it (consider nested <> blocks, you quickly need
scoping, and you start down the road to a full language).

I really would like to have a more uniform syntax throughout the config.
We have a lot of "string match this" arguments which fall into these

- direct match (w/ or w/o case)
- regex match (w/ or w/o case)
- ?* wildcarding match
- "domain matches" i.e. matching *
- "ip matches" i.e. 204.62.130. (we should add CIDR notation, and bind &-netmask notation:

We could quite easily have an expression parser that understood each
of those, and spat out a match_t, which is then executed at run time
against the appropriate input.


View raw message