Skip to content

Commit

Permalink
Merge pull request #1454 from nextcloud/morris
Browse files Browse the repository at this point in the history
Don't check Same-Site attribute for mobile chrome
  • Loading branch information
LukasReschke authored Sep 20, 2016
2 parents 70660d0 + 9a2511f commit 09e1218
Showing 1 changed file with 8 additions and 0 deletions.
8 changes: 8 additions & 0 deletions lib/base.php
Original file line number Diff line number Diff line change
Expand Up @@ -520,6 +520,14 @@ private static function performSameSiteCookieProtection() {
return;
}

// Chrome on Android has a bug that it doesn't sent cookies with the
// same-site attribute for the download manager. To work around that
// all same-site cookies get deleted and recreated directly. Awesome!
// FIXME: Remove once Chrome 54 is deployed to end-users
// @see https://github.com/nextcloud/server/pull/1454
if($request->isUserAgent([\OC\AppFramework\Http\Request::USER_AGENT_ANDROID_MOBILE_CHROME])) {
return;
}

if(count($_COOKIE) > 0) {
$requestUri = $request->getScriptName();
Expand Down

0 comments on commit 09e1218

Please sign in to comment.