How to add a middleware to ALL admin routes? #860
Replies: 2 comments
-
Hello @enabled, as you named, Google 2FA is still not configured. Did you check if it is "enabled" on the config file? You can try to clear the config cache too.
or a full clear
Please let me know if this works for you or need any further assistance. Cheers. |
Beta Was this translation helpful? Give feedback.
0 replies
-
It was not a route problem. sorry simply, the user has a NULL google2fa_secret and so the midlleware skips the otp phase. Sorry |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
-
I need to apply a custom middleware to all and every single routes which are already under 'auth'.
My goal is to add google 2 factor authentication
i already have a middleware ready
In
app\Http\Kernel.php
I added a$middlewareAlias
then in
routes/backpack/custom.php
I tried to modify the middleware asBut It's liltterally doing nothing. As a bare minimum, I was expecting an error because I've not fully configured middleware and db
In the routes list I can see for examples
Is all done and should I check what happening in the middleware code or should I do something other to restrict admin routes ALSO under 2fa middleware?
Beta Was this translation helpful? Give feedback.
All reactions