You can configure a User-Agent blacklist or whitelist to authenticate and authorize visitors. This can restrict access to Dynamic Route for CDN (DCDN) resources and improve DCDN security. This topic describes how to configure a User-Agent blacklist or whitelist.
- User-Agent blacklist: The User-Agent fields on the blacklist cannot be used to access
If your User-Agent field is added to the blacklist, a request with the User-Agent field can still be sent to a DCDN node. However, the DCDN node will reject the request and return a 403 error. Requests that contain the blacklisted User-Agent fields are still recorded in DCDN logs.
- User-Agent whitelist: Only User-Agent fields on the whitelist can be used to access resources.
- Log on to the Dynamic Route for CDN console.
- In the left-side navigation pane, click Domain Names.
- On the Domain Names page, find the target domain name and click Configure.
- In the left-side navigation pane of the specified domain, click Access Control.
- Click the User-Agent Black/White list tab.
- On the User-Agent Black/White list tab, click Modifying the configuration.
- Configure a blacklist or whitelist as prompted.
Parameter Description TypeThe following two types are supported:
The User-Agent fields on the blacklist cannot be used to access the current accelerated domain.
Only User-Agent fields on the whitelist can be used to access the current accelerated domain.
The blacklist and whitelist are mutually exclusive. The most recent configuration takes effect.
Rules When you configure the User-Agent fields, separate multiple values with vertical bars (|). The User-Agent field can contain wildcards (*). Example: *curl*|*IE*|*chrome*|*firefox*
- Click OK.