Enabling Site Content Compression for EmpowerID

If you are experiencing long response times due to bandwidth issues between sites, it may be beneficial to enable HTTP compression for EmpowerID. Enabling HTTP compression can provide faster transmission times between IIS and client browsers that can accept compressed files. There are two different types of compression that IIS uses: Static Content Compression and Dynamic Content Compression. Both types of compression need to be installed and enabled for the benefits of site content compression to be seen when using EmpowerID.

NOTE: Installing and enabling Dynamic Content Compression will provide more efficient utilization of bandwidth at the cost of server processor utilization. Please ensure that your IIS server can handle the increased CPU load imposed by Dynamic Content Compression.

Installing HTTP compression

Windows Server 2008 family:

Open Server Manager.

In the Server Manager hierarchy pane, expand Roles and then click Web Server (IIS).

In the Web Server (IIS) pane, scroll to the Role Services section and then click Add Role Services.

On the Select Role Services page of the Add Role Services Wizard, expand Web Server, expand Performance, select Static Content Compression and Dynamic Content Compression and then click Next.

On the Confirm Installation Selections page of the Add Role Services Wizard, click Install. On the Results page, click Close. Open Internet Information Services (IIS) Manager.

In the Connections pane, highlight the name of your IIS server.

In the server's Home pane, double-click Compression.

In the Compression pane, check Enable dynamic content compression and Enable static content compression.

Click Apply in the Actions pane.

Windows Server 2012 family:

Open Server Manager.

In the Server Manager hierarchy pane, click on IIS.

In the IIS pane, scroll to the Role Services section, click on the Tasks drop down and then click Add Roles and Features.

On the Select installation type page of the Add Roles and Features Wizard, choose Role-based or feature-based installation and click Next.

On the Select destination server page of the Add Roles and Features Wizard, in the Server Pool pane, choose your IIS server and click Next.

On the Select server roles page of the Add Roles and Features Wizard, expand Web Server (IIS), expand Performance, select Static Content Compression and Dynamic Content Compression and click Next.

On the Select features page of the Add Roles and Features Wizard, click Next. On the Confirm installation selections page of the Add Roles and Features Wizard, click Install. Open Internet Information Services (IIS) Manager.

In the Connections pane, highlight the name of your IIS server.

In the server's Home pane, double-click Compression.

In the Compression pane, check Enable dynamic content compression and Enable static content compression.

Click Apply in the Actions pane.

 

Enabling HTTP compression in web.config

NOTE: If you are running EmpowerID 2014 MU2 or later you may skip this section. For assistance in determining which version of EmpowerID you have installed, please see the following KB article: How to find which version of EmpowerID you are using.

Navigate to the following folders on your EmpowerID IIS server:

X:\Program Files\TheDotNetFactory\EmpowerID\Web Sites\EmpowerID.Web.IDP.Forms
X:\Program Files\TheDotNetFactory\EmpowerID\Web Sites\EmpowerID.Web.IDP.SmartCard
X:\Program Files\TheDotNetFactory\EmpowerID\Web Sites\EmpowerID.Web.IDP.Windows
X:\Program Files\TheDotNetFactory\EmpowerID\Web Sites\EmpowerID.Web.IDP.WSFederation
X:\Program Files\TheDotNetFactory\EmpowerID\Web Sites\EmpowerID.Web.ServiceProvider

Replace X:\ with the drive letter where EmpowerID is installed.

In these folders you will see a web.config file. Open this file in a text editor of your choice and find the following section:

</handlers>
<httpRedirect enabled="false" />
</system.webServer>

You will want to change this section to look like the following:

</handlers>
<httpRedirect enabled="false" />
<urlCompression doStaticCompression="true" doDynamicCompression="true" />
</system.webServer>

NOTE: web.config files are case sensitive. Malformed web.config files will cause an outage in EmpowerID services. Please be careful when modifying web.config files in a production environment.

Please note that if you are accessing a load balanced URL you will need to perform these changes on each IIS server that is a target of the load balanced URL.

 

Confirming HTTP compression is working

Open Google Chrome.

Press F12 to open the Developer tools. Click on the Network tab.

Load the EmpowerID web site and then click on any of the requests listed on the Network tab. Click the Headers tab. Expand the Response Headers section and confirm Content-Encoding: gzip is present.

Please feel free to contact us by e-mail at support@empowerid.com or by phone at (877) 996-4276 (Option 2) if you have any questions or concerns regarding this guide.