Header Map Question

Answered Question
Jun 24th, 2008
User Badges:
  • Gold, 750 points or more

Hi,


I have already the following header map which works fine:


match protocol http header Host header-value abc.def.example.com*


Now I need to match whether the subdomain "def" is present or not. So, would the following accomplish this:


match protocol http header Host header-value abc.*example.com*


thanks,

Andrew.


Correct Answer by Gilles Dufour about 9 years 4 weeks ago

Actually the first one is incorrect.

But it will work.


What you need is this


match protocol http header Host header-value abc\.(def\.)?example\.com


Press -v to insert the '?'


Gilles.

  • 1
  • 2
  • 3
  • 4
  • 5
Overall Rating: 5 (1 ratings)
Loading.
Correct Answer
Gilles Dufour Wed, 06/25/2008 - 04:53
User Badges:
  • Cisco Employee,

Actually the first one is incorrect.

But it will work.


What you need is this


match protocol http header Host header-value abc\.(def\.)?example\.com


Press -v to insert the '?'


Gilles.

andrew.burns Wed, 06/25/2008 - 06:47
User Badges:
  • Gold, 750 points or more

Thanks Gilles,


Some review of regular expressions might be in order ;-)

Actions

This Discussion