Aprhont - Adding cookie-prefix, as config option, and into cookie methods

Summary: Cookie-prefix should fix phabricator instances where x.com and x.y.com have conflicting cookie names

Test Plan: Pushed branch to dev.phab.example.com, logged into phab.example.com and into dev.phab.example.com.

Reviewers: epriestley, #blessed_reviewers

Reviewed By: epriestley

CC: Korvin, epriestley, aran

Differential Revision: https://secure.phabricator.com/D7979
This commit is contained in:
Alex Arwine
2014-01-17 08:07:57 -08:00
committed by epriestley
parent c40420eb74
commit e6a6c265b0
3 changed files with 29 additions and 0 deletions

View File

@@ -107,9 +107,12 @@ class AphrontDefaultApplicationConfiguration
$data += $parser->parseQueryString(idx($_SERVER, 'QUERY_STRING', ''));
$cookie_prefix = PhabricatorEnv::getEnvConfig('phabricator.cookie-prefix');
$request = new AphrontRequest($this->getHost(), $this->getPath());
$request->setRequestData($data);
$request->setApplicationConfiguration($this);
$request->setCookiePrefix($cookie_prefix);
return $request;
}