Skip to content

Check if we are in the "force_account_recovery" period #52

@malutanpetronel

Description

@malutanpetronel

There is a way to check if the login redirect is active... ? So after we have reached the number of failed logins to be able to redirect the user to a "too many login attempts" route / page where I would like to be able to output some message to make visitor aware why is it not able to see the login page again:

{% if ( 'admin/login' in app.request.headers.get('referer') ) or
( 'admin/dashboard' in app.request.headers.get('referer') ) %}

Too many login attempts


....

However first time the twig is displaying my message as the referer is the admin/login route ... in my case, but if I will refresh that landing page the message is no longer displayed... so can I check a session var or something to be able to accomplish this ?

Thank you for sharing your code

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions