We have a PS app working fine with internal URLs, cloud servers, all over https, but as we want external access to the application we have created external URLs. Access to external URLs is controlled by MS AppProxy.
We can access the URLs through the browser and get the .Net screens etc., but when we try and run the app the cloud app launcher kicks off and then fails. It appears that the deploylist.ini and LauncherSetup.json get intercepted somehow. For example, the deploylist.ini should contain this:
[Public]
MinimumValidVersion=5.01
[5.01]
OnlineTime=2021-10-28 23:26:28
OfflineTime=2031-10-28 23:26:28
but actually contains this (and a whole lot more):
<!-- Copyright (C) Microsoft Corporation. All rights reserved. -->
<!DOCTYPE html>
<html>
<head>
<title>Redirecting</title>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=2.0, user-scalable=yes">
<meta http-equiv="Pragma" content="no-cache">
<meta http-equiv="Expires" content="-1">
<meta name="PageID" content="BssoInterrupt" />
<meta name="SiteID" content="" />
<meta name="ReqLC" content="1033" />
<meta name="LocLC" content="en-US" />
<meta name="robots" content="none" />
<script type="text/javascript">//<![CDATA[
$Config={"iMaxStackForKnockoutAsyncComponents":10000,"fShowButtons":true,"urlCdn":"https://aadcdn.msauth.net/shared/1.0/","urlDefaultFavicon":"https://aadcdn.msauth.net/shared/1.0/content/images/favicon_a_eupayfgghqiai7k9sol6lg2.ico","urlPost":"/f66fae02-5d36-495b-bfe0-78a6ff9f8e6e/oauth2/authorize?response_type=code\u0026client_id=449b19ed-7753-47b4-9f39-45f21227e5e5\u0026scope=openid\u0026nonce=7c5553c3-9c40-4ab4-8e96-659f11b8f965\u0026redirect_uri=https%3a%2f%2funiprom.unilever.com%2f\u0026state=AppProxyState%3a%7b%22InvalidTokenRetry%22%3anull%2c%22IsMsofba%22%3afalse%2c%22OriginalRawUrl%22%3a%22https%3a%5c%2f%5c%2funiprom.unilever.com%5c%2funiprom%5c%2fdeploylist.ini.zip%22%2c%22RequestProfileId%22%3anull%2c%22SessionId%22%3a%2268e72609-1234-43a4-9ecd-b592de8fe3fb%22%7d%23EndOfStateParam%23\u0026client-request-id=68e72609-1234-43a4-9ecd-b592de8fe3fb\u0026sso_reload=True","iPawnIcon":0,"sPOST_Username":"","sFTName":"flowToken","urlReportPageLoad":"https://login.microsoftonline.com/common/instrumentation/r
I just wondered if anyone had experience of this? I'm guessing that AppProxy is giving some sort of redirect instruction that the Cloud App Launcher can't interpret.
Thanks
function getCookie(){
var strCookie = "";
strCookie = document.cookie;
return strCookie;
}
function getCmdline(Url){
var strCookie = getCookie();
var strUrl = Url;
if(strCookie.length > 0)
{
strUrl += " -cookie ";
strUrl += strCookie;
}
return strUrl;
}
I also tried different browser and cleared the cookies, but always the same result. Also restarted IIS etc..
The full returned file is in the zip attached to the other response if you get a minute to look at it?
Name
AzureAppProxyPreauthSessionCookie_653a3cb9-0083-4305-bd38-5257510de066_0c66ffc0-0341-420b-8572-47abbb09d52d_1.4
Content
3|tRaL5OFEmQd9M2dHUYHNq3BnIgBQsn08Gp0XdDe0eDYT4UYenpQ6kAOAJeoJVjqP6gj/PKd+GNCUwyQ5Ex8iHjL7Wm/mM2CeLRKSqo5h/2i8mPpu4Lip4oh19giEsitoTJBAEl+ikWgces3EnwmUASInJu4Pv2emjF55N3UNrAd9hV/p+CSvzmFFyDw2l22xatTrrEaP46Xq8NKO+1es48LtsIbO8ahCdTnHovrJo6kA+lf1FCAivvS1n9bcaxay7OVRfdinSuhPW1rinOgLl4MbStehBnfUuyNYqJvnopb+uRXBgLtw/+Vd+TuQbtRf
I found some relevant information for you but don't have the same environment to verify them:
https://docs.microsoft.com/en-us/azure/active-directory/app-proxy/application-proxy-configure-cookie-settings
https://stackoverflow.com/questions/63633796/how-to-get-and-set-the-azureappproxyaccesscookie-programatically-to-access-on-pr
https://docs.microsoft.com/en-us/azure/active-directory/app-proxy/application-proxy-configure-cookie-settings
Maybe it can be easier to try your cookie settings in PostMan to see whether you can GET the .ini file.
If you can't solve this issue by setting cookies, please report it via our support ticketing system to ensure it is being properly received by our tech support and tracked at: https://www.appeon.com/standardsupport/.
Regards, Logan