diff options
author | diosmosis <benaka@piwik.pro> | 2014-10-16 05:48:09 +0400 |
---|---|---|
committer | diosmosis <benaka@piwik.pro> | 2014-10-16 05:48:09 +0400 |
commit | cbc8714a9e281721e1e4ceddd7b9826339a1520a (patch) | |
tree | ca19db60b6a05921c51ec42e2311a5788284f10e /core | |
parent | 9b713ca17c7994ff9c75057a72e65e8d2b711d72 (diff) |
Moving CronArchive token auth check to archive script since it is only for when the archive.php script is invoked from a web request.
Diffstat (limited to 'core')
-rw-r--r-- | core/CronArchive.php | 20 |
1 files changed, 0 insertions, 20 deletions
diff --git a/core/CronArchive.php b/core/CronArchive.php index 47fbd7d3df..8549cbb8ea 100644 --- a/core/CronArchive.php +++ b/core/CronArchive.php @@ -854,26 +854,6 @@ class CronArchive } /** - * Script does run on http:// ONLY if the SU token is specified - */ - private function initCheckCli() - { - if (Common::isPhpCliMode()) { - return; - } - - $token_auth = Common::getRequestVar('token_auth', '', 'string'); - if ($token_auth !== $this->token_auth - || strlen($token_auth) != 32 - ) { - die('<b>You must specify the Super User token_auth as a parameter to this script, eg. <code>?token_auth=XYZ</code> if you wish to run this script through the browser. </b><br> - However it is recommended to run it <a href="http://piwik.org/docs/setup-auto-archiving/">via cron in the command line</a>, since it can take a long time to run.<br/> - In a shell, execute for example the following to trigger archiving on the local Piwik server:<br/> - <code>$ /path/to/php /path/to/piwik/console core:archive --url=http://your-website.org/path/to/piwik/</code>'); - } - } - - /** * Init Piwik, connect DB, create log & config objects, etc. */ private function initCore() |