Install MGMT API
Install MGMT API
Installation Guide
Deploy & Install the Management API | Forcepoint Web Security | v8.5.x |8-June-2020
The Management API for Forcepoint Web Security is a REST interface using JSON.
It allows administrators to:
● Create custom, API-managed categories
● Add URLs and IP addresses to API-managed categories
● Remove URLs and IP addresses from API-managed categories
● Delete API-managed categories
● View categories, URLs, IP addresses, and API status
API-managed categories appear in category filters in the Forcepoint Security Manager
for both Super Administrators and delegated administrators. These categories are
added to the Security Risk class and blocked by default. This means that as new
threats are discovered by third-parties, they can quickly be added via the Management
API and blocked for all users.
The Management API is not installed via the Forcepoint Web Security installer.
Instead, administrators use a manual process to install and activate API components.
For deployment planning information and installation instructions, see:
● Preparing to deploy the Management API, page 1
● Installing the Management API on a Linux server, page 3
After you have completed the installation process, find instructions for using the API
in the Management API Guide.
Deploy & Install the Management API | Forcepoint Web Security | v8.5.x |8-June-2020
The Management API resides with Policy Server on a Linux server or Forcepoint
appliance.
● There can be multiple Management API instances in the deployment.
● There can be only one Management API per Policy Server instance.
● Only Policy Server instances that include a Management API instance can use
API-managed categories for policy enforcement.
Before installing the Management API on a Linux server, be sure that the
libgnutls.so.26 library is installed.
Warning
A key component of the Management API, Policy API
Server, will fail to install if this library is missing.
The Management API must be able to communicate with the following components:
● Policy Server provides connection information to allow Management API
components to communicate with other Forcepoint Web Security components.
The Management API and Policy Server must reside on the same machine.
● Policy Broker is used to record API-managed categories, URLs, and IP addresses
in the Policy Database. This allows URLs and IP addresses to be distributed
throughout the deployment.
Policy Broker communication occurs on port 55880.
● Filtering Service queries the Management API for category, URL, and IP address
information for use in policy enforcement.
■ Filtering Service communication occurs on port 17868.
■ Multiple Filtering Service instances can communicate with the same
Management API instance.
■ All Filtering Service instances that connect to the same Policy Server also
share the same Management API instance.
Client communication with the Management API uses port 15873, by default.
The primary component of the Management API is the Policy API Server.
● Policy API Server listens on port 15873, accepting REST requests via HTTPS
using basic authentication.
● API-managed categories and their URLs and IP addresses are stored both in the
Policy Database and a local database on the Policy API Server machine.
In deployments with multiple Policy API Server instances, changes saved by one
instance are replicated to the local databases for all other instances within a short
period.
■ Each Policy API Server instance keeps the most recent 3 good databases.
■ The database location can be configured in the ApiParameters.ini file (see
ApiParameters.ini.).
■ Any bad database is stored in a separate directory for troubleshooting by
Forcepoint Technical Support.
Management API components run using an account created automatically during the
installation process. This account is called forcepoint and has a password generated
dynamically at installation time. The account is used only for running daemons, and
cannot be used to log in to the server.
Note
If your deployment has multiple Filtering Service
instances per Policy Server, see this KBA for additional
configuration information.
Deploy & Install the Management API | Forcepoint Web Security | v8.5.x |8-June-2020
./PolicyApiServerAdmin.sh -i
Management API components are installed, a server certificate is generated, and
the services are started.
5. When the installation process is complete, use the following command to verify
system status:
./PolicyApiServerAdmin.sh --status
The command should return:
WsUrlQuery (pid xxxx) is running...
CatEngineMonitor.sh (pid xxxx) is running...
Policy API Server is running
6. Repeat this process for each Linux-based Policy Server instance.
As part of the installation process, a server certificate is created to enable HTTPS
communication with the Management API. If you need to update or replace the
default certificate for API instances on Linux servers, see Updating the HTTPS server
certificate, page 5.
To continue with the setup process, see Enabling communication between
Management API clients and servers, page 6.
When you deploy a Forcepoint appliance in full policy source or user directory and
filtering mode, the installation files for the Management API are added to the
appliance, but API components are not installed or activated.
These instructions demonstrate the installation commands using the command-line
tool curl. You may use another, similar tool if you prefer.
In the commands below:
● <c_interface> is the IP address of the appliance communication (C) interface.
● <password> is the admin password for the appliance command-line interface
(CLI).
To install the Management API on an appliance:
1. Use the following command:
curl -k -u admin:<password> -X PUT https://<c_interface>/
wse/admin/api/install
When the installation is complete, the command returns its results in JSON
format. In the Data field, look for the following strings:
WsUrlQuery (pid xxxx) is running
CatEngineMonitor.sh (pid xxxx) is running
Policy API Server is running
2. If any API components have failed to start, use the following commands to first
stop all API components, then start the components:
curl -k -u admin:<password> -X PUT https://<c_interface>/
wse/admin/api/stop
curl -k -u admin:<password> -X PUT https://<c_interface>/
wse/admin/api/start
3. To verify the status of Management API components at any time, use the
following command:
curl -k -u admin:<password> -X GET https://<c_interface>/
wse/admin/api/status
Before changing an appliance that hosts the Management API to filtering only mode,
see Changing the policy source mode of an appliance that hosts the Management API,
page 7.
Deploy & Install the Management API | Forcepoint Web Security | v8.5.x |8-June-2020
Activating the Management API requires a server SSL certificate. A script is included
with other API files to facilitate certificate deployment.
● The certificate expires every 5 years.
● The server certificate is different for each Policy API Server instance, because it is
tied to the IP address of the management API machine. As a result, you cannot
generate the certificate for one instance and then copy it to additional instances.
To replace or update the certificate on Linux servers:
1. Log in as root.
2. Navigate to the bin directory on the Management API machine.
cd /opt/Websense/bin
3. Open the ApiParameters.ini file in a text editor.
This file is used to configure how the server certificate is generated.
4. Use the RestServerCertPath parameter to specify where the generated certificate
files will be stored.
5. Use the RestServerCertRoot parameter to specify a name for the certificate file.
6. Use the RestServerCertKey parameter to specify the private key for the
certificate.
Important
The Security Manager does not display the option to create
an authentication account until the Management API is
installed.
The Management API can only run on appliances that host Policy Server. This means:
● Full policy source
● User directory and filtering
If you have installed the Management API on an appliance, but later need to redeploy
the appliances as a filtering only appliance, use the following procedure:
1. Identify which Policy Server instance the new filtering only appliance will use.
■ To continue using the Management API for this Policy Server, it must reside
on an appliance or Linux server.
■ If you plan to use a new instance of Policy Server, deploy the new instance
before changing the policy source mode on the appliance.
2. If you intend to continue using the Management API, make sure that it is installed
and running on the new Policy Server machine.
3. Uninstall the Management API from the appliance:
curl -k -u admin:<password> -X PUT https://<c_interface>/
wse/admin/api/uninstall
4. Change the appliance mode to filtering only.
©2020 Forcepoint. Forcepoint and the FORCEPOINT logo are trademarks of Forcepoint. All
other trademarks used in this document are the property of their respective owners.