In this article:

Setting Up Interaction between System Configuration Elements via the HTTPS Protocol in Linux OS

Setting Up Interaction between Browser and Web Application Back End via the HTTPS Protocol

Step 1. Placement and Installation of Security Certificates

Step 2. Import of Root Certificate to Store

Step 3. Setting Up Web Application Back End

Step 4. Opening Web Application via the HTTPS Protocol

Setting Up Web Application Work via HTTPS

Hypertext Transfer Protocol Secure (HTTPS) is an extended version of the Hypertext Transfer Protocol (HTTP) that uses encryption using the Transport Layer Security (TLS) protocol. The TLS protocol is cryptographic and and is used to create a protected communication channel between computers in the network. Cryptographic methods ensure confidentiality and integrity of transferred data, single-factor or two-factor authentication.

Security certificates are used to ensure trust between the server and the client interacting via the HTTPS protocol. Security certificates include a set of information about the certificate owner, the certificate owner's public key, the subject that issued and signed the certificate, and information for certificate validation.

The following security certificate types are required to ensure interaction between the server and the client via the HTTPS protocol:

Foresight Analytics Platform supports web application work via the HTTPS protocol using GOST encryption algorithms. The GOST encryption requires the use of the means of cryptographic information protection: CryptoPro CSP, ViPNet CSP, Crypto-COM, MagPro CryptoPacket, and so on. The means of cryptographic information protection must be compatible with the operation environment of Foresight Analytics Platform and installed both in web application back end and on a client computer. The means of cryptographic information protection are not included in the software package of Foresight Analytics Platform. Web application work setup via the HTTPS protocol using GOST encryption algorithms is executed according to the documentation for corresponding means of cryptographic information protection.

For details about web application work in the Chromium-Gost browser, see the Setting Up Web Application Work in Chromium-Gost Browser in Linux OS section.

Set up one of the options of interaction between system configuration elements:

When the web application works via the HTTPS protocol, also set up the work of web forms that use the WebSocket protocol. For details see the Setting Up Web Forms Work via HTTPS section.

Setting Up Interaction between System Configuration Elements via the HTTPS Protocol in Linux OS

Consider setting up interaction between the system configuration elements: browser > HTTPS > web application back end > HTTPS > BI server. The web application back end and the BI server may be located one the same physical server or on different ones.

To set up interaction between system configuration elements via the HTTPS protocol in Linux OS:

  1. Make sure that the system contains the following folders:

Directory Description
/opt/foresight/fp10.x-biserver Main files of BI server.

/etc/apache2-fp10.x in Debian-based distributions

/etc/httpd-fp10.x in RedHat-based distributions

/etc/httpd2-fp10.x in ALT Linux

Configuration files of Apache2 web server instance with installed BI server.
/opt/foresight/fp10.x-webserver Main files of web application back end.
/etc/opt/foresight/fp10.x-webserver The additional configuration file envvars of Apache web server instance, on which web application back end is installed, to ser environment variables.

/etc/apache2-fp10.x-web in Debian-based distributions

/etc/httpd-fp10.x-web in RedHat-based distributions

/etc/httpd2-fp10.x-web in ALT Linux

Configuration files of the Apache2 web server instance, on which web application back end is installed.

NOTE. The specified folders are created by default during web application installation.

  1. Determine DNS name of the server:

sudo hostnamectl set-hostname <DNS name of the server>

  1. Download and unarchive the enable_https.zip archive. Place the enable_https.sh script in the home folder /home/<user name>.

  1. Replace the current directory with the directory with the script:

cd /home/<user name>

  1. Grant access permissions for script execution:

sudo chmod +x enable_https.sh

  1. Open the enable_https.sh script for edit and change values of preconfigured parameters if the system contains a set of ready security certificates:

CERT_DIR=./fp-certs
SERVER_CRT_NAME="fp_server.crt"
SERVER_KEY_NAME="fp_server.key"

Description of variables:

NOTE. Skip the step if the system contains no ready security certificates.

  1. Run the script with the service parameter if the serviceUrl field in the config.json file contains the PP.SOM web service URL:

sudo ./enable_https.sh service

If the field contains the PPService.axd request handler URL, run the script without the parameter:

sudo ./enable_https.sh

If web application back end and BI server are located on different physical servers, the following will be requested during script execution:

If the Step 6 was skipped, after running the script select the security certificate generation method:

IMPORTANT. Self-signed security certificates must not be used in the production environment.

After executing the operations the web application is set up to work via the HTTPS protocol.

During the script execution:

Setting Up Interaction between Browser and Web Application Back End via the HTTPS Protocol

COnsider setting up interaction between the system configuration elements: browser > HTTPS > web application back end > HTTP > BI server. It is assumed that the web application back end and the BI server are located on the same physical server.

Step 1. Placement and Installation of Security Certificates

NOTE. Before executing the step see the guide of certification authority service provider and the operating system documentation.

To place and install security certificates:

  1. Generate and save the server.key server certificate private key.

  2. Create a request to issue the domain.csr server certificate.

  3. Get the server.cer server certificate for Linux OS or the server.pfx server certificate for Windows OS signed by the certification authority that is trusted by all users.

  4. Get the ca.cer root certificate and subca.cer intermediate certificates if they are in the chain of trust.

  5. Place the certificates and keys for installation:

TIP. It is recommended to include certificates of intermediate certification authorities to the server certificate file and exclude the root certificate from it. If required, change the server certificate file in the text editor.

The specified certificate and key files are given as an example and may differ.

Step 2. Import of Root Certificate to Store

To import the root certificate to a trusted root certification authority store, use supported browser or operating system tools. Operating system tools can be used to import certificate to store only in Windows OS.

Consider certificate import in Mozilla Firefox:

  1. Open browser settings at:

about:preferences

  1. Open the Privacy and Security section.

  2. Click the View Certificates button in the Certificates subsection. The Certificate Manager dialog box opens.

  3. Click the Import button on the Authorities tab. A standard file selection dialog box opens.

  4. Select the ca.cer root certificate. The Load Certificate dialog box opens.

  5. Select the trust This CA to Identify Websites checkbox.

After executing the operations the root certificate is imported to the trusted root certification authority store.

To import the root certificate to a trusted root certification authority store using Windows OS tools:

  1. Double-click the ca.cer root certificate. The Certificate dialog box opens.

  2. Click the Install Certificate button. The certificate import wizard opens.

  3. Select the Current User store location and click the Next button.

  4. Select the Place All Certificates to the Following Store radio button, select the Trusted Root Certification Authorities certificate store in the Select Certificate Store dialog box and click the Next button.

After executing the operations the root certificate is imported to the trusted root certification authority store.

For other options of certificate installation and import in various operating systems and browsers see the public services portal.

Step 3. Setting Up Web Application Back End

Setup steps differ depending on the web server, on which the web application back end is installed, and the operating system in use.

To set up the web application back end on Apache2 web server in Linux OS:

  1. Connect the mod_ssl module:

    • Debian-based distributions:

sudo a2enmod-fp10.x-web ssl
sudo a2ensite-fp10.x-web default-ssl

    • RedHat-based distributions:

sudo yum install -y mod_ssl
sudo cp /etc/httpd/conf.modules.d/00-ssl.conf /etc/httpd-fp10.x-web/conf.modules.d/
sudo systemctl restart httpd-fp10.x-web

    • ALT Linux:

sudo apt-get install -y apache2-mod_ssl
sudo cp /etc/httpd2/conf/mods-available/ssl.load /etc/httpd2-fp10.x-web/conf/mods-available/
sudo /usr/sbin/a2enmod-fp10.x-web ssl
sudo systemctl condreload httpd2-fp10.x-web.service

After executing the operations the mod_ssl module is connected. For details about the module see the Apache2 documentation.

For RedHat-based distributions the /etc/httpd-fp10.x-web/conf.d/ssl.conf configuration file will be created with the string to connect the module:

LoadModule ssl_module modules/mod_ssl.so

For ALT Linux the /etc/httpd2-fp10.x-web/conf/mods-enabled/ssl.load configuration file will be created with the string to connect the module:

LoadModule ssl_module /usr/lib64/apache2/modules/mod_ssl.so

  1. Add SSL parameters to the <VirtualHost *:8110> section in the Apache2 web server instance configuration file:

    • /etc/apache2-fp10.x-web/sites-available/webserver.conf in Debian-based distributions.

    • /etc/httpd-fp10.x-web/conf.d/00-virtualhost.conf in RedHat-based distributions.

    • /etc/httpd2-fp10.x-web/conf/sites-enabled/000-default.conf in ALT Linux.

SSLEngine On
SSLCertificateFile <path to folder>/server.cer
SSLCertificateKeyFile <path to folder>/server.key
SSLProxyEngine On

In the <path to folder> substitution specify the folder, which contains the server certificate and its private key.

NOTE. Add TLS protocol parameters generated by means of the SSL Configuration Generator tool.

  1. Make sure that the serviceUrl field in the config.json file contains the PPService.axd request handler URL, and replace HTTP with HTTPS in the serviceUrl, baseUrl fields.

The example of the config.json file:

{
  "targetRepo": "WAREHOUSE",
  "serviceUrl": "https://<DNS name of the server>:8110/fp10.x/app/PPService.axd",
  "locale": "ru",
  "locales": ["ru"],
  "title": "FAP10",
  "baseUrl": "https://<DNS name of the server>:8110/fp10.x/",
  "themes": ["fap10"]
}

  1. Restart the web application back end.

After executing the operations, the web application back end is set up.

To set up the web application back end on IIS server in Windows OS, open the home page of the IIS manager and execute the operations:

  1. Open the Server Certificates feature in the IIS section by double-clicking or using the Open Feature context menu item.

  2. Select the Import item on the Actions panel. The Import Certificate dialog box opens:

  1. Set the parameters:

    • Certificate File (.pfx). Specify the path to the server.pfx server certificate.

    • Password. Specify the password that was used to create a server certificate.

    • Select Certificate Store. Select the Web Hosting option in the drop-down list.

  1. Click the OK button.

  2. Select the site in the Connections tree and select the Bindings item on the Actions panel. The Site Bindings dialog box opens.

  3. Click the Add button. The Add Site Binding dialog box opens:

  1. Set the parameters:

    • Type. Select the https option in the Type drop-down list.

    • SSL Certificate. Select the server corresponding to the imported server certificate in the drop-down list.

  2. Add TLS protocol settings to the registry by means of the IIS Crypto utility.

  3. Make sure that the serviceUrl field in the config.json file contains the PPService.axd request handler URL, and replace HTTP with HTTPS in the serviceUrl, baseUrl fields.

  4. Restart the web application back end.

After executing the operations, the web application back end is set up.

Step 4. Opening Web Application via the HTTPS Protocol

To open the web application via the HTTPS protocol, use the supported browser and specify the address in the connection string:

https://<web server>:<port number>/fp10.x/r/

https://<web server>:<port number>/FP_App_v10.x/r/

Where:

NOTE. As a result of web application setup via the HTTPS protocol, in Linux OS the 8110 port should be used instead of 443.

See also:

Setting Up Web Application Configuration | Opening Web Application