Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

[5.x] New "Global Login" feature and fix auth redirects #325

Merged
merged 7 commits into from
Jan 17, 2024

Conversation

joelbutcher
Copy link
Owner

This PR addresses a number of things:

  1. It tightens security around login via a new 'global-login' feature. This is disabled by default, so apps that have previously supported logging users in from pages other than the "login" page will need to enable this feature before releasing
  2. It allows developers to define specific redirect paths for post login / registration:
    'redirects' => [
        'login' => RouteServiceProvider::HOME,
        'register' => RouteServiceProvider::HOME,
        'login-failed' => '/login',
        'registration-failed' => '/register',
        'provider-linked' => '/user/profile',
        'provider-link-failed' => '/user/profile',
    ],
  1. Resolves hardcoded to redirect to /dashboard if laravel breeze #322
  2. Refactors the AuthenticateOAuthCallback to improves readability and reduce complexity

@joelbutcher joelbutcher merged commit a1deace into 5.x Jan 17, 2024
61 checks passed
@joelbutcher joelbutcher deleted the fix/improve-auth-security-and-redirects branch January 17, 2024 13:36
@thumbtech
Copy link

Greetings ... FWIW this one broke my site hard since I have multitenant site using subdomains with redirect URI's coming back to base domain before hopping back to subdomain. Feature globalLogin did the trick, so all's well there ... I just think the docs need to catch up ... it took me a while to figure this out following the composer update!

What I'd like to understand is what is the actual security concern that was addressed here? Between the session and provider callbacks it would seem there is not much wiggle room. What is the (implied here) potential exploit available with globalLogin enabled?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

hardcoded to redirect to /dashboard if laravel breeze
2 participants