- Access exclusive content
- Connect with peers
- Share your expertise
- Find support resources
07-19-2016 01:40 PM - edited 07-19-2016 01:51 PM
Hello all,
I'm attempting to block about 1340 TLDs with a URL filter. However, I can't seem to get the URL filter to not block any URL where the TLD string is part.
For example:
If I want to block the .able TLD, I block "*.able" via a URL Category that's linked to a URL filter that's linked to a profile on a policy.
I expect the following results:
What actually happens:
So, the wildcard "*.able" acts the same as a regex .*able.*
You might think that "*.able/" resolves this in this case:
I expect to happen:
What actually happens:
So, the wildcard "*.able/" acts the same as a regex .*[.]able$
The reason why I wish to block TLDs is simple:
I ran a regressive query against all URLs accessed by my company for three months (we are capturing traffic using Moloch "network VCR") and only about 50 TLDs are ever accessed. ICANNs total list of TLDs contains 1405 TLDs (https://www.icann.org/resources/pages/tlds-2012-02-25-en).
The only time I see hits against odd TLDs is in attack events. So, given that the cost-reward is so high, I wish to block TLDs.
This seems like an odd weakness to have in the URL filtering engine that could be resolved with a single line of code. So I'll hope and assume that I'm doing something wrong.
Is it possible to block TLDs?
SEs, please feel free to access case: 00515922
Thanks,
Matt
07-20-2016 01:08 AM
Hi Matt
the URL filtering manual entries are actually sort of regex rather than simple wildcards, so using .able would do the job
alternatively, if you create a custom threat signature, you can use more complex regex to match the TLDs
07-22-2016 05:12 AM
I have blocked ".able".
What I (and you (?)) expect to happen:
block: nic.able
not block: www.able.org/index.html or foo.docs.able.google.com or https://encrypted.google.com/search?hl=en_q=inurl:able
What actually happens:
block: nic.able
not block: www.able.org/index.html or foo.docs.able.google.com and https://encrypted.google.com/search?hl=en_q=inurl:able
However, if I also block ".google":
What I (and you (?)) expect to happen:
block: nic.google
not block: www.google.com/index.html or docs.google.com or https://encrypted.google.com/search?hl=en&q=inurl%3Agoogle
What actually happens:
block: nic.google and https://encrypted.google.com/search?hl=en&q=inurl%3Agoogle
not block: www.google.com/index.html or docs.google.com
So, although .able worked, the strategy in general doesn't work.
Any further assistance is appreciated.
Thanks,
Matt
07-22-2016 06:55 AM
I've been playing around with this internally for a while and found that while blocking .able or .google works better then doing a *.able it's far from a perfect solution. I've had more luck with creating a custom threat signature however, the time that is needed to create a custom threat signature and properly test it before actaully deploying it is a much longer process in general.
07-22-2016 07:04 AM
Thanks for the reply!
Do you have an example you're willing to share?
Thanks,
Matt
03-01-2018 11:23 PM
03-02-2018 03:37 AM
hi @jhopple
I went looking for that article as it is incorrect, I've updated it to reflect that actual situation (this was an article from 2009, apologies for the confusion)
custom URL entries match tokens, devided by separators
this entry in the admin guide describes it best: https://www.paloaltonetworks.com/documentation/80/pan-os/web-interface-help/objects/objects-security...
06-14-2018 02:35 AM
06-14-2018 04:13 AM
if not for the slash at the end of the string you would be right. the slash is a hard stop to the domain name and will only allow url path after that
*.com/
blocks www.mysite.com
allows www.mysite.com.uk
*.com
blocks www.mysite.com
blocks www.mysite.com.uk
i reproduced it real quick:
always trust @reaper 😉
I've pinged the admin guide team to check the wording
06-14-2018 08:18 AM
06-14-2018 10:39 AM
if you manage to get download.microsoft.com blocked by adding *.domain/ I will come over personally! 😉
but i reproduced it real quick for you:
Click Accept as Solution to acknowledge that the answer to your question has been provided.
The button appears next to the replies on topics you’ve started. The member who gave the solution and all future visitors to this topic will appreciate it!
These simple actions take just seconds of your time, but go a long way in showing appreciation for community members and the LIVEcommunity as a whole!
The LIVEcommunity thanks you for your participation!