From e4d1917616eb21ebdf35de1eda6fe5eb570f9981 Mon Sep 17 00:00:00 2001 From: nuxsmin Date: Fri, 9 Feb 2018 14:02:27 +0100 Subject: [PATCH] * [MOD] Improved bootstrapping. Work in progress. --- .../themes/material-blue/js/app-theme.min.js | 2 +- composer.json | 3 + composer.lock | 75 +- lib/SP/Account/AccountAcl.php | 5 +- lib/SP/Bootstrap.php | 214 +-- lib/SP/Config/ConfigUtil.php | 14 +- lib/SP/Core/CryptPKI.php | 36 +- lib/SP/Core/Language.php | 86 +- lib/SP/Core/Session/Session.php | 113 +- lib/SP/Storage/DBUtil.php | 19 +- lib/SP/Storage/XmlFileStorageInterface.php | 3 + lib/SP/Storage/XmlHandler.php | 12 +- public/js/app-actions.min.js | 2 +- public/js/app-main.min.js | 2 +- public/js/app-triggers.min.js | 2 +- vendor/autoload.php | 2 +- vendor/composer/ClassLoader.php | 4 +- vendor/composer/autoload_real.php | 14 +- vendor/composer/installed.json | 1202 +++++++++-------- 19 files changed, 1023 insertions(+), 787 deletions(-) diff --git a/app/modules/web/themes/material-blue/js/app-theme.min.js b/app/modules/web/themes/material-blue/js/app-theme.min.js index 116428f3..aab01417 100644 --- a/app/modules/web/themes/material-blue/js/app-theme.min.js +++ b/app/modules/web/themes/material-blue/js/app-theme.min.js @@ -1,5 +1,5 @@ var $jscomp={scope:{},findInternal:function(a,e,c){a instanceof String&&(a=String(a));for(var g=a.length,k=0;k"); a.passwordData.complexity.numbers&&(d+="1234567890");a.passwordData.complexity.chars&&(d+="abcdefghijklmnopqrstuvwxyz",a.passwordData.complexity.uppercase&&(d+="ABCDEFGHIJKLMNOPQRSTUVWXYZ"));for(;f++=2.14.2,<2.21.1", - "contao/core": ">=2,<3.5.31", + "contao/core": ">=2,<3.5.32", "contao/core-bundle": ">=4,<4.4.8", "contao/listing-bundle": ">=4,<4.4.8", + "contao/newsletter-bundle": ">=4,<4.1", "doctrine/annotations": ">=1,<1.2.7", "doctrine/cache": ">=1,<1.3.2|>=1.4,<1.4.2", "doctrine/common": ">=2,<2.4.3|>=2.5,<2.5.1", @@ -1063,13 +1064,13 @@ "phpxmlrpc/extras": "<0.6.1", "pusher/pusher-php-server": "<2.2.1", "sabre/dav": ">=1.6,<1.6.99|>=1.7,<1.7.11|>=1.8,<1.8.9", - "shopware/shopware": "<5.2.25", + "shopware/shopware": "<5.3.7", "silverstripe/cms": ">=3,<=3.0.11|>=3.1,<3.1.11", "silverstripe/forum": "<=0.6.1|>=0.7,<=0.7.3", "silverstripe/framework": ">=3,<3.3", "silverstripe/userforms": "<3", - "simplesamlphp/saml2": "<1.8.1|>=1.9,<1.9.1|>=1.10,<1.10.3|>=2,<2.3.3", - "simplesamlphp/simplesamlphp": "<1.14.16", + "simplesamlphp/saml2": "<1.10.4|>=2,<2.3.5|>=3,<3.1.1", + "simplesamlphp/simplesamlphp": "<1.15.2", "simplesamlphp/simplesamlphp-module-infocard": "<1.0.1", "socalnick/scn-social-auth": "<1.15.2", "squizlabs/php_codesniffer": ">=1,<2.8.1", @@ -1092,7 +1093,7 @@ "symfony/web-profiler-bundle": ">=2,<2.3.19|>=2.4,<2.4.9|>=2.5,<2.5.4", "symfony/yaml": ">=2,<2.0.22|>=2.1,<2.1.7", "thelia/backoffice-default-template": ">=2.1,<2.1.2", - "thelia/thelia": ">=2.1,<2.1.2|>=2.1.0-beta1,<2.1.3", + "thelia/thelia": ">=2.1.0-beta1,<2.1.3|>=2.1,<2.1.2", "twig/twig": "<1.20", "typo3/cms": ">=6.2,<6.2.30|>=7,<7.6.22|>=8,<8.7.5", "typo3/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.10|>=3.1,<3.1.7|>=3.2,<3.2.7|>=3.3,<3.3.5", @@ -1141,10 +1142,62 @@ } ], "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it", - "time": "2018-01-13T18:31:46+00:00" + "time": "2018-02-04T22:09:50+00:00" + } + ], + "packages-dev": [ + { + "name": "squizlabs/php_codesniffer", + "version": "3.2.2", + "source": { + "type": "git", + "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", + "reference": "d7c00c3000ac0ce79c96fcbfef86b49a71158cd1" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/d7c00c3000ac0ce79c96fcbfef86b49a71158cd1", + "reference": "d7c00c3000ac0ce79c96fcbfef86b49a71158cd1", + "shasum": "" + }, + "require": { + "ext-simplexml": "*", + "ext-tokenizer": "*", + "ext-xmlwriter": "*", + "php": ">=5.4.0" + }, + "require-dev": { + "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0" + }, + "bin": [ + "bin/phpcs", + "bin/phpcbf" + ], + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "3.x-dev" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "BSD-3-Clause" + ], + "authors": [ + { + "name": "Greg Sherwood", + "role": "lead" + } + ], + "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.", + "homepage": "http://www.squizlabs.com/php-codesniffer", + "keywords": [ + "phpcs", + "standards" + ], + "time": "2017-12-19T21:44:46+00:00" } ], - "packages-dev": [], "aliases": [], "minimum-stability": "stable", "stability-flags": { diff --git a/lib/SP/Account/AccountAcl.php b/lib/SP/Account/AccountAcl.php index 6189b30c..39111478 100644 --- a/lib/SP/Account/AccountAcl.php +++ b/lib/SP/Account/AccountAcl.php @@ -30,7 +30,6 @@ use SP\Core\Acl\ActionsInterface; use SP\Core\Session\Session; use SP\Core\Traits\InjectableTrait; use SP\DataModel\Dto\AccountAclDto; -use SP\DataModel\UserData; use SP\Repositories\UserGroup\UserToUserGroupRepository; use SP\Services\User\UserLoginResponse; use SP\Util\ArrayUtil; @@ -164,9 +163,10 @@ class AccountAcl /** * AccountAcl constructor. * - * @param int $action + * @param int $action * @param bool $isHistory * @throws \SP\Core\Dic\ContainerException + * @throws \ReflectionException */ public function __construct($action, $isHistory = false) { @@ -607,6 +607,7 @@ class AccountAcl * @return void * @link http://php.net/manual/en/language.oop5.magic.php#language.oop5.magic.sleep * @throws \SP\Core\Dic\ContainerException + * @throws \ReflectionException */ public function __wakeup() { diff --git a/lib/SP/Bootstrap.php b/lib/SP/Bootstrap.php index 8d6d80b0..b4368939 100644 --- a/lib/SP/Bootstrap.php +++ b/lib/SP/Bootstrap.php @@ -31,7 +31,6 @@ use Interop\Container\ContainerInterface; use Klein\Klein; use PHPMailer\PHPMailer\Exception; use RuntimeException; -use SP\Account\AccountAcl; use SP\Config\Config; use SP\Config\ConfigData; use SP\Config\ConfigUtil; @@ -57,6 +56,7 @@ use SP\Mgmt\Profiles\Profile; use SP\Modules\Web\Controllers\MainController; use SP\Mvc\View\Template; use SP\Providers\Auth\Browser\Browser; +use SP\Storage\Database; use SP\Storage\DBUtil; use SP\Util\Checks; use SP\Util\HttpUtil; @@ -106,10 +106,6 @@ class Bootstrap * @var bool Indica si la versión de PHP es correcta */ private static $checkPhpVersion; - /** - * @var bool Indica si el script requiere inicialización - */ - private static $checkInitSourceInclude; /** * @var string */ @@ -130,6 +126,10 @@ class Bootstrap * @var Klein */ protected $router; + /** + * @var Language + */ + protected $language; /** * @var Config */ @@ -187,11 +187,12 @@ class Bootstrap /** @var Exception|\Throwable $err */ debugLog('Routing error: ' . formatTrace($err->getTrace())); + + /** @var Klein $router */ + $router->response()->body($err_msg); }); try { - $self->initialize(); - /** @var \Klein\Request $request */ $route = filter_var($request->param('r', 'index/index'), FILTER_SANITIZE_STRING); @@ -222,6 +223,8 @@ class Bootstrap throw new RuntimeException("Oops, it looks like this content doesn't exist...\n"); } + $self->initialize(); + debugLog('Routing call: ' . $controllerClass . '::' . $method . '::' . print_r($params, true)); return call_user_func_array($callableMethod, $params); @@ -251,31 +254,28 @@ class Bootstrap * @throws SPException * @throws \Psr\Container\ContainerExceptionInterface */ - public function initialize() + protected function initialize() { - self::$checkPhpVersion = Checks::checkPhpVersion(); - self::$checkInitSourceInclude = $this->checkInitSourceInclude(); + debugLog('Initializing ...'); - if (date_default_timezone_get() === 'UTC') { - date_default_timezone_set('UTC'); - } + self::$checkPhpVersion = Checks::checkPhpVersion(); // Inicializar autentificación $this->initAuthVariables(); // Inicializar logging - $this->initLogging(); + $this->initPHPVars(); + + // Establecer las rutas de la aplicación + $this->initPaths(); // Cargar las extensiones // self::loadExtensions(); // Establecer el lenguaje por defecto - Language::setLocales('en_US'); + $this->language->setLocales('en_US'); - // Establecer las rutas de la aplicación - $this->initPaths(); - - if (!self::$checkPhpVersion && !self::$checkInitSourceInclude) { + if (!self::$checkPhpVersion) { throw new InitializationException( __u('Versión de PHP requerida >= ') . ' 5.6.0 <= 7.0', SPException::ERROR, @@ -295,20 +295,20 @@ class Bootstrap $this->config->loadConfig(); // Cargar el lenguaje - Language::setLanguage(); + $this->language->setLanguage(); } else { // Cargar la configuración $this->config->loadConfig(true); // Restablecer el idioma y el tema visual - Language::setLanguage(true); + $this->language->setLanguage(true); $this->theme->initTheme(true); if ($this->session->isLoggedIn()) { // Recargar los permisos del perfil de usuario $this->session->setUserProfile(Profile::getItem()->getById($this->session->getUserData()->getUserProfileId())); // Reset de los datos de ACL de cuentas - AccountAcl::resetData(); + $this->session->resetAccountAcl(); } } @@ -316,7 +316,9 @@ class Bootstrap HttpUtil::checkHttps(); // Comprobar si es necesario inicialización - if ((defined('IS_INSTALLER') || defined('IS_UPGRADE')) && Checks::isAjax($this->router)) { + if ((defined('IS_INSTALLER') || defined('IS_UPGRADE')) + && Checks::isAjax($this->router) + ) { return; } @@ -327,7 +329,7 @@ class Bootstrap $this->checkMaintenanceMode(); // Comprobar si la Base de datos existe - DBUtil::checkDatabaseExist(); + DBUtil::checkDatabaseExist(self::$container->get(Database::class), $this->configData->getDbName()); // Comprobar si es necesario actualizar componentes // $this->checkUpgrade(); @@ -342,32 +344,16 @@ class Bootstrap // $this->checkPreLoginActions(); if ($this->session->isLoggedIn() && $this->session->getAuthCompleted() === true) { - $AuthBrowser = new Browser(); + $browser = new Browser(); // Comprobar si se ha identificado mediante el servidor web y el usuario coincide - if ($AuthBrowser->checkServerAuthUser($this->session->getUserData()->getLogin()) === false - && $AuthBrowser->checkServerAuthUser($this->session->getUserData()->getSsoLogin()) === false + if ($browser->checkServerAuthUser($this->session->getUserData()->getLogin()) === false + && $browser->checkServerAuthUser($this->session->getUserData()->getSsoLogin()) === false ) { throw new InitializationException('Logout'); // $this->goLogout(); } } - - // El usuario no está logado y no es una petición, redirigir al login -// $this->goLogin(); - } - - /** - * Comprobar el archivo que realiza el include necesita inicialización. - * - * @returns bool - */ - private function checkInitSourceInclude() - { - self::$sourceScript = pathinfo($_SERVER['SCRIPT_NAME'], PATHINFO_BASENAME); - $skipInit = ['js.php', 'css.php', 'api.php', 'ajax_getEnvironment.php', 'ajax_task.php']; - - return in_array(self::$sourceScript, $skipInit, true); } /** @@ -375,34 +361,31 @@ class Bootstrap */ private function initAuthVariables() { + $server = $this->router->request()->server(); + // Copiar la cabecera http de autentificación para apache+php-fcgid - if (isset($_SERVER['HTTP_XAUTHORIZATION']) && !isset($_SERVER['HTTP_AUTHORIZATION'])) { - $_SERVER['HTTP_AUTHORIZATION'] = $_SERVER['HTTP_XAUTHORIZATION']; + if ($server->get('HTTP_XAUTHORIZATION') !== null + && $server->get('HTTP_AUTHORIZATION') === null) { + $server->set('HTTP_AUTHORIZATION', $server->get('HTTP_XAUTHORIZATION')); } // Establecer las cabeceras de autentificación para apache+php-cgi - if (isset($_SERVER['HTTP_AUTHORIZATION']) - && preg_match('/Basic\s+(.*)$/i', $_SERVER['HTTP_AUTHORIZATION'], $matches) - ) { - list($name, $password) = explode(':', base64_decode($matches[1]), 2); - $_SERVER['PHP_AUTH_USER'] = strip_tags($name); - $_SERVER['PHP_AUTH_PW'] = strip_tags($password); - } - // Establecer las cabeceras de autentificación para que apache+php-cgi funcione si la variable es renombrada por apache - if (isset($_SERVER['REDIRECT_HTTP_AUTHORIZATION']) - && preg_match('/Basic\s+(.*)$/i', $_SERVER['REDIRECT_HTTP_AUTHORIZATION'], $matches) + if (($server->get('HTTP_AUTHORIZATION') !== null + && preg_match('/Basic\s+(.*)$/i', $server->get('HTTP_AUTHORIZATION'), $matches)) + || ($server->get('REDIRECT_HTTP_AUTHORIZATION') !== null + && preg_match('/Basic\s+(.*)$/i', $server->get('REDIRECT_HTTP_AUTHORIZATION'), $matches)) ) { list($name, $password) = explode(':', base64_decode($matches[1]), 2); - $_SERVER['PHP_AUTH_USER'] = strip_tags($name); - $_SERVER['PHP_AUTH_PW'] = strip_tags($password); + $server->set('PHP_AUTH_USER', strip_tags($name)); + $server->set('PHP_AUTH_PW', strip_tags($password)); } } /** * Establecer el nivel de logging */ - public function initLogging() + public function initPHPVars() { // Establecer el modo debug si una sesión de xdebug está activa if (isset($_COOKIE['XDEBUG_SESSION']) && !defined('DEBUG')) { @@ -420,6 +403,14 @@ class Bootstrap if (!file_exists(LOG_FILE) && touch(LOG_FILE) && chmod(LOG_FILE, 0600)) { debugLog('Setup log file: ' . LOG_FILE); } + + if (date_default_timezone_get() === 'UTC') { + date_default_timezone_set('UTC'); + } + + // Evita que javascript acceda a las cookies de sesion de PHP + ini_set('session.cookie_httponly', '1'); + ini_set('session.save_handler', 'files'); } /** @@ -469,9 +460,7 @@ class Bootstrap // Comprobar si es una versión antigua $this->checkConfigVersion(); - if (!self::$checkInitSourceInclude) { - ConfigUtil::checkConfigDir(); - } + ConfigUtil::checkConfigDir(); } /** @@ -481,7 +470,9 @@ class Bootstrap { $appVersion = Util::getVersionStringNormalized(); - if (file_exists(OLD_CONFIG_FILE) && $this->upgrade->upgradeOldConfigFile($appVersion)) { + if (file_exists(OLD_CONFIG_FILE) + && $this->upgrade->upgradeOldConfigFile($appVersion) + ) { // $this->logConfigUpgrade($appVersion); self::$UPDATED = true; @@ -510,14 +501,8 @@ class Bootstrap */ private function initSession($encrypt = false) { - // Evita que javascript acceda a las cookies de sesion de PHP - ini_set('session.cookie_httponly', '1'); - ini_set('session.save_handler', 'files'); - if ($encrypt === true) { - $key = SecureKeyCookie::getKey(); - - if ($key !== false && self::$checkPhpVersion) { + if (($key = SecureKeyCookie::getKey()) !== false && self::$checkPhpVersion) { session_set_save_handler(new CryptSessionHandler($key), true); } } @@ -593,8 +578,6 @@ class Bootstrap throw new InitializationException(__u('Aplicación en mantenimiento'), SPException::INFO, __u('En breve estará operativa')); } - - return false; } /** @@ -603,7 +586,7 @@ class Bootstrap */ private function initUserSession() { - $lastActivity = SessionFactory::getLastActivity(); + $lastActivity = $this->session->getLastActivity(); $inMaintenance = $this->configData->isMaintenance(); // Timeout de sesión @@ -615,21 +598,21 @@ class Bootstrap $this->router->response()->cookie(session_name(), '', time() - 42000); } - $this->wrLogoutInfo(); +// $this->wrLogoutInfo(); SessionUtil::restart(); return; } - $sidStartTime = SessionFactory::getSidStartTime(); + $sidStartTime = $this->session->getSidStartTime(); // Regenerar el Id de sesión periódicamente para evitar fijación if ($sidStartTime === 0) { // Intentar establecer el tiempo de vida de la sesión en PHP @ini_set('session.gc_maxlifetime', $this->getSessionLifeTime()); - SessionFactory::setSidStartTime(time()); - SessionFactory::setStartActivity(time()); + $this->session->setSidStartTime(time()); + $this->session->setStartActivity(time()); } else if (!$inMaintenance && time() - $sidStartTime > 120 && $this->session->getUserData()->getId() > 0 @@ -647,7 +630,7 @@ class Bootstrap } } - SessionFactory::setLastActivity(time()); + $this->session->setLastActivity(time()); } /** @@ -657,11 +640,11 @@ class Bootstrap */ private function getSessionLifeTime() { - $timeout = SessionFactory::getSessionTimeout(); + $timeout = $this->session->getSessionTimeout(); if (null === $timeout) { $configTimeout = $this->configData->getSessionTimeout(); - SessionFactory::setSessionTimeout($configTimeout); + $this->session->setSessionTimeout($configTimeout); return $configTimeout; } @@ -669,23 +652,6 @@ class Bootstrap return $timeout; } - /** - * Escribir la información de logout en el registro de eventos. - */ - private function wrLogoutInfo() - { - $inactiveTime = abs(round((time() - SessionFactory::getLastActivity()) / 60, 2)); - $totalTime = abs(round((time() - SessionFactory::getStartActivity()) / 60, 2)); - - $Log = new Log(); - $LogMessage = $Log->getLogMessage(); - $LogMessage->setAction(__('Finalizar sesión', false)); - $LogMessage->addDetails(__('Usuario', false), $this->session->getUserData()->getLogin()); - $LogMessage->addDetails(__('Tiempo inactivo', false), $inactiveTime . ' min.'); - $LogMessage->addDetails(__('Tiempo total', false), $totalTime . ' min.'); - $Log->writeLog(); - } - /** * @return ContainerInterface */ @@ -698,8 +664,8 @@ class Bootstrap * Devuelve un error utilizando la plantilla de error o en formato JSON * * @param string $message con la descripción del error - * @param string $hint opcional, con una ayuda sobre el error - * @param bool $headers + * @param string $hint opcional, con una ayuda sobre el error + * @param bool $headers */ public static function initError($message, $hint = '', $headers = false) { @@ -762,13 +728,20 @@ class Bootstrap } /** - * @param Config $config + * @param Config $config * @param Upgrade $upgrade * @param Session $session - * @param Theme $theme - * @param Klein $router + * @param Theme $theme + * @param Klein $router + * @param Language $language */ - public function inject(Config $config, Upgrade $upgrade, Session $session, Theme $theme, Klein $router) + public function inject(Config $config, + Upgrade $upgrade, + Session $session, + Theme $theme, + Klein $router, + Language $language + ) { $this->config = $config; $this->configData = $config->getConfigData(); @@ -776,6 +749,7 @@ class Bootstrap $this->session = $session; $this->theme = $theme; $this->router = $router; + $this->language = $language; } /** @@ -797,6 +771,20 @@ class Bootstrap return true; } + /** + * Comprobar el archivo que realiza el include necesita inicialización. + * + * @deprecated + * @returns bool + */ + private function checkInitSourceInclude() + { + self::$sourceScript = pathinfo($_SERVER['SCRIPT_NAME'], PATHINFO_BASENAME); + $skipInit = ['js.php', 'css.php', 'api.php', 'ajax_getEnvironment.php', 'ajax_task.php']; + + return in_array(self::$sourceScript, $skipInit, true); + } + /** * Comprobar si es necesario actualizar componentes * @@ -813,6 +801,7 @@ class Bootstrap /** * Registrar la actualización de la configuración * + * @deprecated * @param $version */ private function logConfigUpgrade($version) @@ -840,6 +829,8 @@ class Bootstrap /** * Deslogar el usuario actual y eliminar la información de sesión. + * + * @deprecated */ private function goLogout() { @@ -852,4 +843,23 @@ class Bootstrap $Controller = new MainController(); $Controller->getLogout(); } + + /** + * Escribir la información de logout en el registro de eventos. + * + * @deprecated + */ + private function wrLogoutInfo() + { + $inactiveTime = abs(round((time() - $this->session->getLastActivity()) / 60, 2)); + $totalTime = abs(round((time() - $this->session->getStartActivity()) / 60, 2)); + + $Log = new Log(); + $LogMessage = $Log->getLogMessage(); + $LogMessage->setAction(__('Finalizar sesión', false)); + $LogMessage->addDetails(__('Usuario', false), $this->session->getUserData()->getLogin()); + $LogMessage->addDetails(__('Tiempo inactivo', false), $inactiveTime . ' min.'); + $LogMessage->addDetails(__('Tiempo total', false), $totalTime . ' min.'); + $Log->writeLog(); + } } \ No newline at end of file diff --git a/lib/SP/Config/ConfigUtil.php b/lib/SP/Config/ConfigUtil.php index 91a92f43..d792d225 100644 --- a/lib/SP/Config/ConfigUtil.php +++ b/lib/SP/Config/ConfigUtil.php @@ -64,24 +64,24 @@ class ConfigUtil if (!is_dir(CONFIG_PATH)) { clearstatcache(); - throw new ConfigException(ConfigException::CRITICAL, __('El directorio "/config" no existe', false)); + throw new ConfigException(__u('El directorio "/config" no existe'), ConfigException::CRITICAL); } if (!is_writable(CONFIG_PATH)) { clearstatcache(); - throw new ConfigException(ConfigException::CRITICAL, __('No es posible escribir en el directorio "config"', false)); + throw new ConfigException(__u('No es posible escribir en el directorio "config"'), ConfigException::CRITICAL); } - $configPerms = decoct(fileperms(CONFIG_PATH) & 0777); - - if ($configPerms !== '750' && !Checks::checkIsWindows()) { + if (!Checks::checkIsWindows() + && ($configPerms = decoct(fileperms(CONFIG_PATH) & 0777)) !== '750' + ) { clearstatcache(); throw new ConfigException( + __u('Los permisos del directorio "/config" son incorrectos'), ConfigException::ERROR, - __('Los permisos del directorio "/config" son incorrectos', false), - __('Actual:', false) . ' ' . $configPerms . ' - ' . __('Necesario: 750', false)); + sprintf(__u('Actual: %s - Necesario: 750'), $configPerms)); } } } \ No newline at end of file diff --git a/lib/SP/Core/CryptPKI.php b/lib/SP/Core/CryptPKI.php index e9ee7a8c..c178d217 100644 --- a/lib/SP/Core/CryptPKI.php +++ b/lib/SP/Core/CryptPKI.php @@ -29,6 +29,7 @@ defined('APP_ROOT') || die(); use phpseclib\Crypt\RSA; use SP\Core\Exceptions\FileNotFoundException; use SP\Core\Exceptions\SPException; +use SP\Core\Traits\InjectableTrait; use SP\Log\Log; /** @@ -38,11 +39,21 @@ use SP\Log\Log; */ class CryptPKI { + use InjectableTrait; + + /** + * @var RSA + */ + protected $rsa; + /** * @throws SPException + * @throws Dic\ContainerException */ public function __construct() { + $this->injectDependencies(); + if (!file_exists($this->getPublicKeyFile()) || !file_exists($this->getPrivateKeyFile())) { if (!$this->createKeys()) { throw new SPException(__('No es posible generar las claves RSA', false), SPException::CRITICAL); @@ -50,6 +61,14 @@ class CryptPKI } } + /** + * @param RSA $rsa + */ + public function inject(RSA $rsa) + { + $this->rsa = $rsa; + } + /** * Devuelve la ruta al archivo de la clave pública * @@ -75,8 +94,7 @@ class CryptPKI */ public function createKeys() { - $Rsa = new RSA(); - $keys = $Rsa->createKey(1024); + $keys = $this->rsa->createKey(1024); $priv = file_put_contents($this->getPrivateKeyFile(), $keys['privatekey']); $pub = file_put_contents($this->getPublicKeyFile(), $keys['publickey']); @@ -95,11 +113,10 @@ class CryptPKI */ public function encryptRSA($data) { - $Rsa = new RSA(); - $Rsa->setEncryptionMode(RSA::ENCRYPTION_PKCS1); - $Rsa->loadKey($this->getPublicKey()); + $this->rsa->setEncryptionMode(RSA::ENCRYPTION_PKCS1); + $this->rsa->loadKey($this->getPublicKey()); - return $Rsa->encrypt($data); + return $this->rsa->encrypt($data); } /** @@ -130,11 +147,10 @@ class CryptPKI */ public function decryptRSA($data) { - $Rsa = new RSA(); - $Rsa->setEncryptionMode(RSA::ENCRYPTION_PKCS1); - $Rsa->loadKey($this->getPrivateKey()); + $this->rsa->setEncryptionMode(RSA::ENCRYPTION_PKCS1); + $this->rsa->loadKey($this->getPrivateKey()); - return $Rsa->decrypt($data); + return $this->rsa->decrypt($data); } /** diff --git a/lib/SP/Core/Language.php b/lib/SP/Core/Language.php index 52014843..6ca75ee3 100644 --- a/lib/SP/Core/Language.php +++ b/lib/SP/Core/Language.php @@ -80,9 +80,34 @@ class Language $this->injectDependencies(); } + /** + * Devolver los lenguajes disponibles + * + * @return array + */ + public static function getAvailableLanguages() + { + $langs = [ + 'Español' => 'es_ES', + 'Catalá' => 'ca_ES', + 'English' => 'en_US', + 'Deutsch' => 'de_DE', + 'Magyar' => 'hu_HU', + 'Français' => 'fr_FR', + 'Polski' => 'po_PO', + 'русский' => 'ru_RU', + 'Nederlands' => 'nl_NL', + 'Português' => 'pt_BR' + ]; + + ksort($langs); + + return $langs; + } + /** * @param Session $session - * @param Config $config + * @param Config $config */ public function inject(Session $session, Config $config) { @@ -95,23 +120,20 @@ class Language * * @param bool $force Forzar la detección del lenguaje para los inicios de sesión */ - public static function setLanguage($force = false) + public function setLanguage($force = false) { - $lang = SessionFactory::getLocale(); + $lang = $this->session->getLocale(); if (empty($lang) || $force === true) { - $language = new Language(); - - self::$userLang = $language->getUserLang(); - self::$globalLang = $language->getGlobalLang(); + self::$userLang = $this->getUserLang(); + self::$globalLang = $this->getGlobalLang(); $lang = self::$userLang ?: self::$globalLang; - SessionFactory::setLocale($lang); + $this->session->setLocale($lang); } - - self::setLocales($lang); + $this->setLocales($lang); } /** @@ -157,11 +179,7 @@ class Language { $lang = Request::getRequestHeaders('HTTP_ACCEPT_LANGUAGE'); - if ($lang) { - return str_replace('-', '_', substr($lang, 0, 5)); - } - - return ''; + return $lang ? str_replace('-', '_', substr($lang, 0, 5)) : ''; } /** @@ -180,51 +198,28 @@ class Language * * @param string $lang El lenguaje a utilizar */ - public static function setLocales($lang) + public function setLocales($lang) { $lang .= '.utf8'; $fallback = 'en_US.utf8'; - putenv('LANG=' . $lang); self::$localeStatus = setlocale(LC_MESSAGES, [$lang, $fallback]); + + putenv('LANG=' . $lang); setlocale(LC_ALL, [$lang, $fallback]); bindtextdomain('messages', LOCALES_PATH); textdomain('messages'); bind_textdomain_codeset('messages', 'UTF-8'); } - /** - * Devolver los lenguajes disponibles - * - * @return array - */ - public static function getAvailableLanguages() - { - $langs = [ - 'Español' => 'es_ES', - 'Catalá' => 'ca_ES', - 'English' => 'en_US', - 'Deutsch' => 'de_DE', - 'Magyar' => 'hu_HU', - 'Français' => 'fr_FR', - 'Polski' => 'po_PO', - 'русский' => 'ru_RU', - 'Nederlands' => 'nl_NL', - 'Português' => 'pt_BR' - ]; - - ksort($langs); - - return $langs; - } - /** * Establecer el lenguaje global para las traducciones */ public function setAppLocales() { - if ($this->configData->getSiteLang() !== SessionFactory::getLocale()) { - self::setLocales($this->configData->getSiteLang()); + if ($this->configData->getSiteLang() !== $this->session->getLocale()) { + $this->setLocales($this->configData->getSiteLang()); + self::$appSet = true; } } @@ -235,7 +230,8 @@ class Language public function unsetAppLocales() { if (self::$appSet === true) { - self::setLocales(SessionFactory::getLocale()); + $this->setLocales($this->session->getLocale()); + self::$appSet = false; } } diff --git a/lib/SP/Core/Session/Session.php b/lib/SP/Core/Session/Session.php index b59f0b18..4d4aa5db 100644 --- a/lib/SP/Core/Session/Session.php +++ b/lib/SP/Core/Session/Session.php @@ -51,7 +51,7 @@ class Session * Devolver una variable de sesión * * @param string $key - * @param mixed $default + * @param mixed $default * @return mixed */ protected function getSessionKey($key, $default = null) @@ -76,8 +76,8 @@ class Session /** * Establecer una variable de sesión * - * @param string $key El nombre de la variable - * @param mixed $value El valor de la variable + * @param string $key El nombre de la variable + * @param mixed $value El valor de la variable * @return mixed */ protected function setSessionKey($key, $value) @@ -189,6 +189,11 @@ class Session return null; } + public function resetAccountAcl() + { + $this->setSessionKey('accountAcl', null); + } + /** * Returns if user is logged in * @@ -304,4 +309,104 @@ class Session { $this->setSessionKey('pubkey', $key); } -} \ No newline at end of file + + /** + * Devuelve el timeout de la sesión + * + * @return int|null El valor en segundos + */ + public function getSessionTimeout() + { + return $this->getSessionKey('sessionTimeout'); + } + + /** + * Establecer el timeout de la sesión + * + * @param int $timeout El valor en segundos + */ + public function setSessionTimeout($timeout) + { + $this->setSessionKey('sessionTimeout', $timeout); + } + + /** + * Devuelve la hora de la última actividad + * + * @return int + */ + public function getLastActivity() + { + return $this->getSessionKey('lastActivity', 0); + } + + /** + * Establece la hora de la última actividad + * + * @param $time int La marca de hora + */ + public function setLastActivity($time) + { + $this->setSessionKey('lastActivity', $time); + } + + /** + * Devuelve la hora en la que el SID de sesión fue creado + * + * @return int + */ + public function getSidStartTime() + { + return $this->getSessionKey('sidStartTime', 0); + } + + /** + * Establece la hora de creación del SID + * + * @param $time int La marca de hora + */ + public function setSidStartTime($time) + { + $this->setSessionKey('sidStartTime', $time); + } + + /** + * Devuelve la hora de inicio de actividad. + * + * @return int + */ + public function getStartActivity() + { + return $this->getSessionKey('startActivity', 0); + } + + /** + * Establece la hora de inicio de actividad + * + * @param $time int La marca de hora + */ + public function setStartActivity($time) + { + $this->setSessionKey('startActivity', $time); + } + + /** + * Establecer el lenguaje de la sesión + * + * @param $locale + */ + public function setLocale($locale) + { + $this->setSessionKey('locale', $locale); + } + + /** + * Devuelve el lenguaje de la sesión + * + * @return string + */ + public function getLocale() + { + return $this->getSessionKey('locale'); + } +} diff --git a/lib/SP/Storage/DBUtil.php b/lib/SP/Storage/DBUtil.php index ffb849e9..84f00fab 100644 --- a/lib/SP/Storage/DBUtil.php +++ b/lib/SP/Storage/DBUtil.php @@ -26,8 +26,6 @@ namespace SP\Storage; use RuntimeException; -use SP\Bootstrap; -use SP\Config\ConfigData; use SP\Core\DiFactory; use SP\Core\Exceptions\SPException; @@ -110,7 +108,7 @@ class DBUtil foreach ($attributes as $val) { $dbinfo[$val] = $db->getAttribute(constant('PDO::ATTR_' . $val)); } - } catch (SPException $e) { + } catch (\Exception $e) { return $dbinfo; } @@ -120,25 +118,20 @@ class DBUtil /** * Comprobar que la base de datos existe. * + * @param DatabaseInterface $database + * @param string $dbName * @return bool - * @throws \Psr\Container\ContainerExceptionInterface */ - public static function checkDatabaseExist() + public static function checkDatabaseExist(DatabaseInterface $database, $dbName) { - $dic = Bootstrap::getContainer(); - /** @var Database $Db */ - $Db = $dic->get(Database::class); - /** @var ConfigData $ConfigData */ - $ConfigData = $dic->get(ConfigData::class); - try { $query = /** @lang SQL */ 'SELECT COUNT(*) FROM information_schema.tables - WHERE table_schema = \'' . $ConfigData->getDbName() . '\' + WHERE table_schema = \'' . $dbName . '\' AND table_name IN (\'Client\', \'Category\', \'Account\', \'User\', \'Config\', \'EventLog\')'; - return (int)$Db->getDbHandler()->getConnection()->query($query)->fetchColumn() === 6; + return (int)$database->getDbHandler()->getConnection()->query($query)->fetchColumn() === 6; } catch (\Exception $e) { debugLog($e->getMessage()); debugLog($e->getCode()); diff --git a/lib/SP/Storage/XmlFileStorageInterface.php b/lib/SP/Storage/XmlFileStorageInterface.php index 2abcac50..afad9634 100644 --- a/lib/SP/Storage/XmlFileStorageInterface.php +++ b/lib/SP/Storage/XmlFileStorageInterface.php @@ -24,6 +24,8 @@ namespace SP\Storage; +use SP\Core\Exceptions\FileNotFoundException; + /** * Interface StorageInterface * @@ -35,6 +37,7 @@ interface XmlFileStorageInterface * @param string $node * * @return XmlFileStorageInterface + * @throws FileNotFoundException */ public function load($node = ''); diff --git a/lib/SP/Storage/XmlHandler.php b/lib/SP/Storage/XmlHandler.php index 574ec2ce..b5dbc16b 100644 --- a/lib/SP/Storage/XmlHandler.php +++ b/lib/SP/Storage/XmlHandler.php @@ -30,6 +30,8 @@ use DOMNode; use DOMNodeList; use ReflectionObject; use RuntimeException; +use SP\Core\Exceptions\FileNotFoundException; +use SP\Core\Exceptions\SPException; /** * Class XmlHandler para manejo básico de documentos XML @@ -70,12 +72,12 @@ class XmlHandler implements XmlFileStorageInterface * * @param string $node * @return XmlFileStorageInterface - * @throws \RuntimeException + * @throws FileNotFoundException */ public function load($node = 'root') { if (!$this->checkSourceFile()) { - throw new RuntimeException(sprintf(__('No es posible leer/escribir el archivo: %s', false), $this->file)); + throw new FileNotFoundException(SPException::SP_ERROR, sprintf(__('No es posible leer/escribir el archivo: %s', false), $this->file)); } $this->setDOM(); @@ -180,9 +182,9 @@ class XmlHandler implements XmlFileStorageInterface /** * Crear los nodos hijos recursivamente a partir de un array multidimensional * - * @param mixed $items + * @param mixed $items * @param DOMNode $Node - * @param null $type + * @param null $type */ protected function writeChildNodes($items, DOMNode $Node, $type = null) { @@ -211,7 +213,7 @@ class XmlHandler implements XmlFileStorageInterface * Analizar el tipo de elementos * * @param mixed $items - * @param bool $serialize + * @param bool $serialize * @return array */ protected function analyzeItems($items, $serialize = false) diff --git a/public/js/app-actions.min.js b/public/js/app-actions.min.js index 36226805..69142e59 100644 --- a/public/js/app-actions.min.js +++ b/public/js/app-actions.min.js @@ -1,5 +1,5 @@ var $jscomp={scope:{},findInternal:function(c,k,e){c instanceof String&&(c=String(c));for(var l=c.length,f=0;f";mdlDialog().show({text:b,negative:{title:c.config().LANG[44],onClick:function(a){a.preventDefault();c.msg.error(c.config().LANG[44])}},positive:{title:c.config().LANG[43],onClick:function(b){b=c.appRequests().getRequestOpts();b.url=f.account.save;b.data={r:"account/saveDelete/"+a.data("item-id"),sk:c.sk.get()};c.appRequests().getActionCall(b,function(a){c.msg.out(a);k.search()})}}})},viewPass:function(a){e.info("account:showpass");var b=a.data("parent-id")||0,b=0=== diff --git a/public/js/app-main.min.js b/public/js/app-main.min.js index 5ba76f92..cff0f6f3 100644 --- a/public/js/app-main.min.js +++ b/public/js/app-main.min.js @@ -1,5 +1,5 @@ var $jscomp={scope:{},findInternal:function(b,k,l){b instanceof String&&(b=String(b));for(var m=b.length,n=0;nprefixDirsPsr4[$search])) { + $pathEnd = DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $lastPos + 1); foreach ($this->prefixDirsPsr4[$search] as $dir) { - $length = $this->prefixLengthsPsr4[$first][$search]; - if (file_exists($file = $dir . DIRECTORY_SEPARATOR . substr($logicalPathPsr4, $length))) { + if (file_exists($file = $dir . $pathEnd)) { return $file; } } diff --git a/vendor/composer/autoload_real.php b/vendor/composer/autoload_real.php index eb929c68..d19dbc63 100644 --- a/vendor/composer/autoload_real.php +++ b/vendor/composer/autoload_real.php @@ -2,7 +2,7 @@ // autoload_real.php @generated by Composer -class ComposerAutoloaderInit1701764f82c629b16cc164189600cb41 +class ComposerAutoloaderInitb174c89ce62ffa56cba5b414933da45e { private static $loader; @@ -19,15 +19,15 @@ class ComposerAutoloaderInit1701764f82c629b16cc164189600cb41 return self::$loader; } - spl_autoload_register(array('ComposerAutoloaderInit1701764f82c629b16cc164189600cb41', 'loadClassLoader'), true, true); + spl_autoload_register(array('ComposerAutoloaderInitb174c89ce62ffa56cba5b414933da45e', 'loadClassLoader'), true, true); self::$loader = $loader = new \Composer\Autoload\ClassLoader(); - spl_autoload_unregister(array('ComposerAutoloaderInit1701764f82c629b16cc164189600cb41', 'loadClassLoader')); + spl_autoload_unregister(array('ComposerAutoloaderInitb174c89ce62ffa56cba5b414933da45e', 'loadClassLoader')); $useStaticLoader = PHP_VERSION_ID >= 50600 && !defined('HHVM_VERSION') && (!function_exists('zend_loader_file_encoded') || !zend_loader_file_encoded()); if ($useStaticLoader) { require_once __DIR__ . '/autoload_static.php'; - call_user_func(\Composer\Autoload\ComposerStaticInit1701764f82c629b16cc164189600cb41::getInitializer($loader)); + call_user_func(\Composer\Autoload\ComposerStaticInitb174c89ce62ffa56cba5b414933da45e::getInitializer($loader)); } else { $map = require __DIR__ . '/autoload_namespaces.php'; foreach ($map as $namespace => $path) { @@ -48,19 +48,19 @@ class ComposerAutoloaderInit1701764f82c629b16cc164189600cb41 $loader->register(true); if ($useStaticLoader) { - $includeFiles = Composer\Autoload\ComposerStaticInit1701764f82c629b16cc164189600cb41::$files; + $includeFiles = Composer\Autoload\ComposerStaticInitb174c89ce62ffa56cba5b414933da45e::$files; } else { $includeFiles = require __DIR__ . '/autoload_files.php'; } foreach ($includeFiles as $fileIdentifier => $file) { - composerRequire1701764f82c629b16cc164189600cb41($fileIdentifier, $file); + composerRequireb174c89ce62ffa56cba5b414933da45e($fileIdentifier, $file); } return $loader; } } -function composerRequire1701764f82c629b16cc164189600cb41($fileIdentifier, $file) +function composerRequireb174c89ce62ffa56cba5b414933da45e($fileIdentifier, $file) { if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) { require $file; diff --git a/vendor/composer/installed.json b/vendor/composer/installed.json index 9f13df05..f9e00e7f 100644 --- a/vendor/composer/installed.json +++ b/vendor/composer/installed.json @@ -46,6 +46,39 @@ "rfc4648" ] }, + { + "name": "container-interop/container-interop", + "version": "1.2.0", + "version_normalized": "1.2.0.0", + "source": { + "type": "git", + "url": "https://github.com/container-interop/container-interop.git", + "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/container-interop/container-interop/zipball/79cbf1341c22ec75643d841642dd5d6acd83bdb8", + "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8", + "shasum": "" + }, + "require": { + "psr/container": "^1.0" + }, + "time": "2017-02-14T19:40:03+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-4": { + "Interop\\Container\\": "src/Interop/Container/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "Promoting the interoperability of container objects (DIC, SL, etc.)", + "homepage": "https://github.com/container-interop/container-interop" + }, { "name": "defuse/php-encryption", "version": "v2.1.0", @@ -112,36 +145,40 @@ ] }, { - "name": "paragonie/random_compat", - "version": "v2.0.11", - "version_normalized": "2.0.11.0", + "name": "doctrine/annotations", + "version": "v1.4.0", + "version_normalized": "1.4.0.0", "source": { "type": "git", - "url": "https://github.com/paragonie/random_compat.git", - "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8" + "url": "https://github.com/doctrine/annotations.git", + "reference": "54cacc9b81758b14e3ce750f205a393d52339e97" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/paragonie/random_compat/zipball/5da4d3c796c275c55f057af5a643ae297d96b4d8", - "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8", + "url": "https://api.github.com/repos/doctrine/annotations/zipball/54cacc9b81758b14e3ce750f205a393d52339e97", + "reference": "54cacc9b81758b14e3ce750f205a393d52339e97", "shasum": "" }, "require": { - "php": ">=5.2.0" + "doctrine/lexer": "1.*", + "php": "^5.6 || ^7.0" }, "require-dev": { - "phpunit/phpunit": "4.*|5.*" + "doctrine/cache": "1.*", + "phpunit/phpunit": "^5.7" }, - "suggest": { - "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." - }, - "time": "2017-09-27T21:40:39+00:00", + "time": "2017-02-24T16:22:25+00:00", "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.4.x-dev" + } + }, "installation-source": "dist", "autoload": { - "files": [ - "lib/random.php" - ] + "psr-4": { + "Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations" + } }, "notification-url": "https://packagist.org/downloads/", "license": [ @@ -149,37 +186,338 @@ ], "authors": [ { - "name": "Paragon Initiative Enterprises", - "email": "security@paragonie.com", - "homepage": "https://paragonie.com" + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" } ], - "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", + "description": "Docblock Annotations Parser", + "homepage": "http://www.doctrine-project.org", "keywords": [ - "csprng", - "pseudorandom", - "random" + "annotations", + "docblock", + "parser" ] }, { - "name": "psr/container", - "version": "1.0.0", - "version_normalized": "1.0.0.0", + "name": "doctrine/cache", + "version": "v1.6.2", + "version_normalized": "1.6.2.0", "source": { "type": "git", - "url": "https://github.com/php-fig/container.git", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" + "url": "https://github.com/doctrine/cache.git", + "reference": "eb152c5100571c7a45470ff2a35095ab3f3b900b" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/php-fig/container/zipball/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", - "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", + "url": "https://api.github.com/repos/doctrine/cache/zipball/eb152c5100571c7a45470ff2a35095ab3f3b900b", + "reference": "eb152c5100571c7a45470ff2a35095ab3f3b900b", "shasum": "" }, "require": { - "php": ">=5.3.0" + "php": "~5.5|~7.0" }, - "time": "2017-02-14T16:28:37+00:00", + "conflict": { + "doctrine/common": ">2.2,<2.4" + }, + "require-dev": { + "phpunit/phpunit": "~4.8|~5.0", + "predis/predis": "~1.0", + "satooshi/php-coveralls": "~0.6" + }, + "time": "2017-07-22T12:49:21+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.6.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "Doctrine\\Common\\Cache\\": "lib/Doctrine/Common/Cache" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" + } + ], + "description": "Caching library offering an object-oriented API for many cache backends", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "cache", + "caching" + ] + }, + { + "name": "doctrine/collections", + "version": "v1.4.0", + "version_normalized": "1.4.0.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/collections.git", + "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/collections/zipball/1a4fb7e902202c33cce8c55989b945612943c2ba", + "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba", + "shasum": "" + }, + "require": { + "php": "^5.6 || ^7.0" + }, + "require-dev": { + "doctrine/coding-standard": "~0.1@dev", + "phpunit/phpunit": "^5.7" + }, + "time": "2017-01-03T10:49:41+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.3.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-0": { + "Doctrine\\Common\\Collections\\": "lib/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" + } + ], + "description": "Collections Abstraction library", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "array", + "collections", + "iterator" + ] + }, + { + "name": "doctrine/common", + "version": "v2.7.3", + "version_normalized": "2.7.3.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/common.git", + "reference": "4acb8f89626baafede6ee5475bc5844096eba8a9" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/common/zipball/4acb8f89626baafede6ee5475bc5844096eba8a9", + "reference": "4acb8f89626baafede6ee5475bc5844096eba8a9", + "shasum": "" + }, + "require": { + "doctrine/annotations": "1.*", + "doctrine/cache": "1.*", + "doctrine/collections": "1.*", + "doctrine/inflector": "1.*", + "doctrine/lexer": "1.*", + "php": "~5.6|~7.0" + }, + "require-dev": { + "phpunit/phpunit": "^5.4.6" + }, + "time": "2017-07-22T08:35:12+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "2.7.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-4": { + "Doctrine\\Common\\": "lib/Doctrine/Common" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" + } + ], + "description": "Common Library for Doctrine projects", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "annotations", + "collections", + "eventmanager", + "persistence", + "spl" + ] + }, + { + "name": "doctrine/inflector", + "version": "v1.1.0", + "version_normalized": "1.1.0.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/inflector.git", + "reference": "90b2128806bfde671b6952ab8bea493942c1fdae" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/inflector/zipball/90b2128806bfde671b6952ab8bea493942c1fdae", + "reference": "90b2128806bfde671b6952ab8bea493942c1fdae", + "shasum": "" + }, + "require": { + "php": ">=5.3.2" + }, + "require-dev": { + "phpunit/phpunit": "4.*" + }, + "time": "2015-11-06T14:35:42+00:00", + "type": "library", + "extra": { + "branch-alias": { + "dev-master": "1.1.x-dev" + } + }, + "installation-source": "dist", + "autoload": { + "psr-0": { + "Doctrine\\Common\\Inflector\\": "lib/" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "authors": [ + { + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Benjamin Eberlei", + "email": "kontakt@beberlei.de" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Jonathan Wage", + "email": "jonwage@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" + } + ], + "description": "Common String Manipulations with regard to casing and singular/plural rules.", + "homepage": "http://www.doctrine-project.org", + "keywords": [ + "inflection", + "pluralize", + "singularize", + "string" + ] + }, + { + "name": "doctrine/lexer", + "version": "v1.0.1", + "version_normalized": "1.0.1.0", + "source": { + "type": "git", + "url": "https://github.com/doctrine/lexer.git", + "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/doctrine/lexer/zipball/83893c552fd2045dd78aef794c31e694c37c0b8c", + "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c", + "shasum": "" + }, + "require": { + "php": ">=5.3.2" + }, + "time": "2014-09-09T13:34:57+00:00", "type": "library", "extra": { "branch-alias": { @@ -188,8 +526,8 @@ }, "installation-source": "dist", "autoload": { - "psr-4": { - "Psr\\Container\\": "src/" + "psr-0": { + "Doctrine\\Common\\Lexer\\": "lib/" } }, "notification-url": "https://packagist.org/downloads/", @@ -198,18 +536,23 @@ ], "authors": [ { - "name": "PHP-FIG", - "homepage": "http://www.php-fig.org/" + "name": "Roman Borschel", + "email": "roman@code-factory.org" + }, + { + "name": "Guilherme Blanco", + "email": "guilhermeblanco@gmail.com" + }, + { + "name": "Johannes Schmitt", + "email": "schmittjoh@gmail.com" } ], - "description": "Common Container Interface (PHP FIG PSR-11)", - "homepage": "https://github.com/php-fig/container", + "description": "Base library for a lexer that can be used in Top-Down, Recursive Descent Parsers.", + "homepage": "http://www.doctrine-project.org", "keywords": [ - "PSR-11", - "container", - "container-interface", - "container-interop", - "psr" + "lexer", + "parser" ] }, { @@ -271,223 +614,55 @@ ] }, { - "name": "roave/security-advisories", - "version": "dev-master", - "version_normalized": "9999999-dev", + "name": "paragonie/random_compat", + "version": "v2.0.11", + "version_normalized": "2.0.11.0", "source": { "type": "git", - "url": "https://github.com/Roave/SecurityAdvisories.git", - "reference": "a54d4cf91890993ee599c446e2eb3dba3f9eae32" + "url": "https://github.com/paragonie/random_compat.git", + "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/a54d4cf91890993ee599c446e2eb3dba3f9eae32", - "reference": "a54d4cf91890993ee599c446e2eb3dba3f9eae32", + "url": "https://api.github.com/repos/paragonie/random_compat/zipball/5da4d3c796c275c55f057af5a643ae297d96b4d8", + "reference": "5da4d3c796c275c55f057af5a643ae297d96b4d8", "shasum": "" }, - "conflict": { - "adodb/adodb-php": "<5.20.6", - "amphp/artax": "<1.0.6|>=2,<2.0.6", - "aws/aws-sdk-php": ">=3,<3.2.1", - "bugsnag/bugsnag-laravel": ">=2,<2.0.2", - "cakephp/cakephp": ">=1.3,<1.3.18|>=2,<2.4.99|>=2.5,<2.5.99|>=2.6,<2.6.12|>=2.7,<2.7.6|>=3,<3.0.15|>=3.1,<3.1.4", - "cart2quote/module-quotation": ">=4.1.6,<=4.4.5|>=5,<5.4.4", - "cartalyst/sentry": "<=2.1.6", - "codeigniter/framework": "<=3.0.6", - "composer/composer": "<=1.0.0-alpha11", - "contao-components/mediaelement": ">=2.14.2,<2.21.1", - "contao/core": ">=2,<3.5.31", - "contao/core-bundle": ">=4,<4.4.8", - "contao/listing-bundle": ">=4,<4.4.8", - "doctrine/annotations": ">=1,<1.2.7", - "doctrine/cache": ">=1,<1.3.2|>=1.4,<1.4.2", - "doctrine/common": ">=2,<2.4.3|>=2.5,<2.5.1", - "doctrine/dbal": ">=2,<2.0.8|>=2.1,<2.1.2", - "doctrine/doctrine-bundle": "<1.5.2", - "doctrine/doctrine-module": "<=0.7.1", - "doctrine/mongodb-odm": ">=1,<1.0.2", - "doctrine/mongodb-odm-bundle": ">=2,<3.0.1", - "doctrine/orm": ">=2,<2.4.8|>=2.5,<2.5.1", - "dompdf/dompdf": ">=0.6,<0.6.2", - "drupal/core": ">=8,<8.3.7", - "drupal/drupal": ">=8,<8.3.7", - "ezsystems/ezpublish-legacy": ">=5.3,<5.3.12.2|>=5.4,<5.4.10.1|>=2017.8,<2017.8.1.1", - "firebase/php-jwt": "<2", - "friendsofsymfony/rest-bundle": ">=1.2,<1.2.2", - "friendsofsymfony/user-bundle": ">=1.2,<1.3.5", - "gree/jose": "<=2.2", - "gregwar/rst": "<1.0.3", - "guzzlehttp/guzzle": ">=6,<6.2.1|>=4.0.0-rc2,<4.2.4|>=5,<5.3.1", - "illuminate/auth": ">=4,<4.0.99|>=4.1,<4.1.26", - "illuminate/database": ">=4,<4.0.99|>=4.1,<4.1.29", - "joomla/session": "<1.3.1", - "laravel/framework": ">=4,<4.0.99|>=4.1,<4.1.29", - "laravel/socialite": ">=1,<1.0.99|>=2,<2.0.10", - "magento/magento1ce": ">=1.5.0.1,<1.9.3.2", - "magento/magento1ee": ">=1.9,<1.14.3.2", - "magento/magento2ce": ">=2,<2.2", - "monolog/monolog": ">=1.8,<1.12", - "namshi/jose": "<2.2", - "onelogin/php-saml": "<2.10.4", - "oro/crm": ">=1.7,<1.7.4", - "oro/platform": ">=1.7,<1.7.4", - "phpmailer/phpmailer": ">=5,<5.2.24", - "phpunit/phpunit": ">=4.8.19,<4.8.28|>=5.0.10,<5.6.3", - "phpxmlrpc/extras": "<0.6.1", - "pusher/pusher-php-server": "<2.2.1", - "sabre/dav": ">=1.6,<1.6.99|>=1.7,<1.7.11|>=1.8,<1.8.9", - "shopware/shopware": "<5.2.25", - "silverstripe/cms": ">=3,<=3.0.11|>=3.1,<3.1.11", - "silverstripe/forum": "<=0.6.1|>=0.7,<=0.7.3", - "silverstripe/framework": ">=3,<3.3", - "silverstripe/userforms": "<3", - "simplesamlphp/saml2": "<1.8.1|>=1.9,<1.9.1|>=1.10,<1.10.3|>=2,<2.3.3", - "simplesamlphp/simplesamlphp": "<1.14.16", - "simplesamlphp/simplesamlphp-module-infocard": "<1.0.1", - "socalnick/scn-social-auth": "<1.15.2", - "squizlabs/php_codesniffer": ">=1,<2.8.1", - "swiftmailer/swiftmailer": ">=4,<5.4.5", - "symfony/dependency-injection": ">=2,<2.0.17", - "symfony/form": ">=2.3,<2.3.35|>=2.4,<2.6.12|>=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", - "symfony/framework-bundle": ">=2,<2.3.18|>=2.4,<2.4.8|>=2.5,<2.5.2", - "symfony/http-foundation": ">=2,<2.3.27|>=2.4,<2.5.11|>=2.6,<2.6.6", - "symfony/http-kernel": ">=2,<2.3.29|>=2.4,<2.5.12|>=2.6,<2.6.8", - "symfony/intl": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", - "symfony/routing": ">=2,<2.0.19", - "symfony/security": ">=2,<2.0.25|>=2.1,<2.1.13|>=2.2,<2.2.9|>=2.3,<2.3.37|>=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8.23,<2.8.25|>=3.2.10,<3.2.12|>=3.3.3,<3.3.5", - "symfony/security-core": ">=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8,<2.8.6|>=2.8.23,<2.8.25|>=3,<3.0.6|>=3.2.10,<3.2.12|>=3.3.3,<3.3.5", - "symfony/security-csrf": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", - "symfony/security-http": ">=2.3,<2.3.41|>=2.4,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", - "symfony/serializer": ">=2,<2.0.11", - "symfony/symfony": ">=2,<2.3.41|>=2.4,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", - "symfony/translation": ">=2,<2.0.17", - "symfony/validator": ">=2,<2.0.24|>=2.1,<2.1.12|>=2.2,<2.2.5|>=2.3,<2.3.3", - "symfony/web-profiler-bundle": ">=2,<2.3.19|>=2.4,<2.4.9|>=2.5,<2.5.4", - "symfony/yaml": ">=2,<2.0.22|>=2.1,<2.1.7", - "thelia/backoffice-default-template": ">=2.1,<2.1.2", - "thelia/thelia": ">=2.1,<2.1.2|>=2.1.0-beta1,<2.1.3", - "twig/twig": "<1.20", - "typo3/cms": ">=6.2,<6.2.30|>=7,<7.6.22|>=8,<8.7.5", - "typo3/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.10|>=3.1,<3.1.7|>=3.2,<3.2.7|>=3.3,<3.3.5", - "typo3/neos": ">=1.1,<1.1.3|>=1.2,<1.2.13|>=2,<2.0.4", - "willdurand/js-translation-bundle": "<2.1.1", - "yiisoft/yii": ">=1.1.14,<1.1.15", - "yiisoft/yii2": "<2.0.5", - "yiisoft/yii2-bootstrap": "<2.0.4", - "yiisoft/yii2-dev": "<2.0.4", - "yiisoft/yii2-gii": "<2.0.4", - "yiisoft/yii2-jui": "<2.0.4", - "zendframework/zend-cache": ">=2.4,<2.4.8|>=2.5,<2.5.3", - "zendframework/zend-captcha": ">=2,<2.4.9|>=2.5,<2.5.2", - "zendframework/zend-crypt": ">=2,<2.4.9|>=2.5,<2.5.2", - "zendframework/zend-db": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.10|>=2.3,<2.3.5", - "zendframework/zend-diactoros": ">=1,<1.0.4", - "zendframework/zend-form": ">=2,<2.2.7|>=2.3,<2.3.1", - "zendframework/zend-http": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.3,<2.3.8|>=2.4,<2.4.1", - "zendframework/zend-json": ">=2.1,<2.1.6|>=2.2,<2.2.6", - "zendframework/zend-ldap": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.8|>=2.3,<2.3.3", - "zendframework/zend-mail": ">=2,<2.4.11|>=2.5,<2.7.2", - "zendframework/zend-navigation": ">=2,<2.2.7|>=2.3,<2.3.1", - "zendframework/zend-session": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.9|>=2.3,<2.3.4", - "zendframework/zend-validator": ">=2.3,<2.3.6", - "zendframework/zend-view": ">=2,<2.2.7|>=2.3,<2.3.1", - "zendframework/zend-xmlrpc": ">=2.1,<2.1.6|>=2.2,<2.2.6", - "zendframework/zendframework": ">=2,<2.4.11|>=2.5,<2.5.1", - "zendframework/zendframework1": "<1.12.20", - "zendframework/zendopenid": ">=2,<2.0.2", - "zendframework/zendxml": ">=1,<1.0.1", - "zetacomponents/mail": "<1.8.2", - "zf-commons/zfc-user": "<1.2.2", - "zfcampus/zf-apigility-doctrine": ">=1,<1.0.3", - "zfr/zfr-oauth2-server-module": "<0.1.2" + "require": { + "php": ">=5.2.0" + }, + "require-dev": { + "phpunit/phpunit": "4.*|5.*" + }, + "suggest": { + "ext-libsodium": "Provides a modern crypto API that can be used to generate random bytes." + }, + "time": "2017-09-27T21:40:39+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "files": [ + "lib/random.php" + ] }, - "time": "2018-01-13T18:31:46+00:00", - "type": "metapackage", "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], "authors": [ { - "name": "Marco Pivetta", - "email": "ocramius@gmail.com", - "role": "maintainer" + "name": "Paragon Initiative Enterprises", + "email": "security@paragonie.com", + "homepage": "https://paragonie.com" } ], - "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it" - }, - { - "name": "php-di/phpdoc-reader", - "version": "2.0.1", - "version_normalized": "2.0.1.0", - "source": { - "type": "git", - "url": "https://github.com/PHP-DI/PhpDocReader.git", - "reference": "83f5ead159defccfa8e7092e5b6c1c533b326d68" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/PHP-DI/PhpDocReader/zipball/83f5ead159defccfa8e7092e5b6c1c533b326d68", - "reference": "83f5ead159defccfa8e7092e5b6c1c533b326d68", - "shasum": "" - }, - "require": { - "php": ">=5.3.0" - }, - "require-dev": { - "phpunit/phpunit": "~4.6" - }, - "time": "2015-11-29T10:34:25+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "psr-4": { - "PhpDocReader\\": "src/PhpDocReader" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "PhpDocReader parses @var and @param values in PHP docblocks (supports namespaced class names with the same resolution rules as PHP)", + "description": "PHP 5.x polyfill for random_bytes() and random_int() from PHP 7", "keywords": [ - "phpdoc", - "reflection" + "csprng", + "pseudorandom", + "random" ] }, - { - "name": "container-interop/container-interop", - "version": "1.2.0", - "version_normalized": "1.2.0.0", - "source": { - "type": "git", - "url": "https://github.com/container-interop/container-interop.git", - "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/container-interop/container-interop/zipball/79cbf1341c22ec75643d841642dd5d6acd83bdb8", - "reference": "79cbf1341c22ec75643d841642dd5d6acd83bdb8", - "shasum": "" - }, - "require": { - "psr/container": "^1.0" - }, - "time": "2017-02-14T19:40:03+00:00", - "type": "library", - "installation-source": "dist", - "autoload": { - "psr-4": { - "Interop\\Container\\": "src/Interop/Container/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "description": "Promoting the interoperability of container objects (DIC, SL, etc.)", - "homepage": "https://github.com/container-interop/container-interop" - }, { "name": "php-di/invoker", "version": "1.3.3", @@ -598,6 +773,45 @@ "di" ] }, + { + "name": "php-di/phpdoc-reader", + "version": "2.0.1", + "version_normalized": "2.0.1.0", + "source": { + "type": "git", + "url": "https://github.com/PHP-DI/PhpDocReader.git", + "reference": "83f5ead159defccfa8e7092e5b6c1c533b326d68" + }, + "dist": { + "type": "zip", + "url": "https://api.github.com/repos/PHP-DI/PhpDocReader/zipball/83f5ead159defccfa8e7092e5b6c1c533b326d68", + "reference": "83f5ead159defccfa8e7092e5b6c1c533b326d68", + "shasum": "" + }, + "require": { + "php": ">=5.3.0" + }, + "require-dev": { + "phpunit/phpunit": "~4.6" + }, + "time": "2015-11-29T10:34:25+00:00", + "type": "library", + "installation-source": "dist", + "autoload": { + "psr-4": { + "PhpDocReader\\": "src/PhpDocReader" + } + }, + "notification-url": "https://packagist.org/downloads/", + "license": [ + "MIT" + ], + "description": "PhpDocReader parses @var and @param values in PHP docblocks (supports namespaced class names with the same resolution rules as PHP)", + "keywords": [ + "phpdoc", + "reflection" + ] + }, { "name": "phpmailer/phpmailer", "version": "v6.0.3", @@ -761,24 +975,24 @@ ] }, { - "name": "doctrine/lexer", - "version": "v1.0.1", - "version_normalized": "1.0.1.0", + "name": "psr/container", + "version": "1.0.0", + "version_normalized": "1.0.0.0", "source": { "type": "git", - "url": "https://github.com/doctrine/lexer.git", - "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c" + "url": "https://github.com/php-fig/container.git", + "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/lexer/zipball/83893c552fd2045dd78aef794c31e694c37c0b8c", - "reference": "83893c552fd2045dd78aef794c31e694c37c0b8c", + "url": "https://api.github.com/repos/php-fig/container/zipball/b7ce3b176482dbbc1245ebf52b181af44c2cf55f", + "reference": "b7ce3b176482dbbc1245ebf52b181af44c2cf55f", "shasum": "" }, "require": { - "php": ">=5.3.2" + "php": ">=5.3.0" }, - "time": "2014-09-09T13:34:57+00:00", + "time": "2017-02-14T16:28:37+00:00", "type": "library", "extra": { "branch-alias": { @@ -787,8 +1001,8 @@ }, "installation-source": "dist", "autoload": { - "psr-0": { - "Doctrine\\Common\\Lexer\\": "lib/" + "psr-4": { + "Psr\\Container\\": "src/" } }, "notification-url": "https://packagist.org/downloads/", @@ -797,378 +1011,218 @@ ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "PHP-FIG", + "homepage": "http://www.php-fig.org/" } ], - "description": "Base library for a lexer that can be used in Top-Down, Recursive Descent Parsers.", - "homepage": "http://www.doctrine-project.org", + "description": "Common Container Interface (PHP FIG PSR-11)", + "homepage": "https://github.com/php-fig/container", "keywords": [ - "lexer", - "parser" + "PSR-11", + "container", + "container-interface", + "container-interop", + "psr" ] }, { - "name": "doctrine/inflector", - "version": "v1.1.0", - "version_normalized": "1.1.0.0", + "name": "roave/security-advisories", + "version": "dev-master", + "version_normalized": "9999999-dev", "source": { "type": "git", - "url": "https://github.com/doctrine/inflector.git", - "reference": "90b2128806bfde671b6952ab8bea493942c1fdae" + "url": "https://github.com/Roave/SecurityAdvisories.git", + "reference": "3df94834c80037130b533703df4672785b6ea112" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/inflector/zipball/90b2128806bfde671b6952ab8bea493942c1fdae", - "reference": "90b2128806bfde671b6952ab8bea493942c1fdae", + "url": "https://api.github.com/repos/Roave/SecurityAdvisories/zipball/3df94834c80037130b533703df4672785b6ea112", + "reference": "3df94834c80037130b533703df4672785b6ea112", "shasum": "" }, - "require": { - "php": ">=5.3.2" - }, - "require-dev": { - "phpunit/phpunit": "4.*" - }, - "time": "2015-11-06T14:35:42+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.1.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-0": { - "Doctrine\\Common\\Inflector\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Common String Manipulations with regard to casing and singular/plural rules.", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "inflection", - "pluralize", - "singularize", - "string" - ] - }, - { - "name": "doctrine/collections", - "version": "v1.4.0", - "version_normalized": "1.4.0.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/collections.git", - "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/collections/zipball/1a4fb7e902202c33cce8c55989b945612943c2ba", - "reference": "1a4fb7e902202c33cce8c55989b945612943c2ba", - "shasum": "" - }, - "require": { - "php": "^5.6 || ^7.0" - }, - "require-dev": { - "doctrine/coding-standard": "~0.1@dev", - "phpunit/phpunit": "^5.7" - }, - "time": "2017-01-03T10:49:41+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.3.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-0": { - "Doctrine\\Common\\Collections\\": "lib/" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Collections Abstraction library", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "array", - "collections", - "iterator" - ] - }, - { - "name": "doctrine/cache", - "version": "v1.6.2", - "version_normalized": "1.6.2.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/cache.git", - "reference": "eb152c5100571c7a45470ff2a35095ab3f3b900b" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/cache/zipball/eb152c5100571c7a45470ff2a35095ab3f3b900b", - "reference": "eb152c5100571c7a45470ff2a35095ab3f3b900b", - "shasum": "" - }, - "require": { - "php": "~5.5|~7.0" - }, "conflict": { - "doctrine/common": ">2.2,<2.4" - }, - "require-dev": { - "phpunit/phpunit": "~4.8|~5.0", - "predis/predis": "~1.0", - "satooshi/php-coveralls": "~0.6" - }, - "time": "2017-07-22T12:49:21+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "1.6.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "Doctrine\\Common\\Cache\\": "lib/Doctrine/Common/Cache" - } + "adodb/adodb-php": "<5.20.6", + "amphp/artax": "<1.0.6|>=2,<2.0.6", + "aws/aws-sdk-php": ">=3,<3.2.1", + "bugsnag/bugsnag-laravel": ">=2,<2.0.2", + "cakephp/cakephp": ">=1.3,<1.3.18|>=2,<2.4.99|>=2.5,<2.5.99|>=2.6,<2.6.12|>=2.7,<2.7.6|>=3,<3.0.15|>=3.1,<3.1.4", + "cart2quote/module-quotation": ">=4.1.6,<=4.4.5|>=5,<5.4.4", + "cartalyst/sentry": "<=2.1.6", + "codeigniter/framework": "<=3.0.6", + "composer/composer": "<=1.0.0-alpha11", + "contao-components/mediaelement": ">=2.14.2,<2.21.1", + "contao/core": ">=2,<3.5.32", + "contao/core-bundle": ">=4,<4.4.8", + "contao/listing-bundle": ">=4,<4.4.8", + "contao/newsletter-bundle": ">=4,<4.1", + "doctrine/annotations": ">=1,<1.2.7", + "doctrine/cache": ">=1,<1.3.2|>=1.4,<1.4.2", + "doctrine/common": ">=2,<2.4.3|>=2.5,<2.5.1", + "doctrine/dbal": ">=2,<2.0.8|>=2.1,<2.1.2", + "doctrine/doctrine-bundle": "<1.5.2", + "doctrine/doctrine-module": "<=0.7.1", + "doctrine/mongodb-odm": ">=1,<1.0.2", + "doctrine/mongodb-odm-bundle": ">=2,<3.0.1", + "doctrine/orm": ">=2,<2.4.8|>=2.5,<2.5.1", + "dompdf/dompdf": ">=0.6,<0.6.2", + "drupal/core": ">=8,<8.3.7", + "drupal/drupal": ">=8,<8.3.7", + "ezsystems/ezpublish-legacy": ">=5.3,<5.3.12.2|>=5.4,<5.4.10.1|>=2017.8,<2017.8.1.1", + "firebase/php-jwt": "<2", + "friendsofsymfony/rest-bundle": ">=1.2,<1.2.2", + "friendsofsymfony/user-bundle": ">=1.2,<1.3.5", + "gree/jose": "<=2.2", + "gregwar/rst": "<1.0.3", + "guzzlehttp/guzzle": ">=6,<6.2.1|>=4.0.0-rc2,<4.2.4|>=5,<5.3.1", + "illuminate/auth": ">=4,<4.0.99|>=4.1,<4.1.26", + "illuminate/database": ">=4,<4.0.99|>=4.1,<4.1.29", + "joomla/session": "<1.3.1", + "laravel/framework": ">=4,<4.0.99|>=4.1,<4.1.29", + "laravel/socialite": ">=1,<1.0.99|>=2,<2.0.10", + "magento/magento1ce": ">=1.5.0.1,<1.9.3.2", + "magento/magento1ee": ">=1.9,<1.14.3.2", + "magento/magento2ce": ">=2,<2.2", + "monolog/monolog": ">=1.8,<1.12", + "namshi/jose": "<2.2", + "onelogin/php-saml": "<2.10.4", + "oro/crm": ">=1.7,<1.7.4", + "oro/platform": ">=1.7,<1.7.4", + "phpmailer/phpmailer": ">=5,<5.2.24", + "phpunit/phpunit": ">=4.8.19,<4.8.28|>=5.0.10,<5.6.3", + "phpxmlrpc/extras": "<0.6.1", + "pusher/pusher-php-server": "<2.2.1", + "sabre/dav": ">=1.6,<1.6.99|>=1.7,<1.7.11|>=1.8,<1.8.9", + "shopware/shopware": "<5.3.7", + "silverstripe/cms": ">=3,<=3.0.11|>=3.1,<3.1.11", + "silverstripe/forum": "<=0.6.1|>=0.7,<=0.7.3", + "silverstripe/framework": ">=3,<3.3", + "silverstripe/userforms": "<3", + "simplesamlphp/saml2": "<1.10.4|>=2,<2.3.5|>=3,<3.1.1", + "simplesamlphp/simplesamlphp": "<1.15.2", + "simplesamlphp/simplesamlphp-module-infocard": "<1.0.1", + "socalnick/scn-social-auth": "<1.15.2", + "squizlabs/php_codesniffer": ">=1,<2.8.1", + "swiftmailer/swiftmailer": ">=4,<5.4.5", + "symfony/dependency-injection": ">=2,<2.0.17", + "symfony/form": ">=2.3,<2.3.35|>=2.4,<2.6.12|>=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", + "symfony/framework-bundle": ">=2,<2.3.18|>=2.4,<2.4.8|>=2.5,<2.5.2", + "symfony/http-foundation": ">=2,<2.3.27|>=2.4,<2.5.11|>=2.6,<2.6.6", + "symfony/http-kernel": ">=2,<2.3.29|>=2.4,<2.5.12|>=2.6,<2.6.8", + "symfony/intl": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", + "symfony/routing": ">=2,<2.0.19", + "symfony/security": ">=2,<2.0.25|>=2.1,<2.1.13|>=2.2,<2.2.9|>=2.3,<2.3.37|>=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8.23,<2.8.25|>=3.2.10,<3.2.12|>=3.3.3,<3.3.5", + "symfony/security-core": ">=2.4,<2.6.13|>=2.7,<2.7.9|>=2.7.30,<2.7.32|>=2.8,<2.8.6|>=2.8.23,<2.8.25|>=3,<3.0.6|>=3.2.10,<3.2.12|>=3.3.3,<3.3.5", + "symfony/security-csrf": ">=2.7,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", + "symfony/security-http": ">=2.3,<2.3.41|>=2.4,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", + "symfony/serializer": ">=2,<2.0.11", + "symfony/symfony": ">=2,<2.3.41|>=2.4,<2.7.38|>=2.8,<2.8.31|>=3,<3.2.14|>=3.3,<3.3.13", + "symfony/translation": ">=2,<2.0.17", + "symfony/validator": ">=2,<2.0.24|>=2.1,<2.1.12|>=2.2,<2.2.5|>=2.3,<2.3.3", + "symfony/web-profiler-bundle": ">=2,<2.3.19|>=2.4,<2.4.9|>=2.5,<2.5.4", + "symfony/yaml": ">=2,<2.0.22|>=2.1,<2.1.7", + "thelia/backoffice-default-template": ">=2.1,<2.1.2", + "thelia/thelia": ">=2.1.0-beta1,<2.1.3|>=2.1,<2.1.2", + "twig/twig": "<1.20", + "typo3/cms": ">=6.2,<6.2.30|>=7,<7.6.22|>=8,<8.7.5", + "typo3/flow": ">=1,<1.0.4|>=1.1,<1.1.1|>=2,<2.0.1|>=2.3,<2.3.16|>=3,<3.0.10|>=3.1,<3.1.7|>=3.2,<3.2.7|>=3.3,<3.3.5", + "typo3/neos": ">=1.1,<1.1.3|>=1.2,<1.2.13|>=2,<2.0.4", + "willdurand/js-translation-bundle": "<2.1.1", + "yiisoft/yii": ">=1.1.14,<1.1.15", + "yiisoft/yii2": "<2.0.5", + "yiisoft/yii2-bootstrap": "<2.0.4", + "yiisoft/yii2-dev": "<2.0.4", + "yiisoft/yii2-gii": "<2.0.4", + "yiisoft/yii2-jui": "<2.0.4", + "zendframework/zend-cache": ">=2.4,<2.4.8|>=2.5,<2.5.3", + "zendframework/zend-captcha": ">=2,<2.4.9|>=2.5,<2.5.2", + "zendframework/zend-crypt": ">=2,<2.4.9|>=2.5,<2.5.2", + "zendframework/zend-db": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.10|>=2.3,<2.3.5", + "zendframework/zend-diactoros": ">=1,<1.0.4", + "zendframework/zend-form": ">=2,<2.2.7|>=2.3,<2.3.1", + "zendframework/zend-http": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.3,<2.3.8|>=2.4,<2.4.1", + "zendframework/zend-json": ">=2.1,<2.1.6|>=2.2,<2.2.6", + "zendframework/zend-ldap": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.8|>=2.3,<2.3.3", + "zendframework/zend-mail": ">=2,<2.4.11|>=2.5,<2.7.2", + "zendframework/zend-navigation": ">=2,<2.2.7|>=2.3,<2.3.1", + "zendframework/zend-session": ">=2,<2.0.99|>=2.1,<2.1.99|>=2.2,<2.2.9|>=2.3,<2.3.4", + "zendframework/zend-validator": ">=2.3,<2.3.6", + "zendframework/zend-view": ">=2,<2.2.7|>=2.3,<2.3.1", + "zendframework/zend-xmlrpc": ">=2.1,<2.1.6|>=2.2,<2.2.6", + "zendframework/zendframework": ">=2,<2.4.11|>=2.5,<2.5.1", + "zendframework/zendframework1": "<1.12.20", + "zendframework/zendopenid": ">=2,<2.0.2", + "zendframework/zendxml": ">=1,<1.0.1", + "zetacomponents/mail": "<1.8.2", + "zf-commons/zfc-user": "<1.2.2", + "zfcampus/zf-apigility-doctrine": ">=1,<1.0.3", + "zfr/zfr-oauth2-server-module": "<0.1.2" }, + "time": "2018-02-04T22:09:50+00:00", + "type": "metapackage", "notification-url": "https://packagist.org/downloads/", "license": [ "MIT" ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "Marco Pivetta", + "email": "ocramius@gmail.com", + "role": "maintainer" } ], - "description": "Caching library offering an object-oriented API for many cache backends", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "cache", - "caching" - ] + "description": "Prevents installation of composer packages with known security vulnerabilities: no API, simply require it" }, { - "name": "doctrine/annotations", - "version": "v1.4.0", - "version_normalized": "1.4.0.0", + "name": "squizlabs/php_codesniffer", + "version": "3.2.2", + "version_normalized": "3.2.2.0", "source": { "type": "git", - "url": "https://github.com/doctrine/annotations.git", - "reference": "54cacc9b81758b14e3ce750f205a393d52339e97" + "url": "https://github.com/squizlabs/PHP_CodeSniffer.git", + "reference": "d7c00c3000ac0ce79c96fcbfef86b49a71158cd1" }, "dist": { "type": "zip", - "url": "https://api.github.com/repos/doctrine/annotations/zipball/54cacc9b81758b14e3ce750f205a393d52339e97", - "reference": "54cacc9b81758b14e3ce750f205a393d52339e97", + "url": "https://api.github.com/repos/squizlabs/PHP_CodeSniffer/zipball/d7c00c3000ac0ce79c96fcbfef86b49a71158cd1", + "reference": "d7c00c3000ac0ce79c96fcbfef86b49a71158cd1", "shasum": "" }, "require": { - "doctrine/lexer": "1.*", - "php": "^5.6 || ^7.0" + "ext-simplexml": "*", + "ext-tokenizer": "*", + "ext-xmlwriter": "*", + "php": ">=5.4.0" }, "require-dev": { - "doctrine/cache": "1.*", - "phpunit/phpunit": "^5.7" + "phpunit/phpunit": "^4.0 || ^5.0 || ^6.0" }, - "time": "2017-02-24T16:22:25+00:00", + "time": "2017-12-19T21:44:46+00:00", + "bin": [ + "bin/phpcs", + "bin/phpcbf" + ], "type": "library", "extra": { "branch-alias": { - "dev-master": "1.4.x-dev" + "dev-master": "3.x-dev" } }, "installation-source": "dist", - "autoload": { - "psr-4": { - "Doctrine\\Common\\Annotations\\": "lib/Doctrine/Common/Annotations" - } - }, "notification-url": "https://packagist.org/downloads/", "license": [ - "MIT" + "BSD-3-Clause" ], "authors": [ { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" + "name": "Greg Sherwood", + "role": "lead" } ], - "description": "Docblock Annotations Parser", - "homepage": "http://www.doctrine-project.org", + "description": "PHP_CodeSniffer tokenizes PHP, JavaScript and CSS files and detects violations of a defined set of coding standards.", + "homepage": "http://www.squizlabs.com/php-codesniffer", "keywords": [ - "annotations", - "docblock", - "parser" - ] - }, - { - "name": "doctrine/common", - "version": "v2.7.3", - "version_normalized": "2.7.3.0", - "source": { - "type": "git", - "url": "https://github.com/doctrine/common.git", - "reference": "4acb8f89626baafede6ee5475bc5844096eba8a9" - }, - "dist": { - "type": "zip", - "url": "https://api.github.com/repos/doctrine/common/zipball/4acb8f89626baafede6ee5475bc5844096eba8a9", - "reference": "4acb8f89626baafede6ee5475bc5844096eba8a9", - "shasum": "" - }, - "require": { - "doctrine/annotations": "1.*", - "doctrine/cache": "1.*", - "doctrine/collections": "1.*", - "doctrine/inflector": "1.*", - "doctrine/lexer": "1.*", - "php": "~5.6|~7.0" - }, - "require-dev": { - "phpunit/phpunit": "^5.4.6" - }, - "time": "2017-07-22T08:35:12+00:00", - "type": "library", - "extra": { - "branch-alias": { - "dev-master": "2.7.x-dev" - } - }, - "installation-source": "dist", - "autoload": { - "psr-4": { - "Doctrine\\Common\\": "lib/Doctrine/Common" - } - }, - "notification-url": "https://packagist.org/downloads/", - "license": [ - "MIT" - ], - "authors": [ - { - "name": "Roman Borschel", - "email": "roman@code-factory.org" - }, - { - "name": "Benjamin Eberlei", - "email": "kontakt@beberlei.de" - }, - { - "name": "Guilherme Blanco", - "email": "guilhermeblanco@gmail.com" - }, - { - "name": "Jonathan Wage", - "email": "jonwage@gmail.com" - }, - { - "name": "Johannes Schmitt", - "email": "schmittjoh@gmail.com" - } - ], - "description": "Common Library for Doctrine projects", - "homepage": "http://www.doctrine-project.org", - "keywords": [ - "annotations", - "collections", - "eventmanager", - "persistence", - "spl" + "phpcs", + "standards" ] } ]