Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
S
syncEnrollments
Project
Project
Details
Activity
Releases
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Yeray Santana Hualde
syncEnrollments
Commits
264cc512
Commit
264cc512
authored
Jan 05, 2012
by
Taylor Otwell
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed bug in auth cookie removal.
parent
2733e5ce
Changes
4
Show whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
24 additions
and
5 deletions
+24
-5
changelog.md
changelog.md
+8
-0
auth.php
laravel/auth.php
+9
-2
cookie.php
laravel/cookie.php
+6
-2
index.php
public/index.php
+1
-1
No files found.
changelog.md
View file @
264cc512
# Laravel Change Log
## Version 2.1.0
-
Fix: Authentication cookies are not deleted properly when custom domains or paths are used.
### Upgrading from 2.0.9
-
Replace
**laravel**
directory.
## Version 2.0.9
-
Minor: Made "timestamps" method in Eloquent model protected instead of private.
...
...
laravel/auth.php
View file @
264cc512
...
...
@@ -206,9 +206,16 @@ class Auth {
static
::
$user
=
null
;
Cookie
::
forget
(
Auth
::
user_key
);
$config
=
Config
::
get
(
'session'
);
extract
(
$config
,
EXTR_SKIP
);
// When forgetting the cookie, we need to also pass in the path and
// domain that would have been used when the cookie was originally
// set by the framework, otherwise it will not be deleted.
Cookie
::
forget
(
Auth
::
user_key
,
$path
,
$domain
,
$secure
);
Cookie
::
forget
(
Auth
::
remember_key
);
Cookie
::
forget
(
Auth
::
remember_key
,
$path
,
$domain
,
$secure
);
IoC
::
core
(
'session'
)
->
forget
(
Auth
::
user_key
);
}
...
...
laravel/cookie.php
View file @
264cc512
...
...
@@ -128,11 +128,15 @@ class Cookie {
* Delete a cookie.
*
* @param string $name
* @param string $path
* @param string $domain
* @param bool $secure
* @param bool $http_only
* @return bool
*/
public
static
function
forget
(
$name
)
public
static
function
forget
(
$name
,
$path
=
'/'
,
$domain
=
null
,
$secure
=
false
,
$http_only
=
false
)
{
return
static
::
put
(
$name
,
null
,
-
2000
);
return
static
::
put
(
$name
,
null
,
-
2000
,
$path
,
$domain
,
$secure
,
$http_only
);
}
}
\ No newline at end of file
public/index.php
View file @
264cc512
...
...
@@ -3,7 +3,7 @@
* Laravel - A PHP Framework For Web Artisans
*
* @package Laravel
* @version 2.
0.9
* @version 2.
1.0
* @author Taylor Otwell <taylorotwell@gmail.com>
* @link http://laravel.com
*/
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment