Web Interface on NetScaler Error: Corrupted Content Error or Duplicate Headers Received from the Server

Web Interface on NetScaler Error: Corrupted Content Error or Duplicate Headers Received from the Server

book

Article ID: CTX131952

calendar_today

Updated On:

Description

The following error appears when using Web Interface on NetScaler in Firefox or Google Chrome:

Corrupted Content Error or Duplicate headers received from the server"

Resolution

Complete the following steps to resolve the issue:

  1. Run the following command from the command line interface of the appliance to add the rewrite action:
    add rewrite action ReplaceContentLengthZeroHeader_act replace "HTTP.RES.FULL_HEADER.REGEX_SELECT(re!Content-Length: 0!)" "\"Cotnent-Length: 0\""
    Note: The “Cotnent-Length” is intentionally spelt wrong in the rewrite policy to destroy the duplicate header.

  2. Run the following command to add a rewrite policy:
    add rewrite policy ReplaceContentLengthZero_pol "HTTP.RES.STATUS.EQ(302) && HTTP.RES.FULL_HEADER.REGEX_MATCH(re!Content-Length: 0!) && HTTP.RES.FULL_HEADER.REGEX_MATCH(re!Location: .*/login.jsp!)" ReplaceContentLengthZeroHeader_act

  3. Run the following command to bind the policy at the global level:
    bind rewrite global ReplaceContentLengthZero_pol 10 END -type RES_DEFAULT


Problem Cause

The response from the NetScaler appliance has two instances of Content-Length header.

Issue/Introduction

The error " Corrupted Content Error or Duplicate headers received from the server" appears when you use Web Interface on NetScaler in Firefox or Google Chrome: