Commit 16b910ae by 杨树贤

cookie安全性

parent 81898104
......@@ -7,7 +7,7 @@ APP_URL=http://localhost
LOG_CHANNEL=stack
DB_CONNECTION=mysql
DB_HOST=master.db2.liexindev.me
DB_HOST=192.168.1.238
DB_PORT=3306
DB_DATABASE=semour
DB_USERNAME=semour
......@@ -27,7 +27,7 @@ MAIL_MAILER=smtp
MAIL_FROM_ADDRESS="system@semour.com"
MAIL_FROM_NAME="semour.com"
MAIL_DRIVER=smtp
MAIL_HOST='smtp.semour.com'
MAIL_HOST='smtp.mxhichina.com'
MAIL_PORT=25
MAIL_FROM='semour.com'
MAIL_USERNAME='system@semour.com'
......
......@@ -62,8 +62,7 @@ class AuthApiController extends Controller
if ($this->attemptLogin($request)) {
$request->session()->regenerate();
$cookie = Cookie::make('sem_email', Auth::user()->email, config('session.lifetime'), null, null, false,
false);
$cookie = Cookie::make('sem_email', Auth::user()->email, config('session.lifetime'));
Cookie::queue($cookie);
$userIdCookie = Cookie::make('sem_user_id', Auth::user()->id, config('session.lifetime'), null, null, false,
false);
......
......@@ -107,4 +107,5 @@ return [
],
],
];
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment