Users are Unable to Start published apps as they recieve launch.jsp instead of launch.ica
book
Article ID: CTX133790
calendar_today
Updated On:
Description
Users are unable to start applications from mobile devices through Web Interface on NetScaler. They receive launch.jsp instead of launch.ica which automatically associates with the ICA client.
Resolution
There are some generic rewrite policies which support the following platforms:
List of generic rewrite actions
- add rewrite action replaceLocationJspToIca replace "HTTP.RES.HEADER(\"Location\").REGEX_SELECT(re#/site/launch.jsp#)" "\"/site/launch.ica\"" -bypassSafetyCheck YES
- add rewrite action replaceLaunchUrlIcaToJsp replace "HTTP.REQ.URL.PATH.REGEX_SELECT(re#/site/launch.ica#)" "\"/site/launch.jsp\"" -bypassSafetyCheck YES
- add rewrite action replaceContentType replace "HTTP.REQ.HEADER(\"Content-Type\")" "\"application/x-www-form-urlencoded\"" -bypassSafetyCheck YES
- add rewrite action insertXmlDocument insert_before "HTTP.REQ.BODY(6).SUBSTR(0,1)" "\"xmlDocument=\"" -bypassSafetyCheck YES
- add rewrite action replace_launch_jsp_in_body replace "http.RES.BODY(5000).REGEX_SELECT(re#launch[.]jsp#)" "\"launch.ica\""
List of generic rewrite policies
- add rewrite policy rw_wi_302_by_ipad_iphone "(HTTP.RES.STATUS.EQ(302) || HTTP.RES.STATUS.EQ(200)) && HTTP.REQ.URL.SUFFIX.EQ(\"jsp\") && (HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"iPad\") || HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"Safari\") || HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"iPhone\")) && HTTP.RES.HEADER(\"Location\").CONTAINS(\"/site/launch.jsp?CTX_UID=\")" replaceLocationJspToIca
If the above expression does not work,change it to:
(HTTP.RES.STATUS.EQ(302)) && (HTTP.REQ.HEADER("User-Agent").CONTAINS("iPad") || HTTP.REQ.HEADER("User-Agent").CONTAINS("Safari") || HTTP.REQ.HEADER("User-Agent").CONTAINS("iPhone")) && HTTP.RES.HEADER("Location").CONTAINS("/site/launch.jsp?CTX_UID=")
- add rewrite policy rw_wi_launch_ica_by_ipad_iphone "HTTP.REQ.URL.SUFFIX.EQ(\"ica\") && (HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"iPad\") || HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"Safari\") || HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"iPhone\")) && HTTP.REQ.URL.PATH_AND_QUERY.CONTAINS(\"/site/launch.ica?\") && HTTP.REQ.HEADER(\"Cookie\").CONTAINS(\"JSESSIONID=\")" replaceLaunchUrlIcaToJsp
If the above expression does not work,change it to:
HTTP.REQ.URL.SUFFIX.EQ("ica") && (HTTP.REQ.HEADER("User-Agent").CONTAINS("iPad") || HTTP.REQ.HEADER("User-Agent").CONTAINS("Safari") || HTTP.REQ.HEADER("User-Agent").CONTAINS("iPhone")) && HTTP.REQ.URL.PATH_AND_QUERY.CONTAINS("/site/launch.ica") && HTTP.REQ.HEADER("Cookie").CONTAINS("JSESSIONID=")
- add rewrite policy rw_wi_posthdr_by_receiver "HTTP.REQ.METHOD.EQ(POST) && HTTP.REQ.URL.SUFFIX.EQ(\"jsp\") && (HTTP.REQ.URL.PATH_AND_QUERY.ENDSWITH(\"enum.jsp\") || HTTP.REQ.URL.PATH_AND_QUERY.ENDSWITH(\"launch.jsp\")) && HTTP.REQ.BODY(6).STARTSWITH(\"<?xml \")" replaceContentType
- add rewrite policy rw_wi_postbody_by_receiver "HTTP.REQ.METHOD.EQ(POST) && HTTP.REQ.URL.SUFFIX.EQ(\"jsp\") && (HTTP.REQ.URL.PATH_AND_QUERY.ENDSWITH(\"enum.jsp\") || HTTP.REQ.URL.PATH_AND_QUERY.ENDSWITH(\"launch.jsp\")) && HTTP.REQ.BODY(6).STARTSWITH(\"<?xml \")" insertXmlDocument
- add rewrite policy rw_wi_200_by_ipad_iphone "HTTP.RES.STATUS.EQ(200) && HTTP.REQ.URL.CONTAINS(\"launcher.jsp\") && (HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"iPad\") || HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"Safari\") || HTTP.REQ.HEADER(\"User-Agent\").CONTAINS(\"iPhone\")) " replace_launch_jsp_in_body
Problem Cause
The iPad/iPhone support option in Web Interface on NetScaler Wizard is applicable only with iPad and iPhone.
When users try to start applications from other mobile devices or from the Safari Browser from Windows or Macintosh computers after enabling this option, they get launch.jsp instead of launch.ica.
Issue/Introduction
Users are unable to start applications using Safari Browser. They receive launch.jsp instead of launch.ica which automatically associates with the ICA client.
Was this article helpful?
thumb_up
Yes
thumb_down
No