Support Forum
The Forums are a place to find answers on a range of Fortinet products from peers and product experts.
willbase
New Contributor II

How to configure URL Filter to allow only specific domains

Hello,

 

We would like to allow only certain domains in the static URL filter.
Is the following the correct way to write it if the domain is an exact match and subdomains are not allowed?

 

example

I want to allow only 【example.com】,
If I do not want to allow the subdomain 【aaa.example.com】

when I select Regular Expression,

 

→ example \. com

 

Normally, when you select a simple URL filter, writing 【example.com】 is recognized to include subdomains.
The following web site was used as a reference.

 

https://community.fortinet.com/t5/FortiGate/Technical-Tip-URL-Filter-expressions-for-the-FortiGate/t...

 

FortiGate 

2 REPLIES 2
funkylicious
SuperUser
SuperUser

"jack of all trades, master of none"
hpenmetsa
Staff
Staff

Hello,

If you want to allow only example.com. Please use "www.example.com" in the static URl. This will allow only www.fortinet.com and the rest of the subdomains, such as aaa.example.com will be blocked. Please check link below for more info.
https://community.fortinet.com/t5/FortiGate/Technical-Tip-Using-a-static-URL-filter-feature-to-allow...

Thanks

Announcements
Check out our Community Chatter Blog! Click here to get involved
Labels
Top Kudoed Authors