I noticed that the login route '/l/{urlstring}/{arg}' is being cached: using the same url twice (each time in a new anonymous window) the second time you are just redirected to the homepage in stead of being logged in.

This is easy to fix if you add the following option to the routing.yml for that route:

urllogin.login:
  path: '/l/{urlstring}/{arg}'
  defaults:
    _controller: '\Drupal\urllogin\Controller\UrlloginController::login'
    urlstring: ''
    arg: ''
  requirements:
    _permission: 'access content'
  options:
    no_cache: 'TRUE'

(so adding no_cache: 'TRUE')

solves the issue. I can now keep on logging in.

Comments

pieterdt created an issue. See original summary.

pieterdt’s picture

Title: login do not cache the login route » do not cache the login route