Jump to content

SessionLoginThrottle number of attempts


CarloC
 Share

Recommended Posts

I'm using the LoginRegister module and I'm getting an internal server error when I try to login with a wrong password more than one time.
I've found that the error comes from the SessionLoginThrottle.module, because, for security reasons, is better to prevent too many failed logins.

Ok, good. But, am I wrong if I think it's too bad to show an Internal server error to the user instead of a simple error in template saying the user to wait X seconds to retry to login?
Is there a way to do that? It would be great if I could get the error string and style it in the page the way I like.

And in the SessionLoginThrottle admin configuration, I think that could be a good idea to be able to change the maximum number of login attempts before the error is shown.

Link to comment
Share on other sites

Thank you for your answers

How should I use try and catch with the LoginRegister module? Or better where I should put that code? Because it's the module that handles the session login and I only use the $loginRegister->execute method in my template like in the module guide.

As soon as possible I will paste here my template code to give you a better idea of my situation.

Thank you

Link to comment
Share on other sites

  • 1 year later...

Hi,

I've found this topic due a hint from @Robin S here: 

One question is open to me: I'm wondering if it's possible to "manually create" an error in order to test if the code is running fine and everything works as expected? Could someone please give me a hint how to force the LoginRegister module to throw an error.

Many greets!

 

Link to comment
Share on other sites

1 hour ago, DV-JF said:

Could someone please give me a hint how to force the LoginRegister module to throw an error.

Attempt to log in via the LoginRegister module several times in short period of time using an incorrect password.

  • Like 2
Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
 Share

×
×
  • Create New...