I have extended these three classes to hook-in and perform a different action if certain conditions are met:
DefaultAuthenticationFailureHandler
DefaultAuthenticationSuccessHandler
DefaultLogoutSuccessHandler
Everything works great and they all use more or less the same code and services.yml configuration.
I now need to do exactly the same and hook-in to the event/class/whatever it is that performs the redirect when an attempt is made to access a page in the secure area.
So I don't need this for when they fail the login attempt (as one of the ones above does that), but I need to hook-in on when they access a page that's in the secure area and that then usually redirects to the login page (but I want to intercept that and perform an action before the redirect).
Ideally the answer would be something like this:
"Just extend the DefaultAuthenticationRequired class in the same way"
...but I don't think it's that easy