-
-
Notifications
You must be signed in to change notification settings - Fork 391
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
Persist session across subdomain #70
Comments
So the use case is you create a user for a newly created tenant website. A good solution would be to create a one time token that the identifies the user on the newly created Tenant website. Simply setting the session domain to allow for any subdomain will only solve this issue in the case of a subdomain set up. |
Yes, that's right. After a new user was created, I will login the user with Auth::login($user); Then a redirection to the user corresponding subdomain site. I am not sure if this will cause any security concern though. return redirect()->intended("http://" . $tenant_hostname . "/home"); |
That's fine for the single use case of working with subdomains. In any other case attempting to save a cookie/session for another domain has no effect. |
not going to do this, will consider some solution with the authentication feature for 3.x |
In order to make multi-tenancy to work with multiple subdomain, remember to configure config/session.php domain attribute to your domain name.
config/session.php
'domain' => '.lvh.me'
The text was updated successfully, but these errors were encountered: