FortiMail provides advanced, multi-layer protection against the full spectrum of email-borne threats
Article Id 196146
This article describes how to configure the FortiGuard URL filter.

For version 6.4.1 and 6.4.2.

From the version 6.4.1, FortiMail has feature of FortiGuard URL filter service which allows to choose the categories of URL in the email body which can be checked, rewrite, or block.
Then the filters can be used in the anti spam profiles.

To configure a URL category profile.

1) Go to Security -> URL Filter -> Category.
2) Select 'Create New'.
3) Enter a profile name.
4) Select the URL categories to check in the email body.
5) Select 'Create'.

URL types.

There are two types of URLs:
- Absolute URLs strictly follow the URL syntax and include the URL scheme names, such as 'http', 'https', and 'ftp'. For instance,
- Reference URLs do not contain the scheme names. For instance,

By default, FortiMail scans for absolute URLs.
Find below the CLI command to change the default setting.
# config antispam settings
    set uri-checking {aggressive | strict}
- aggressive: Choose this option to scan for both the absolute and reference URLs.
- strict: Choose this option to scan for absolute URLs only. Note that web sites without http', 'https' but starting with 'www' are also treated as absolute URLs. For instance,

How to configure the URL exempt list.
To exempt URLs from FortiGuard URL and web filter, add the URLs to the exempt list is possible.

To configure the URL exempt list.

1) Go to Security -> URL Filter -> Exempt.
2) Select 'New'.
3) Enter an exempt pattern. The pattern can use wildcards (default) or regular expressions.
4) Select 'Create'.

Related document.