Exclude Content Based on Content-Type

The HTTP header "content-type:" defines the format of response body. This topic describes how to exclude content from the correlation scan by content-type.

  1. Open the <Installation folder>\config\IgnoredContent.xml in a text editor.

    IgnoredContent.xml

    Example: <?xml version="1.0" encoding="utf-8" ?>
     <IgnoredHttpContentTypes 
         xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
         xmlns:xsd="http://www.w3.org/2001/XMLSchema">
       <CONTENT_TYPES>
       <string>application/(?!(x-amf|json))</string>
        <string>audio/</string>
        <string>image/</string>
        <string>model/</string>
        <string>video/</string>
      </CONTENT_TYPES>
    </IgnoredHttpContentTypes>
  2. Modify the IgnoredContent.xml to exclude content-type by inserting a string or regular expression.

    If you enter: Design Studio will:
    image/ Ignore any content type beginning with image/ such as image/gif, image/jpeg, image/png
    application/(!?(json|x-amf)) Ignore content type that begins with application/ except for content type application/json or application/x-amf.

    Example of content added to the IgnoredContent.xml

    In this example, the correlation engine will ignore content unless formatted x-amf , json, or javascript.

    Example: <?xml version="1.0" encoding="utf-8" ?>
    <IgnoredHttpContentTypes 
      xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
      xmlns:xsd="http://www.w3.org/2001/XMLSchema">
      <CONTENT_TYPES>
       <string>application/(?!(x-amf|json|javascript))</string>
       <string>audio/</string>
       <string>image/</string>
       <string>model/</string>
       <string>video/</string>
      </CONTENT_TYPES>
    </IgnoredHttpContentTypes>
Back to top