Word boundary regex \b on squidGuard
-
I’m running pfSense with great squid and squidGuard packages. On squidGuard lies my problem as follows:
I have a blacklist of bad words that are blocked if they are used on any web search engine. Examples of those words are: anal, ass, bum bra, butt, cum, dick, lust, tit.On the other hand, normal words that contain any of these previous words as part of their structures are accordingly blocked. Examples of those good words are: analog, canal, analysis, asset, compass, album, brand, button, circumstance, dickson, illustrate, repetition.
My suggested solution is to use “word boundary \b” regex on those bad words. Hence, \banal\b, or \blust\b will block only anal or lust but not analysis or illustrate. Unfortunately this solution is not working on squidGuard. What is actually blocked is the expression itself, so \banal\b and \blust\b are blocked and anal or lust are passed!!
Can anyone help me with this issue? Appreciating your attention.
-
if this isn't working as yoiu expect than it probably is a "problem" of squidguard and not of the package or regex.
ask on the squidguard mailing list if this can be realized or not.perhaps dansguardia n can help you with that because it does not only check URLs but the content of the page. And you are able to block a page because of the count of specific words.
-
Well, back again to the same topic.. I had been trying to get to anyone from squidGuard people who may be able to help me, and eventually I received one email message that "word boundary \b" is working on squidGuard-1.5_b, and that was a month ago. I actually downloaded it from: http://www.squidguard.org/Downloads/Devel/squidGuard-1.5-beta.tar.gz and since I have been trying to compile it into .tbz package so as to be able to install it on pfSense box, with no success.
Can anyone help me with this request, in the hope that I may be able to utilize word boundary \b in my expressions?
Thanks in advance
-
You probably cannot compile things on pfsense because the dependencies are not installed because a firewall do not need to compile packages.
So you should compile this package on a freebsd 8.1 system (pfsense 2.0.x) or freebsd 8.3 (pfsense 2.1) and build there the .tbz.
I read here in the forum that it is possible to create/build .tbz packages on another system and then copy this to pfsense and install it but I do not know the command lines for that.I know that user marcelloc posted on some other threads how to do that because other users asked for that. Perhaps the forum search will give you some success.