title: Complete OpenIDConnect auth when requesting via Ajax
body: <p>The normal OpenIDConnect server works like:</p>
  
  <ul>
  <li>You go to <code>a.com/secure-resource</code></li>
  <li>You get a <code>302</code> back from the server</li>
  <li>Your browser handles it and sends you to the identity server</li>
  <li>You login there</li>
  <li>It sends you back to <code>a.com</code> via a <code>POST</code></li>
  <li>You get logged in on <code>a.com</code> and get <code>a.com/secure-resource</code> back on your browser.</li>
  </ul>
  
  <p><strong>However</strong> I have a scenario that I'm trying to solve but I need your help.</p>
  
  <ul>
  <li>The user is already logged in on idServer</li>
  <li>The user is logged in on <code>a.com</code></li>
  <li>The user is NOT logged in on <code>b.com</code></li>
  <li>We need to send an ajax call to web server <code>b.com</code> (from another domain <code>a.com</code>)</li>
  <li><code>b.com</code> is configured to use OpenIDConnect.</li>
  <li>But because the request to <code>b.com</code> is via Ajax, user cannot be redirected normally to idServer. (all we get in response is a <code>302</code>)</li>
  </ul>
  
  <p>We can go ahead and handle the 302 via Ajax (I'm still not sure whether that would work, security-wise).</p>
  
  <p><strong>BUT</strong></p>
  
  <p>Is there any scenario in IdentityServer/OpenIDConnect that is designed for these situations?</p>