Foros de discusión

liferay authentication

G R, modificado hace 8 años.

liferay authentication

New Member Mensajes: 13 Fecha de incorporación: 25/03/16 Mensajes recientes
HI,

1. I wanted to bypass the Liferay Auth and forward it for SSO auth to external server.
2. So to start with it first I implemented Liefray interface Authenticator. In it returns Authenticator.SUCCESS for all methods.
3. then I also updated and restart Liferay
portal-ext.properties for
auth.pipeline.pre=com.test.CustomAuth
auth.pipeline.enable.liferay.check=false

4. next when I hit the liferay UI, I am still prompted with login box where I enter the user and password mentioned as per property default.admin.password in portal-ext.properties.

please suggest if I miss any more things or need to do thing differently.
thumbnail
Bijan Vakili, modificado hace 8 años.

RE: liferay authentication

Expert Mensajes: 375 Fecha de incorporación: 10/03/09 Mensajes recientes
Hello G R,
Thanks for posting question.

So what you want is for it to "forward"; "and forward it for SSO auth to external server." To do this, you implement "CustomAuth." That will enable authenticating; though that does not enable the "forward." In order to "forward," you have choices. Look at LIferay implementation of:
- OpenSSOFilter on Github

It shows you how Liferay does the forward; for OpenSSO login option. Note the other piece to this in Liferay:
- OpenSSO AutoLogin class

For your custom Auth, you will need both parts: custom login and the "forward" parts too.

What you have done is a good start to this; though to achieve all goals, need some more code.
G R, modificado hace 8 años.

RE: liferay authentication

New Member Mensajes: 13 Fecha de incorporación: 25/03/16 Mensajes recientes
HI Bijan Vakili,

thanks very much for answering and pointers.

Another question i have "Authenticator Pipeline". I developed the Authenticator.. I send SAMLREsponse with POST method to Liferay url and I expect that SAMLResponse data to be available inside my custom pipeline. Is this possible ?[ I know that filter can be asked to listen to url and catch this data ]

I see that it exposed headerMap & parameterMap, but I do not see the content part.
headerMap
{content-length=[Ljava.lang.String;@6d2788ba, referer=[Ljava.lang.String;@21299879, accept-language=[Ljava.lang.String;@42eb5999, cookie=[Ljava.lang.String;@7c6277c9, origin=[Ljava.lang.String;@2a5142d7, accept=[Ljava.lang.String;@40b6fd54, host=[Ljava.lang.String;@68094246, upgrade-insecure-requests=[Ljava.lang.String;@37d9384a, connection=[Ljava.lang.String;@1039939c, content-type=[Ljava.lang.String;@67f2f095, cache-control=[Ljava.lang.String;@7513ec5e, accept-encoding=[Ljava.lang.String;@b76a9e1, user-agent=[Ljava.lang.String;@570f465f}

parameterMap
{redirect=[Ljava.lang.String;@27097273, saveLastPath=[Ljava.lang.String;@4d920bd0, password=[Ljava.lang.String;@75899a22, formDate=[Ljava.lang.String;@5e8507a1, rememberMe=[Ljava.lang.String;@32f37ce8, doActionAfterLogin=[Ljava.lang.String;@6fe22ded, login=[Ljava.lang.String;@30796eb9, struts_action=[Ljava.lang.String;@46b7df18}