<div dir="ltr"><div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99)"><div class="gmail_default">Yup... probably I configured something wrong, but I reviewed each step and couldn't find anything that seems not ok... Is there a way I can export the realm so you can see it?</div><div class="gmail_default">I'm attaching some images from the keycloak admin console that maybe can help...</div><div class="gmail_default"><br></div><div class="gmail_default"><img src="cid:ii_1529cc33be4d92ab" alt="Imagem inline 2" width="562" height="361"><img src="cid:ii_1529cc339da90ae1" alt="Imagem inline 1" width="562" height="281"><img src="cid:ii_1529cc33b2138c20" alt="Imagem inline 3" width="562" height="394"><br></div><div class="gmail_default"><br></div><div class="gmail_default">Thank you.</div><div class="gmail_default"><br></div><div class="gmail_default"><br></div><div class="gmail_default">PS: Mistakenly, I had sent this same message just for Mr. Burke.</div></div></div><div class="gmail_extra"><br clear="all"><div><div class="gmail_signature"><div style="text-align:left">Cordialmente.</div><div style="text-align:left">Alex Gouvêa Vasconcelos</div>mailto:<a href="mailto:alexgv99@gmail.com" target="_blank">alexgv99@gmail.com</a><br>MSN: <a href="mailto:alexgv99@hotmail.com" target="_blank">alexgv99@hotmail.com</a><br><div><a href="http://about.me/alexgv99" target="_blank">http://about.me/alexgv99</a></div><div><br></div></div></div>
<br><div class="gmail_quote">2016-01-28 14:12 GMT-02:00 Bill Burke <span dir="ltr"><<a href="mailto:bburke@redhat.com" target="_blank">bburke@redhat.com</a>></span>:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">
<div bgcolor="#FFFFFF" text="#000000">
Then you probably haven't set u the roles correctly for the user
that is logging in.<div><div class="h5"><br>
<br>
<div>On 1/28/2016 11:03 AM, Alex Gouvêa
Vasconcelos wrote:<br>
</div>
</div></div><blockquote type="cite"><div><div class="h5">
<div dir="ltr">
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99)">Sorry
guys, I'm not sure weather the group receive the answer to Mr.
Burke question about logs or not...</div>
<blockquote style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex" class="gmail_quote">
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99);display:inline"></div>
<span style="font-size:12.8px">Do you can an exception
stacktrace on app or auth server?</span><span style="color:rgb(7,55,99);font-family:verdana,sans-serif"></span></blockquote>
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99)">Anyway,
there's no log to share, here... the server.log file (in
Keycloak cluster - 2 instances) doesn't emit any line in the
process... and the Wildfly (where the app is deployed) just
say:</div>
<blockquote style="margin:0px 0px 0px 0.8ex;border-left-width:1px;border-left-color:rgb(204,204,204);border-left-style:solid;padding-left:1ex" class="gmail_quote">
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99);display:inline"></div>
<span style="color:rgb(0,0,0)">16:10:23,145 WARN
[org.keycloak.adapters.OAuthRequestAuthenticator]
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99);display:inline">
</div>
</span><span style="color:rgb(0,0,0)">(default task-66) No
state cookie</span><span style="color:rgb(7,55,99);font-family:verdana,sans-serif"></span></blockquote>
<div><br>
</div>
<div>
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99)">
So, I hope someone could help me here...</div>
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99)"><br>
</div>
<div class="gmail_default" style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99)">Thanks.
</div>
<br>
</div>
<br>
<div class="gmail_quote">---------- Forwarded message ----------<br>
From: <b class="gmail_sendername">Alex Gouvêa Vasconcelos</b>
<span dir="ltr"><<a href="mailto:alexgv99@gmail.com" target="_blank">alexgv99@gmail.com</a>></span><br>
Date: 2016-01-26 17:16 GMT-02:00<br>
Subject: Fwd: Bad Request<br>
To: <a href="mailto:keycloak-dev@lists.jboss.org" target="_blank">keycloak-dev@lists.jboss.org</a><br>
<br>
<br>
<div>
<div>
<div dir="ltr">
<div style="font-family:verdana,sans-serif;font-size:small;color:rgb(7,55,99)">Hi
guys. I'm running into some trouble here...<br>
</div>
<div class="gmail_quote">
<div dir="ltr">
<div>
<div><font color="#073763" face="verdana,
sans-serif"><br>
</font></div>
<div><font color="#073763" face="verdana,
sans-serif">I have a very simple application
which should authenticate against keycloak and
return to the main page. This is triggered
through the web.xml in my application.</font></div>
<div><font color="#073763" face="verdana,
sans-serif"><br>
</font></div>
</div>
<blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px">
<div>
<div><span style="color:rgb(7,55,99);font-family:monospace,monospace"><web-app
xmlns="<a href="http://java.sun.com/xml/ns/javaee" target="_blank">http://java.sun.com/xml/ns/javaee</a>"
xmlns:xsi="<a href="http://www.w3.org/2001/XMLSchema-instance" target="_blank">http://www.w3.org/2001/XMLSchema-instance</a>"</span></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span>xsi:schemaLocation="<a href="http://java.sun.com/xml/ns/javaee" target="_blank"></a><a href="http://java.sun.com/xml/ns/javaee" target="_blank">http://java.sun.com/xml/ns/javaee</a>
<a href="http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd" target="_blank">http://java.sun.com/xml/ns/javaee/web-app_3_0.xsd</a>"</font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span>version="3.0"></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span><module-name>teste</module-name></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span><filter></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><filter-name>CORSFilter</filter-name></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><filter-class>br.com.test.tms.teste.util.CORSFilter</filter-class></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span></filter></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span><filter-mapping></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><filter-name>CORSFilter</filter-name></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><url-pattern>/rest/*</url-pattern></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span></filter-mapping></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span><distributable
/></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span><security-constraint></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><web-resource-collection></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                        </span><web-resource-name>teste</web-resource-name></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                        </span><url-pattern>/rest/exemploService/secure/*</url-pattern></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span></web-resource-collection></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><auth-constraint></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                        </span><role-name>*</role-name></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span></auth-constraint></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><user-data-constraint></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                        </span><transport-guarantee>CONFIDENTIAL</transport-guarantee></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span></user-data-constraint></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span></security-constraint></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span><login-config></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><auth-method>KEYCLOAK</auth-method></font></div>
</div>
<div>
<div><span style="color:rgb(7,55,99);font-family:monospace,monospace;white-space:pre-wrap">                </span><span style="color:rgb(7,55,99);font-family:monospace,monospace"><realm-name>realmtest</realm-name></span></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span></login-config></font></div>
</div>
<div>
<div><span style="color:rgb(7,55,99);font-family:monospace,monospace;white-space:pre-wrap">        </span><span style="color:rgb(7,55,99);font-family:monospace,monospace"><security-role></span></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><role-name>user</role-name></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span></security-role></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span><security-role></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">                </span><role-name>admin</role-name></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><span style="white-space:pre-wrap">        </span></security-role></font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
</div>
<div>
<div><font color="#073763" face="monospace,
monospace"></web-app></font></div>
</div>
</blockquote>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
<div>
<div>
<div><font color="#073763" face="verdana,
sans-serif">The server side has a REST API
and the client side is an angular
application. Everything very simple to
just try the development environment. What
happens is that, after filling the login
page and return to the index.html
(actually it's not returning), I receive a
400 BAD REQUEST for the uri: </font></div>
<div><font color="#073763" face="verdana,
sans-serif"><br>
</font></div>
</div>
</div>
</div>
<blockquote style="margin:0px 0px 0px 40px;border:none;padding:0px">
<div>
<div>
<div>
<div><span style="color:rgb(7,55,99);font-family:monospace,monospace"><a href="http://localhost:8080/teste/?code=X8VlnUNxYzofJDHzkx1ZmMgO2BP0ZDJ-e2l7uB091Dk.bd5edab3-359b-4616-a403-34fffb427af9&state=67b87fd5-7cc0-4415-9b8b-fc16675229a1" target="_blank"></a><a href="http://localhost:8080/teste/?code=X8VlnUNxYzofJDHzkx1ZmMgO2BP0ZDJ-e2l7uB091Dk.bd5edab3-359b-4616-a403-34fffb427af9&state=67b87fd5-7cc0-4415-9b8b-fc16675229a1" target="_blank">http://localhost:8080/teste/?code=X8VlnUNxYzofJDHzkx1ZmMgO2BP0ZDJ-e2l7uB091Dk.bd5edab3-359b-4616-a403-34fffb427af9&state=67b87fd5-7cc0-4415-9b8b-fc16675229a1</a></span></div>
</div>
</div>
</div>
</blockquote>
<div>
<div><font color="#073763" face="monospace,
monospace"><br>
</font></div>
<div>
<div>
<div>
<div><font color="#073763" face="verdana,
sans-serif">It seems to me, that the
malformed URI is because of the
?code=... If I reload the page with the
same URL, it just return the same 400...
if I remove the ? portion, it reloads
the page and again redirects to and from
the keycloak server, and recovers the ?
portion, repeating the same 400. </font></div>
<div><font color="#073763" face="verdana,
sans-serif"><br>
</font></div>
<div><font color="#073763" face="verdana,
sans-serif">I'm running everything in
the same application under wildfly 10.
Both the server and client sides in the
same deployed WAR.</font></div>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)">I'd
appreciate any help.</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)">Best
regards.</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)">Alex
Gouvea Vasconcelos</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><img src="cid:part8.05020602.00000902@redhat.com" alt="Imagem inline 1" style="margin-right:0px" height="475" width="920"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
<div style="font-family:verdana,sans-serif;color:rgb(7,55,99)"><br>
</div>
</div>
</div>
</div>
</div>
</div>
<br>
</div>
</div>
</div>
</div>
<br>
</div>
<br>
<fieldset></fieldset>
<br>
</div></div><pre>_______________________________________________
keycloak-dev mailing list
<a href="mailto:keycloak-dev@lists.jboss.org" target="_blank">keycloak-dev@lists.jboss.org</a>
<a href="https://lists.jboss.org/mailman/listinfo/keycloak-dev" target="_blank">https://lists.jboss.org/mailman/listinfo/keycloak-dev</a></pre><span class="HOEnZb"><font color="#888888">
</font></span></blockquote><span class="HOEnZb"><font color="#888888">
<br>
<pre cols="72">--
Bill Burke
JBoss, a division of Red Hat
<a href="http://bill.burkecentral.com" target="_blank">http://bill.burkecentral.com</a></pre>
</font></span></div>
<br>_______________________________________________<br>
keycloak-dev mailing list<br>
<a href="mailto:keycloak-dev@lists.jboss.org">keycloak-dev@lists.jboss.org</a><br>
<a href="https://lists.jboss.org/mailman/listinfo/keycloak-dev" rel="noreferrer" target="_blank">https://lists.jboss.org/mailman/listinfo/keycloak-dev</a><br></blockquote></div><br></div>