2
SAP Note Header Data Symptom You get following error message in sxi_cache: - HTTP response does not contain a valid XML root tag - Error 'HTTP status code 400 Bad Request' while executing HTTP request (calling method 'get_status') - Error 'HTTP status code 403 Forbidden' while executing HTTP request ( calling method 'get_status') When sxi_cache shows "Unable to refresh cache contents" status message, double click on the message to open "Last Error during Cache Refresh" window with more details on the error. Other Terms PI Integration Directory, Cache Refresh, sxi_cache, XSRF, Process Integration 7.31, Reason and Prerequisites Several changes in Integration Directory and underlying components were done over last several months due to security standards. These changes affect cache refresh functionality. This note describes typical error situations and provides steps how to fix them. Solution Depending on the error message apply provided solution. 1) HTTP response does not contain a valid XML root tag or Error 'HTTP status code 400 Bad Request' while executing HTTP request (calling method 'get_status') The error 'HTTP response does not contain a valid XML root tag' occurs when path prefix of the destination is '/dir/hmi_cache_refresh_service/ext'. The error 'Error 'HTTP status code 400 Bad Request' while executing HTTP request (calling method 'get_status')' when path prefix is '/dir/CacheRefresh'. Solution: Go to transaction sm59 and open destination of type 'H' INTEGRATION_DIRECTORY_HMI. Select "Connection Test". The connection test should return HTTP response 200. Now go to "Logon & Security" tab and ensure that username and password are stored in the system. Fixing credentials should fix the problem. Note: Credentials cannot be tested via "Connection Test" tool. If used credentials are wrong, the server simply returns login html page (using HTTP response code 200). As the login html page is not a valid cache refresh xml document, an error is shown in sxi_cache. 2) Error 'HTTP status code 403 Forbidden' while executing HTTP request ( calling method 'get_status') This error occurs due to XSRF protection implemented in Integration Directory. The protection requires changes in ABAP clients, the fix comes with 7.31 SP8 and higher. There is no fix available for 7.30 and lower releases. Note: Such error in sm59's connection test of INTEGRATION_DIRECTORY_HMI is normal. This error in sm59 cannot be 'fixed' because it reflects the presence of the security fix. The sm59 connection test logic does not support xsrf protocol, therefore the connection test fails. When your ABAP system has the required patch, sxi_cache works fine when sm59 returns this error. Please double check whether you have an issue in sxi_cache or in sm59. Solution: Either upgrade ABAP backend to 7.31 or deactivate XSRF protection until all your backends are upgraded. There are two possibilities to deactivate XSRF protection: you can do it globally for the entire J2EE engine or locally just for /dir/CacheRefresh servlet. 1894606 - HTTP errors in sxi_cache Version 4 Validity: 20.01.2014 - active Language English (Master) Released On 20.01.2014 14:33:09 Release Status Released for Customer Component BC-XI-IBC Integration Builder - Configuration Priority Correction with high priority Category Program error

1894606 - HTTP Errors in Sxi_cache

Embed Size (px)

Citation preview

  • SAP Note

    Header Data

    Symptom

    You get following error message in sxi_cache:

    - HTTP response does not contain a valid XML root tag

    - Error 'HTTP status code 400 Bad Request' while executing HTTP request (calling method 'get_status')

    - Error 'HTTP status code 403 Forbidden' while executing HTTP request ( calling method 'get_status')

    When sxi_cache shows "Unable to refresh cache contents" status message, double click on the message to open "Last Error during Cache Refresh" window with more details on the error.

    Other Terms

    PI Integration Directory, Cache Refresh, sxi_cache, XSRF, Process Integration 7.31,

    Reason and Prerequisites

    Several changes in Integration Directory and underlying components were done over last several months due to security standards. These changes affect cache refresh functionality. This note describes typical error situations and provides steps how to fix them.

    Solution

    Depending on the error message apply provided solution.

    1) HTTP response does not contain a valid XML root tag orError 'HTTP status code 400 Bad Request' while executing HTTP request (calling method 'get_status')

    The error 'HTTP response does not contain a valid XML root tag' occurs when path prefix of the destination is '/dir/hmi_cache_refresh_service/ext'. The error 'Error 'HTTP status code 400 Bad Request' while executing HTTP request (calling method 'get_status')' when path prefix is '/dir/CacheRefresh'.

    Solution: Go to transaction sm59 and open destination of type 'H' INTEGRATION_DIRECTORY_HMI.Select "Connection Test". The connection test should return HTTP response 200. Now go to "Logon & Security" tab and ensure that username and password are stored in the system. Fixing credentials should fix the problem.

    Note: Credentials cannot be tested via "Connection Test" tool. If used credentials are wrong, the server simply returns login html page (using HTTP response code 200). As the login html page is not a valid cache refresh xml document, an error is shown in sxi_cache.

    2) Error 'HTTP status code 403 Forbidden' while executing HTTP request ( calling method 'get_status')

    This error occurs due to XSRF protection implemented in Integration Directory. The protection requires changes in ABAP clients, the fix comes with 7.31 SP8 and higher. There is no fix available for 7.30 and lower releases.

    Note: Such error in sm59's connection test of INTEGRATION_DIRECTORY_HMI is normal. This error in sm59 cannot be 'fixed' because it reflects the presence of the security fix. The sm59 connection test logic does not support xsrf protocol, therefore the connection test fails. When your ABAP system has the required patch, sxi_cache works fine when sm59 returns this error. Please double check whether you have an issue in sxi_cache or in sm59.

    Solution: Either upgrade ABAP backend to 7.31 or deactivate XSRF protection until all your backends are upgraded.

    There are two possibilities to deactivate XSRF protection: you can do it globally for the entire J2EE engine or locally just for /dir/CacheRefresh servlet.

    1894606 - HTTP errors in sxi_cache

    Version 4 Validity: 20.01.2014 - active Language English (Master)

    Released On 20.01.2014 14:33:09 Release Status Released for Customer Component BC-XI-IBC Integration Builder - Configuration Priority Correction with high priority Category Program error

  • 1. In order to deactivate XSRF protection globally go to NWA -> Configuration -> Infrastructure -> Java System Properties. - Switch to tab "Services", search for Web Container service - Click on Show Advanced Properties - Set xsrf.protection.enabled to false

    2. To switch the xsrf protection locally go to Exchange Profile properties and setcom.sap.aii.ibdir.server.cache.xsrfProtection = false

    3. One more workaround currently exists for this problem:Go to sm59 and open INTEGRATION_DIRECTORY_HMI destination. Use following path there: "/dir/hmi_cache_refresh_service/ext". Do not forget to re-enter password on "Logon & Security" tab, otherwise you might get 'HTTP response does not contain a valid XML root tag' error described above. Save the destinaion and retry the cache refresh. The alternative URL is not yet XSRF-protected, which will be fixed in further SPs.

    Validity

    Support Packages & Patches

    References

    This document is referenced by:

    SAP Notes (1)

    Software Component From Rel. To Rel. And Subsequent

    SAP_XITOOL 7.31 7.31

    7.40 7.40

    Support Package Patches

    Software Component Support Package Patch Level

    XI TOOLS 7.31 SP008 000011

    SP009 000007

    SP010 000000

    SP011 000000

    XI TOOLS 7.40 SP003 000011

    SP004 000004

    SP005 000000

    SP006 000000

    1929966 Collective note : SAP NETWEAVER 7.31 SP11 - PO (PI)