Foren

Home » Liferay Portal » English » 3. Development

Kombinierte Ansicht Flache Ansicht Baumansicht
Threads [ Zurück | Nächste ]
Ravi Kiran
difference between login.events.pre and login.events.post
16. April 2012 11:18
Antwort

Ravi Kiran

Rang: Junior Member

Nachrichten: 53

Eintrittsdatum: 7. April 2012

Neue Beiträge

What is the difference between these two Startup Events

login.events.pre and login.events.post

Because when i developed a Liferay 6 Hookin and configured portal.properties files with these two .

Both of them has been called , only after clicking on Submit button on Default Liferay Login .

login.events.pre=com.sample.hook.LoginAction
login.events.post=com.sample.hook.LoginAction2
COuld this login.events.pre and login.events.post can be thought as Filters in Servlets ??
David H Nebinger
RE: difference between login.events.pre and login.events.post
16. April 2012 11:22
Antwort

David H Nebinger

Community Moderator

Rang: Liferay Legend

Nachrichten: 9460

Eintrittsdatum: 1. September 2006

Neue Beiträge

one is called before the actual login occurs (allows you to manipulate the info being used for the login request).

The other is called after the login occurs (allows you to audit a successful login or do whatever else you want).

No they are not like filters because they do not get called on every page, only during the login process.
Ravi Kiran
RE: difference between login.events.pre and login.events.post
16. April 2012 13:17
Antwort

Ravi Kiran

Rang: Junior Member

Nachrichten: 53

Eintrittsdatum: 7. April 2012

Neue Beiträge

That was very useful information .Thanks once again David.
Vincent CARNINO
RE: difference between login.events.pre and login.events.post
9. Oktober 2014 01:38
Antwort

Vincent CARNINO

Rang: Junior Member

Nachrichten: 41

Eintrittsdatum: 11. September 2014

Neue Beiträge

This is an old post but i have a similar question.

I tried to check some infos before users login but when i use "login.events.pre" property, the authentication process is already done (i have to check the user RemoteAddr before he may login). I tried to use the auth pipeline but i don't have access to this info in the Custom Authenticator class that i use.

Any idea ?
Raza Abbas
RE: difference between login.events.pre and login.events.post
6. April 2015 14:29
Antwort

Raza Abbas

Rang: New Member

Nachrichten: 1

Eintrittsdatum: 17. März 2015

Neue Beiträge

Hi,
I am new to liferay and working with version 6.2. I am seeing the seeing the same behavior as Vincent. The login.events.pre is called after successful login. Is this the desired behaviour. If yes, then can some one provide guidance as to how one would write a hook to be called before the login actually occurs.

Thanks
Raza
Vishal Kumar
RE: difference between login.events.pre and login.events.post
7. April 2015 04:11
Antwort

Vishal Kumar

Rang: Regular Member

Nachrichten: 198

Eintrittsdatum: 11. Dezember 2012

Neue Beiträge

Some action classes get called while performing some events in liferay.

- For Example:

- Login event :

login.events.pre : Called before get Login
- login.events.pre=com.liferay.portal.events.LoginPreAction


- login.events.post : Called after get Login
login.events.post=com.liferay.portal.events.ChannelLoginPostAction, com.liferay.portal.events.DefaultLandingPageAction,
com.liferay.portal.events.LoginPostAction