hotlink_protection.exe: Site Content Protection from Hotlinking
The hotlink_protection
utility serves to configure protection from
hotlinking on domains.
Use this utility to do the following:
- Set up hotlinking protection on a domain.
- Retrieve the current configuration of domain hotlinking protection.
Location
%plesk_cli%
Usage
hotlink_protection command [parameter] [
<option 1> <param 1>[
<option n> <param n>]]
Example
The following command enables hotlinking protection on the domain example.com with the following parameters: protected content is image files with extensions JPG, JPEG, GIF, PNG, TIFF, exception is made only for domain jonny.blogs.sample.net:
plesk bin hotlink_protection --update example.com -enabled true -protected-extensions "jpg;jpeg;gif;png;tiff" -friendly-domains jonny.blogs.sample.net
Commands
Command | Parameter | Description | Example |
---|---|---|---|
--update or -u
|
<domain name> |
Changes hotlinking protection settings. |
To add to the protection list (already including JPG, GIF) file extension BMP for the domain example.com: plesk bin hotlink_protection --update example.com -protected-extensions bmp |
--info or -i
|
<domain name> |
Retrieves current hotlinking protection configuration. |
To retrieve information on the hotlinking protection settings for domain example.org: plesk bin hotlink_protection --info example.org |
--help or -h
|
Displays help on the utility usage. |
plesk bin hotlink_protection --help |
Options
Option | Parameter | Description | Example |
---|---|---|---|
-enabled |
true| false |
Enables/Disables hotlinking protection. |
To turn the hotlinking protection off on the domain example.com: plesk bin hotlink_protection --update example.com -enabled false |
-protected-extensions |
"<ext1>;<ext2>;<...>;<ext n>" |
Defines the protected file extensions. |
To add to the protection list (already including JPG, GIF) file extension BMP for the domain example.com: plesk bin hotlink_protection --update example.com -protected-extensions bmp |
-friendly-domains |
<domain1>;<domain2>;<...>;<domainn> |
Defines friendly domains, which are allowed to hotlink the files. |
To allow users of blogger.com hotlink files hosted on domain example.com: plesk bin hotlink_protection --update example.com -friendly-domains blogger.com |