IDEMPIERE-5346 SSO Support (#2046)
- Fix change role exception - Fix SSO breaking -H "X-PING: true"
This commit is contained in:
parent
c4e7e0abaa
commit
5506aa7ae4
|
@ -65,6 +65,14 @@ public class SSOWebUIFilter implements Filter
|
|||
HttpServletRequest httpRequest = (HttpServletRequest) request;
|
||||
HttpServletResponse httpResponse = (HttpServletResponse) response;
|
||||
|
||||
//handle ping request
|
||||
String ping = httpRequest.getHeader("X-PING");
|
||||
if (!Util.isEmpty(ping, true))
|
||||
{
|
||||
chain.doFilter(request, response);
|
||||
return;
|
||||
}
|
||||
|
||||
// Ignore the resource request
|
||||
if (SSOUtils.isResourceRequest(httpRequest, true))
|
||||
{
|
||||
|
|
|
@ -211,15 +211,7 @@ public class LoginWindow extends Window implements EventListener<Event>
|
|||
pnlRole = new RolePanel(ctx, this, userName, show, clientsKNPairs, isClientDefined);
|
||||
if (isSSOLogin)
|
||||
{
|
||||
this.addEventListener(SSOUtils.EVENT_ON_AFTER_SSOLOGIN, new EventListener<Event>() {
|
||||
|
||||
@Override
|
||||
public void onEvent(Event arg0) throws Exception
|
||||
{
|
||||
validateMFPanel(userName, show, clientsKNPairs, isClientDefined);
|
||||
}
|
||||
});
|
||||
Events.echoEvent(SSOUtils.EVENT_ON_AFTER_SSOLOGIN, this, null);
|
||||
Executions.schedule(getDesktop(), e -> validateMFPanel(userName, show, clientsKNPairs, isClientDefined), new Event(SSOUtils.EVENT_ON_AFTER_SSOLOGIN));
|
||||
}
|
||||
else
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue