<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
</head>
<body style="word-wrap: break-word; -webkit-nbsp-mode: space; -webkit-line-break: after-white-space; color: rgb(0, 0, 0); font-size: 14px; font-family: Calibri, sans-serif;">
<div>Hi Stian,</div>
<div><br>
</div>
<div>I understand that I can create a theme using free marker, but my question was, if I were to create a theme using JSP instead of free marker, then do I have to change the Keycloak&#8217;s source code?</div>
<div><br>
</div>
<span id="OLK_SRC_BODY_SECTION">
<div style="font-family:Calibri; font-size:11pt; text-align:left; color:black; BORDER-BOTTOM: medium none; BORDER-LEFT: medium none; PADDING-BOTTOM: 0in; PADDING-LEFT: 0in; PADDING-RIGHT: 0in; BORDER-TOP: #b5c4df 1pt solid; BORDER-RIGHT: medium none; PADDING-TOP: 3pt">
<span style="font-weight:bold">From: </span>Stian Thorgersen &lt;<a href="mailto:sthorger@redhat.com">sthorger@redhat.com</a>&gt;<br>
<span style="font-weight:bold">Reply-To: </span>&quot;<a href="mailto:stian@redhat.com">stian@redhat.com</a>&quot; &lt;<a href="mailto:stian@redhat.com">stian@redhat.com</a>&gt;<br>
<span style="font-weight:bold">Date: </span>Friday, February 12, 2016 at 6:53 PM<br>
<span style="font-weight:bold">To: </span>Abdullah Sarp Kaya &lt;<a href="mailto:akaya@expedia.com">akaya@expedia.com</a>&gt;<br>
<span style="font-weight:bold">Cc: </span>&quot;<a href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a>&quot; &lt;<a href="mailto:keycloak-user@lists.jboss.org">keycloak-user@lists.jboss.org</a>&gt;<br>
<span style="font-weight:bold">Subject: </span>Re: [keycloak-user] Extending Themes via SPI<br>
</div>
<div><br>
</div>
<div>
<div>
<div dir="ltr">No, you can create a theme that contains stylesheets and freemarker templates (if you need to change those) and deploy it to Keycloak. Please read&nbsp;<a href="http://keycloak.github.io/docs/userguide/keycloak-server/html/themes.html">http://keycloak.github.io/docs/userguide/keycloak-server/html/themes.html</a>
 and take a look at the themes examples in our examples download.</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On 12 February 2016 at 09:47, Sarp Kaya <span dir="ltr">
&lt;<a href="mailto:akaya@expedia.com" target="_blank">akaya@expedia.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:Calibri,sans-serif">
<div>Okay but what you are saying is done directly on the Keycloak source code which is then built and deployed, rather than extending classes and then deploying directly to a Keycloak instance?</div>
<div><br>
</div>
<span>
<div style="font-family:Calibri;font-size:11pt;text-align:left;color:black;BORDER-BOTTOM:medium none;BORDER-LEFT:medium none;PADDING-BOTTOM:0in;PADDING-LEFT:0in;PADDING-RIGHT:0in;BORDER-TOP:#b5c4df 1pt solid;BORDER-RIGHT:medium none;PADDING-TOP:3pt">
<span class=""><span style="font-weight:bold">From: </span>Stian Thorgersen &lt;<a href="mailto:sthorger@redhat.com" target="_blank">sthorger@redhat.com</a>&gt;<br>
<span style="font-weight:bold">Reply-To: </span>&quot;<a href="mailto:stian@redhat.com" target="_blank">stian@redhat.com</a>&quot; &lt;<a href="mailto:stian@redhat.com" target="_blank">stian@redhat.com</a>&gt;<br>
</span><span style="font-weight:bold">Date: </span>Friday, February 12, 2016 at 6:29 PM
<div>
<div class="h5"><br>
<span style="font-weight:bold">To: </span>Abdullah Sarp Kaya &lt;<a href="mailto:akaya@expedia.com" target="_blank">akaya@expedia.com</a>&gt;<br>
<span style="font-weight:bold">Cc: </span>&quot;<a href="mailto:keycloak-user@lists.jboss.org" target="_blank">keycloak-user@lists.jboss.org</a>&quot; &lt;<a href="mailto:keycloak-user@lists.jboss.org" target="_blank">keycloak-user@lists.jboss.org</a>&gt;<br>
<span style="font-weight:bold">Subject: </span>Re: [keycloak-user] Extending Themes via SPI<br>
</div>
</div>
</div>
<div>
<div class="h5">
<div><br>
</div>
<div>
<div>
<div dir="ltr">There's a lot more to the login on Keycloak than a simple JSP page used for JEE form-based authentication. We have user registration, password recovery, OTP support, remember me, etc, etc..
<div><br>
</div>
<div>Take the look and feel (stylesheet) of your JSP login screen and apply it to Keycloak with a custom theme. That's the simplest, quickest and best option.<br>
<div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On 12 February 2016 at 09:15, Sarp Kaya <span dir="ltr">
&lt;<a href="mailto:akaya@expedia.com" target="_blank">akaya@expedia.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div>
<div>
<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:Calibri,sans-serif">
<div><br>
</div>
<span>
<div>
<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:Calibri,sans-serif">
<div>We have internal front end libraries that works with JSP only. From the sounds of SPI, I thought that I could use JSP and our internal libraries instead of FreeMarker templates. Also because our JSP login screen is almost ready it wouldn&#8217;t take much time
 to just deploy it (that&#8217;s what I thought).</div>
<div><br>
</div>
<span>
<div style="font-family:Calibri;font-size:11pt;text-align:left;color:black;BORDER-BOTTOM:medium none;BORDER-LEFT:medium none;PADDING-BOTTOM:0in;PADDING-LEFT:0in;PADDING-RIGHT:0in;BORDER-TOP:#b5c4df 1pt solid;BORDER-RIGHT:medium none;PADDING-TOP:3pt">
<span style="font-weight:bold">From: </span>Stian Thorgersen &lt;<a href="mailto:sthorger@redhat.com" target="_blank">sthorger@redhat.com</a>&gt;<br>
<span style="font-weight:bold">Reply-To: </span>&quot;<a href="mailto:stian@redhat.com" target="_blank">stian@redhat.com</a>&quot; &lt;<a href="mailto:stian@redhat.com" target="_blank">stian@redhat.com</a>&gt;<br>
<span style="font-weight:bold">Date: </span>Friday, February 12, 2016 at 5:54 PM<br>
<span style="font-weight:bold">To: </span>Abdullah Sarp Kaya &lt;<a href="mailto:akaya@expedia.com" target="_blank">akaya@expedia.com</a>&gt;<br>
<span style="font-weight:bold">Cc: </span>&quot;<a href="mailto:keycloak-user@lists.jboss.org" target="_blank">keycloak-user@lists.jboss.org</a>&quot; &lt;<a href="mailto:keycloak-user@lists.jboss.org" target="_blank">keycloak-user@lists.jboss.org</a>&gt;<br>
<span style="font-weight:bold">Subject: </span>Re: [keycloak-user] Extending Themes via SPI<br>
</div>
<div><br>
</div>
<div>
<div>
<div dir="ltr">What are you actually trying to achieve? We mainly support modifying the FreeMarker templates and stylesheets. Beyond that you may in theory be able to re-implement it all to replace FreeMarker with something else, but I don't see why you would
 want to and it would be a significant amount of work, and also maintenance.&nbsp;</div>
<div class="gmail_extra"><br>
<div class="gmail_quote">On 12 February 2016 at 07:08, Sarp Kaya <span dir="ltr">
&lt;<a href="mailto:akaya@expedia.com" target="_blank">akaya@expedia.com</a>&gt;</span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div style="word-wrap:break-word;color:rgb(0,0,0);font-size:14px;font-family:Calibri,sans-serif">
<div>Hi all,</div>
<div><br>
</div>
<div>In regards to Extending Themes via SPI all I found is this documentation:</div>
<div>
<div><a href="http://keycloak.github.io/docs/userguide/keycloak-server/html/providers.html" target="_blank">http://keycloak.github.io/docs/userguide/keycloak-server/html/providers.html</a>&nbsp;and&nbsp;</div>
<div><a href="http://keycloak.github.io/docs/userguide/keycloak-server/html/themes.html#d4e2450" target="_blank"></a></div>
<div><a href="http://keycloak.github.io/docs/userguide/keycloak-server/html/themes.html#d4e2450" target="_blank">http://keycloak.github.io/docs/userguide/keycloak-server/html/themes.html#d4e2450</a></div>
</div>
<div>I found it a little less describing.</div>
<div><br>
</div>
<div>When I implement those two classes, where do I put the new implemented classes? How do I deploy them?</div>
<div>Can I also use Spring mvc and JSP and few maven dependencies instead of freemarker?</div>
<div><br>
</div>
<div>I also tried to find an example to extend theme using SPI but there seems to be none. It would be really nice if you could provide a sample hello world.</div>
<div><br>
</div>
<div>Thank you very much,</div>
<div>Sarp Kaya</div>
</div>
<br>
_______________________________________________<br>
keycloak-user mailing list<br>
<a href="mailto:keycloak-user@lists.jboss.org" target="_blank">keycloak-user@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/keycloak-user" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/keycloak-user</a><br>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</span></div>
</div>
</span></div>
</div>
</div>
<br>
_______________________________________________<br>
keycloak-user mailing list<br>
<a href="mailto:keycloak-user@lists.jboss.org" target="_blank">keycloak-user@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/keycloak-user" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/keycloak-user</a><br>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</div>
</span></div>
</blockquote>
</div>
<br>
</div>
</div>
</div>
</span>
</body>
</html>