Web Gateway Guide Introduction to the Web Gateway Purposes of the Web Server, Web Gateway, and CSP Server How the Web Server, Web Gateway, and CSP Server Work Together Structure of an InterSystems Web Application URL Supported Configurations for the Web Gateway Supported Configurations Supported Web Servers Installing the Web Gateway Default Web Gateway Installation and Configuration Web Gateway Management Modules Web Gateway Components and Physical Installation Paths Deploying the Web Gateway as a Stand-alone Component Using or Replacing the Private Web Server Purpose of the Private Web Server Limitations of the Private Web Server Using a Different Web Server to Run the Management Portal Managing the Private Web Server Configuring IIS to Work With the Web Gateway (Windows) Common Steps (All Versions) Additional Steps: Microsoft IIS 7 or Later Configuring Apache to Work With the Web Gateway (Windows) Assumptions Install Locations with Apache Servers (All Configurations) Recommended Option: Apache API Modules (CSPa24.dll) Configuring Apache to Pass Additional File Types (All Platforms) Configuring Apache by Location Configuring Apache by File Extension (CSPFileTypes Directive) Configuring Apache by MIME Type Building and Configuring Nginx to Work With the Web Gateway (Windows) Assumptions Installation Building the Nginx Web Server for CSP Using the NSD with Nginx Deprecated: Building Nginx to Work with the Universal Modules Configuring Apache to Work With the Web Gateway (UNIX®/Linux/macOS) Assumptions Install Locations for Apache for UNIX®, Linux, macOS (Recommended Option) Recommended Option: Apache API Module without NSD (CSPa24.so) Building and Configuring Nginx (UNIX®/Linux/macOS) Assumptions Installation Building the Nginx Web Server for CSP Using the NSD with Nginx Deprecated: Building Nginx to Work with the Universal Modules Configuration Basics for the Web Gateway Web Gateway Configuration and Log Files File Types Automatically Routed to InterSystems IRIS Serving Static Files from InterSystems IRIS Enable Sticky Sessions on Hardware Load Balancer on High Availability Solutions Enable Script to Reactivate Web Gateway Configuration Hybrid Multi-Process/Multi-Threaded Web Server Architecture Overview of the Web Gateway Management Pages Accessing the Web Gateway Management Pages Enabling Access from Additional Client Addresses Available Options Localization Configuring the Default Parameters for Web Gateway Web Gateway Security Connections to InterSystems IRIS ASP Redirect Internal HTTP Server Custom Error Pages Event Logging Parameters Configuring Server Access Adding a Server Configuration Copying a Server Configuration Disabling Access to a Configured Server Deleting a Server Configuration Configuring Application Access Adding an Application Path Copying an Application Path Configuration Disabling Access via an Application Path Deleting an Application Path Configuration Managing and Monitoring the Web Gateway Checking System Status Testing Server Connections Viewing the Event Log Using the HTTP Trace Facility Protecting Web Gateway Connections to InterSystems IRIS Configuring Connection Security for the Web Gateway Minimal Connection Security (Not Recommended) Simple Username/Password Authentication Kerberos-based Authentication and Data Protection SSL/TLS-Based Authentication and Data Protection CGI Environment Variables Passed by the Web Gateway HTTP Response Headers Returned by the Web Gateway Compressing the Response to Requests for CSP Forms (GZIP/ZLIB) The GZIP/ZLIB Library Using the GZIP/ZLIB Library Specifying Compression for Individual Pages Specifying Compression for All Pages within an Application Path Monitoring Implementing HTTP Authentication for Web Applications Standard HTTP authentication in Apache (mod_auth) Authenticating in CSP at the Same Time as the Request is Processed. Authenticating in CSP before the Request is Processed. Mirrored Configurations, Failover, and Load Balancing Load Balancing and Failover Between Multiple Web Servers Load Balancing and Failover Between Multiple InterSystems IRIS Server Instances Mirrored Configurations Process Affinity and State-Aware Mode (Preserve Mode 1) Launching State-Aware Mode Maintaining State-Aware Mode and Responding to Errors Terminating State-Aware Mode Web Gateway Registry in InterSystems IRIS Forcing the Web Gateway to Reload Its Configuration Using the NSD (Windows) When to Use the NSD NSD Module Install Locations Operating the NSD Alternative Options for IIS 7 or Later (Windows) Installing the ISAPI and CGI Services Alternative Option 1: Using the ISAPI Modules (CSPms*.dll) Alternative Option 2: Using a Native Module with the NSD (CSPcms.dll) Alternative Option 3: Using an ISAPI Module with the NSD (CSPcms.dll) Alternative Option 4: Using the CGI Modules with the NSD (nph-CSPcgi*.exe) Alternative Options for Apache (Windows) Install Locations (All Atypical Options) Alternative Option 1: Apache and CGI Modules with NSD (nph-CSPcgi.exe) Alternative Option 2: Apache API Module with NSD (mod_csp24.dll) Locked-down Apache Environments for Microsoft Windows Using the NSD (UNIX®/Linux/macOS) When to Use the NSD NSD Module Install Locations Operating the NSD Alternative Options for Apache (UNIX®/Linux/macOS) Install Locations (All Atypical Options) Alternative Option 1: Apache API Module with NSD (mod_csp24.so) Alternative Option 2: CGI Modules with NSD (nph-CSPcgi) Alternative Option 3: Built-in Apache API Module with NSD (mod_csp.c) Locked-down Apache (UNIX®/Linux/macOS) Recommended Option: Apache API Modules (CSPa24.so) Alternative Option 1: Apache API Module with NSD (mod_csp.so) Alternative Option 2: CGI Modules with NSD (nph-CSPcgi) Alternative Option 3: Built-in Apache API Module with NSD (mod_csp.c) Apache Considerations (UNIX®/Linux/macOS) Apache Process Management and Capacity Planning State-Aware Sessions (Preserve mode 1) IIS Technical Notes IIS Application Pools and Web Gardens Bitness — 32-bit Apps on 64-bit Servers for Windows Using Web Applications with a Remote Web Server Configuring the Web Server and Web Gateway Accessing CSP on Multiple InterSystems IRIS Servers Configuring Apache Virtual Hosts Using WebSockets (RFC 6455) WebSockets Protocol WebSockets Client Code (JavaScript) WebSockets Server Code WebSockets Server Example WebSockets Server Asynchronous Operation