title: using xmlHTTPRequest for opening a secure application in a new window
body: <p>We have a requirement where we want the ability to launch a new application (NewApp) from the base app (BaseApp). The login credentials for BaseApp and the NewApp are same since they use the same identity store.
  BaseApp and NewApp are on different tech stacks, both being web applications. they are hosted on different servers.
  NewApp provides basic Auth for web access.</p>
  
  <p>How can I use java script to launch NewApp from links on my BaseApp. I want to be able to inject Basic Auth credentials.</p>
  
  <p>I have tried using xmlHTTPRequest, but it appears to be geared more towards calling REST services and processing the fetched data rather than launching URLs.
  using java script window.open(url) does not let me inject authorization header!</p>
  
  <p>anything else I can explore ?</p>
  
  <p>Additional Info:
  The session cookie for BaseApp is not applicable for NewApp. When we first complete Basic Auth on the BaseApp, it generates a new Session Cookie which needs to be used.
  Through xhr we are able to call the URL (with Basic Auth) for the NewApp. This returns a response with a session cookie.
  The problem that I am unable to figure out is, how to render the response on a new window/tab on the browser.</p>