title: How to open Keycloak sign-in page inside a bootstrap modal
body: <p>I am creating an <code>npm</code> package and I want to authenticate users with Keycloak. But what exactly I want to do is</p>
  <p>when someone clicks on authenticates button it should open a <code>bootstrap</code> modal and inside this modal, I should see the Keycloak login page and after filling in the information it should authenticate me and return back to that modal itself.</p>
  <p><strong>What is happening?</strong></p>
  <p>When someone opens the modal for signing in it redirects the user to another window where the Keycloak form is located and we have to fill in the information there and it redirects the user back to the calling page.</p>
  <p><strong>What are the requirements?</strong></p>
  <p>Keycloak sign-in page should open inside the modal itself and one should be able to authenticate on modal.</p>
  <p><strong>What I have tried?</strong></p>
  <p>I have tried using iframes inside the modal so that the sign-in page for Keycloak can open inside the popup itself. But after filling in the details it redirects me to the same frame instead of the calling site.</p>
  <p>I have tried loading the whole process inside an iframe and then again it redirects me to the sign-in page on a different window.</p>
  <p>I have published the package <code>@adeshkumar/component</code>.</p>
  <pre><code>import React from 'react';
  
  const LoginPage = () =&gt; {
  return (
      &lt;iframe
          height=&quot;100%&quot;
          width=&quot;100%&quot;
          allowtransparency=&quot;true&quot;
          src=&quot;HTTP://localhost:3000/auth/realms/realm1/protocol/openid-connect/auth?client_id=client1&amp;redirect_uri=http://localhost:3000&amp;state=f60ed21e-1708-4d81-9746-1b607650c1d9&amp;response_mode=fragment&amp;response_type=code&amp;scope=openid&amp;nonce=d1af5a78-a30b-4d91-84ad-9e2a3d9e1586&quot;&gt;
  
      &lt;/iframe&gt;
  );
  };
  
  export default LoginPage;
  </code></pre>
  <p>This is how I am trying to put this inside iframe but it is not working expected.</p>
  <p>I am kind of stuck at this thing just want to know whether this is possible or not even. Or is there any other way I can open a URL or tab inside a modal.</p>