squid regex correct syntax help for refresh_patterns
-
Can someone help to confirm my understanding of the regex syntax
I think the -i is to ignore case but what about the 2nd line?
should it have a -i in front two?refresh_pattern -i \.avg.com\/.*\.(bin) 4320 100% 43200 reload-into-ims
In the above expression any domain with *.avg.com will be matched ignoring case
refresh_pattern -i ([^.]+.|)avg.com/.*\.(bin) 4320 100% 43200 reload-into-ims
in the above expression any domain in the form abc.avg.com or abc.xzy.avg.com will be matched ignoring case.
but in this example abc.xyz.123.avg.com would not be matched.so that would mean the first expression is the most versatile to use, correct?
--- update ---
managed to come across www.regextester.com and found the 2nd expression was the best, but is with bugs above.
it is correctly;refresh_pattern -i ([^.]+.|)avg\.com\/.*\.(bin)
this means many of the refresh patterns on the forum are not ideal too. i will post my final refresh list once i finish testing them all