// Loop until the string is done // Grab the very next character and load it into a while (($this->a = $this->getChar()) !== false) { switch ($this->a) { // If the string opener (single or double quote) is used // output it and break out of the while loop- // The string is finished! case $stringType: break 2; // New lines in strings without line delimiters are bad- actual // new lines will be represented by the string \n and not the actual // character, so those will be treated just fine using the switch // block below. case "\n": if ($stringType === '`') { echo $this->a; } else { throw new \RuntimeException('Unclosed string at position: ' . $startpos); } break; // Escaped characters get picked up here. If it's an escaped new line it's not really needed case '\\': // a is a slash. We want to keep it, and the next character, // unless it's a new line. New lines as actual strings will be // preserved, but escaped new lines should be reduced. $this->b = $this->getChar(); // If b is a new line we discard a and b and restart the loop. if ($this->b === "\n") { break; } // echo out the escaped character and restart the loop. echo $this->a . $this->b; break;
$this->saveString(); } } break; case ' ': if (!static::isAlphaNumeric($this->a)) { break; } // no break default: // check for some regex that breaks stuff if ($this->a === '/' && ($this->b === '\'' || $this->b === '"')) { $this->saveRegex(); continue 3; } echo $this->a; $this->saveString(); break; } } // do reg check of doom $this->b = $this->getReal(); if (($this->b == '/' && strpos('(,=:[!&|?*+-%', $this->a) !== false)) { $this->saveRegex(); } } } /** * Resets attributes that do not need to be stored between requests so that * the next request is ready to go. Another reason for this is to make sure * the variables are cleared and are not taking up memory. */ protected function clean() {
unset($jshrink); } // without this call things get weird, with partially outputted js. ob_end_clean(); throw $e; } } /** * Processes a javascript string and outputs only the required characters, * stripping out all unneeded characters. * * @param string $js The raw javascript to be minified * @param array $options Various runtime options in an associative array */ protected function minifyDirectToOutput($js, $options) { $this->initialize($js, $options); $this->loop(); $this->clean(); } /** * Initializes internal variables, normalizes new lines, * * @param string $js The raw javascript to be minified * @param array $options Various runtime options in an associative array */ protected function initialize($js, $options) { $this->options = array_merge(static::$defaultOptions, $options); $js = str_replace("\r\n", "\n", $js); $js = str_replace('/**/', '', $js); $this->input = str_replace("\r", "\n", $js); // We add a newline to the end of the script to make it easier to deal // with comments at the bottom of the script- this prevents the unclosed // comment error that can otherwise occur. $this->input .= PHP_EOL;
*/ protected $locks = array(); /** * Takes a string containing javascript and removes unneeded characters in * order to shrink the code without altering it's functionality. * * @param string $js The raw javascript to be minified * @param array $options Various runtime options in an associative array * @throws \Exception * @return bool|string */ public static function minify($js, $options = array()) { try { ob_start(); $jshrink = new Minifier(); $js = $jshrink->lock($js); $jshrink->minifyDirectToOutput($js, $options); // Sometimes there's a leading new line, so we trim that out here. $js = ltrim(ob_get_clean()); $js = $jshrink->unlock($js); unset($jshrink); return $js; } catch (\Exception $e) { if (isset($jshrink)) { // Since the breakdownScript function probably wasn't finished // we clean it out before discarding it. $jshrink->clean(); unset($jshrink); } // without this call things get weird, with partially outputted js. ob_end_clean(); throw $e; } }
public static function process($assets) { if ($directory = self::getOutputDirectory()) { $relativeDirectory = self::getRelativeOutputDirectory(); $filename = ''; $sourceFiles = array(); for ($i = 0; $i < count($assets); ++$i) { $asset = $assets[$i]; $filename .= $asset->getAssetHashKey(); $sourceFiles[] = $asset->getAssetURL(); } $filename = sha1($filename); $cacheFile = $directory.'/'.$filename.'.js'; if (!file_exists($cacheFile)) { $js = ''; foreach ($assets as $asset) { $contents = $asset->getAssetContents(); if (isset($contents)) { if ($asset->assetSupportsMinification()) { $contents = \JShrink\Minifier::minify($contents); } $js .= $contents.";\n\n"; } } @file_put_contents($cacheFile, $js); } $asset = new self(); $asset->setAssetURL($relativeDirectory.'/'.$filename.'.js'); $asset->setAssetPath($directory.'/'.$filename.'.js'); $asset->setCombinedAssetSourceFiles($sourceFiles); return array($asset); } return $assets; } /** * @return string
++$segment; continue; } } $return = []; // now we have a sub assets array with different segments split by whether they can be combined. foreach ($groupedAssets as $assets) { if ( ($assets[0] instanceof Asset) && ( (count($assets) > 1) || $assets[0]->assetSupportsMinification() ) ) { $class = get_class($assets[0]); $assets = call_user_func([$class, 'process'], $assets); } $return = array_merge($return, $assets); } return $return; } protected function replaceEmptyAssetPlaceholders($pageContent) { foreach (['<!--ccm:assets:'.Asset::ASSET_POSITION_HEADER.'//-->', '<!--ccm:assets:'.Asset::ASSET_POSITION_FOOTER.'//-->'] as $comment) { $pageContent = str_replace($comment, '', $pageContent); } return $pageContent; } protected function replaceAssetPlaceholders($outputAssets, $pageContent) { $outputItems = []; foreach ($outputAssets as $position => $assets) {
++$segment; continue; } } $return = []; // now we have a sub assets array with different segments split by whether they can be combined. foreach ($groupedAssets as $assets) { if ( ($assets[0] instanceof Asset) && ( (count($assets) > 1) || $assets[0]->assetSupportsMinification() ) ) { $class = get_class($assets[0]); $assets = call_user_func([$class, 'process'], $assets); } $return = array_merge($return, $assets); } return $return; } protected function replaceEmptyAssetPlaceholders($pageContent) { foreach (['<!--ccm:assets:'.Asset::ASSET_POSITION_HEADER.'//-->', '<!--ccm:assets:'.Asset::ASSET_POSITION_FOOTER.'//-->'] as $comment) { $pageContent = str_replace($comment, '', $pageContent); } return $pageContent; } protected function replaceAssetPlaceholders($outputAssets, $pageContent) { $outputItems = []; foreach ($outputAssets as $position => $assets) {
} return $return; } protected function replaceEmptyAssetPlaceholders($pageContent) { foreach (['<!--ccm:assets:'.Asset::ASSET_POSITION_HEADER.'//-->', '<!--ccm:assets:'.Asset::ASSET_POSITION_FOOTER.'//-->'] as $comment) { $pageContent = str_replace($comment, '', $pageContent); } return $pageContent; } protected function replaceAssetPlaceholders($outputAssets, $pageContent) { $outputItems = []; foreach ($outputAssets as $position => $assets) { $output = ''; $transformed = $this->postProcessAssets($assets); foreach ($transformed as $item) { $itemstring = (string) $item; if (!in_array($itemstring, $outputItems)) { $output .= $this->outputAssetIntoView($item); $outputItems[] = $itemstring; } } $pageContent = str_replace('<!--ccm:assets:'.$position.'//-->', $output, $pageContent); } return $pageContent; } protected function outputAssetIntoView($item) { $formatter = new StandardFormatter(); if ($item instanceof Asset) { return $formatter->output($item) . "\n"; } else { return $item . "\n";
* Function responsible for outputting footer items. */ public function markFooterAssetPosition() { echo '<!--ccm:assets:'.Asset::ASSET_POSITION_FOOTER.'//-->'; } protected function getAssetsToOutput() { $responseGroup = ResponseAssetGroup::get(); $assets = $responseGroup->getAssetsToOutput(); return $assets; } public function postProcessViewContents($contents) { $assets = $this->getAssetsToOutput(); $contents = $this->replaceAssetPlaceholders($assets, $contents); // replace any empty placeholders $contents = $this->replaceEmptyAssetPlaceholders($contents); return $contents; } protected function postProcessAssets($assets) { $c = Page::getCurrentPage(); if (!Config::get('concrete.cache.assets')) { return $assets; } if (!count($assets)) { return []; } // goes through all assets in this list, creating new URLs and post-processing them where possible. $segment = 0;
$return = array_merge($this->scopeItems, $sets, $helpers); } else { $return = $this->scopeItems; } $return['view'] = $this; $return['controller'] = $this->controller; return $return; } public function render($state = false) { if ($this instanceof View) { $this->setRequestInstance($this); } $this->start($state); $this->setupRender(); $this->startRender(); $scopeItems = $this->getScopeItems(); $contents = $this->renderViewContents($scopeItems); $contents = $this->postProcessViewContents($contents); $response = $this->finishRender($contents); if ($this instanceof View) { $this->revertRequestInstance(); } return $response; } public function renderViewContents($scopeItems) { if (file_exists($this->template)) { extract($scopeItems); ob_start(); $this->onBeforeGetContents(); include $this->template; $this->onAfterGetContents(); $contents = ob_get_contents(); ob_end_clean(); return $contents;
$cnt = $this->app->make(PageForbidden::class); $this->controller($cnt, $code, $headers); } /** * {@inheritdoc} */ public function redirect($to, $code = Response::HTTP_MOVED_PERMANENTLY, $headers = []) { return RedirectResponse::create($to, $code, $headers); } /** * {@inheritdoc} */ public function view(View $view, $code = Response::HTTP_OK, $headers = []) { $this->localization->pushActiveContext(Localization::CONTEXT_SITE); try { $contents = $view->render(); return $this->create($contents, $code, $headers); } finally { $this->localization->popActiveContext(); } } /** * {@inheritdoc} */ public function controller(Controller $controller, $code = Response::HTTP_OK, $headers = []) { $this->localization->pushActiveContext(Localization::CONTEXT_SITE); try { $request = $this->request; if ($response = $controller->on_start()) { return $response; }
if ($response = $controller->runAction('view')) { return $response; } } $view = $controller->getViewObject(); // Mobile theme if ($this->config->get('concrete.misc.mobile_theme_id') > 0) { $md = $this->app->make(MobileDetect::class); if ($md->isMobile()) { $mobileTheme = Theme::getByID($this->app->config->get('concrete.misc.mobile_theme_id')); if ($mobileTheme instanceof Theme) { $view->setViewTheme($mobileTheme); $controller->setTheme($mobileTheme); } } } return $this->view($view, $code, $headers); } finally { $this->localization->popActiveContext(); } } /** * {@inheritdoc} */ public function collection(Collection $collection, $code = Response::HTTP_OK, $headers = []) { if (!$this->app) { throw new \RuntimeException('Cannot resolve collections without a reference to the application'); } $request = $this->request; if ($collection->isError() && $collection->getError() == COLLECTION_NOT_FOUND) { if ($response = $this->collectionNotFound($collection, $request, $headers)) { return $response; }
$pe = new Event($collection); $pe->setUser($u); $pe->setRequest($request); $this->app['director']->dispatch('on_page_view', $pe); // Core menu items $item = new RelationListItem(); $menu = $this->app->make('helper/concrete/ui/menu'); $menu->addMenuItem($item); // Multisite item $item = new SiteListItem(); $menu->addMenuItem($item); $controller = $collection->getPageController(); // we update the current page with the one bound to this controller. $collection->setController($controller); return $this->controller($controller); } private function collectionNotFound(Collection $collection, Request $request, array $headers) { // if we don't have a path and we're doing cID, then this automatically fires a 404. if (!$request->getPath() && $request->get('cID')) { return $this->notFound('', Response::HTTP_NOT_FOUND, $headers); } // let's test to see if this is, in fact, the home page, // and we're routing arguments onto it (which is screwing up the path.) $home = Page::getByID(Page::getHomePageID()); $request->setCurrentPage($home); $homeController = $home->getPageController(); $homeController->setupRequestActionAndParameters($request); $response = $homeController->validateRequest(); if ($response instanceof \Symfony\Component\HttpFoundation\Response) { return $response; } elseif ($response === true) {
new DispatcherDelegate($dispatcher) ); $stack->setApplication($this->app); foreach($route->getMiddlewares() as $middleware) { if (is_string($middleware->getMiddleware())) { $inflatedMiddleware = $this->app->make($middleware->getMiddleware()); } else { $inflatedMiddleware = $middleware->getMiddleware(); } $stack = $stack->withMiddleware( $inflatedMiddleware, $middleware->getPriority() ); } return $stack->process($request); } catch (ResourceNotFoundException $e) { } catch (MethodNotAllowedException $e) { } $c = \Page::getFromRequest($request); $response = $this->app->make(ResponseFactoryInterface::class)->collection($c); return $response; } /** * @param \Symfony\Component\Routing\RouteCollection $routes * @param string $path * * @return \Symfony\Component\Routing\RouteCollection */ private function filterRouteCollectionForPath(RouteCollection $routes, $path) { $result = new RouteCollection(); foreach ($routes->getResources() as $resource) { $result->addResource($resource); } foreach ($routes->all() as $name => $route) { $routePath = $route->getPath(); $p = strpos($routePath, '{'); $skip = false;
/** * @param \Symfony\Component\HttpFoundation\Request $request * * @return SymfonyResponse */ public function dispatch(SymfonyRequest $request) { $path = rawurldecode($request->getPathInfo()); if (substr($path, 0, 3) == '../' || substr($path, -3) == '/..' || strpos($path, '/../') || substr($path, 0, 3) == '..\\' || substr($path, -3) == '\\..' || strpos($path, '\\..\\')) { throw new \RuntimeException(t('Invalid path traversal. Please make this request with a valid HTTP client.')); } $response = null; if ($this->app->isInstalled()) { $response = $this->getEarlyDispatchResponse(); } if ($response === null) { $response = $this->handleDispatch($request); } return $response; } private function getEarlyDispatchResponse() { $validator = $this->app->make(SessionValidator::class); if ($validator->hasActiveSession()) { $session = $this->app['session']; if (!$session->has('uID')) { User::verifyAuthTypeCookie(); } // User may have been logged in, so lets check status again. if ($session->has('uID') && $session->get('uID') > 0 && $response = $this->validateUser()) { return $response; } } }
private $dispatcher; /** * DispatcherFrame constructor. * @param \Concrete\Core\Http\DispatcherInterface $dispatcher */ public function __construct(DispatcherInterface $dispatcher) { $this->dispatcher = $dispatcher; } /** * Dispatch the next available middleware and return the response. * * @param Request $request * @return Response */ public function next(Request $request) { return $this->dispatcher->dispatch($request); } }
* @var \Concrete\Core\Config\Repository\Repository */ private $config; public function __construct(Repository $config) { $this->config = $config; } /** * Process the request and return a response. * * @param \Symfony\Component\HttpFoundation\Request $request * @param DelegateInterface $frame * * @return \Symfony\Component\HttpFoundation\Response */ public function process(Request $request, DelegateInterface $frame) { $response = $frame->next($request); if ($response && $this->app->isInstalled() && $this->config->get('concrete.misc.basic_thumbnailer_generation_strategy') == 'now') { $responseStatusCode = (int) $response->getStatusCode(); if ($responseStatusCode === 200 || $responseStatusCode === 404) { $database = $this->tryGetConnection(); if ($database !== null) { if ($responseStatusCode === 404) { $searchThumbnailPath = $request->getRequestUri(); } else { $searchThumbnailPath = null; } $thumbnail = $this->getThumbnailToGenerate($database, $searchThumbnailPath); if ($thumbnail !== null) { $this->markThumbnailAsBuilt($database, $thumbnail); if ($this->generateThumbnail($thumbnail)) { if ($this->couldBeTheRequestedThumbnail($thumbnail, $searchThumbnailPath)) { $response = $this->buildRedirectToThumbnailResponse($request); } } }
public function __construct( MiddlewareInterface $middleware, DelegateInterface $nextDelegate, HttpFoundationFactory $foundationFactory ) { $this->middleware = $middleware; $this->nextDelegate = $nextDelegate; $this->foundationFactory = $foundationFactory; } /** * Dispatch the next available middleware and return the response. * * @param Request $request * @return Response */ public function next(Request $request) { $response = $this->middleware->process($request, $this->nextDelegate); // Negotiate PSR7 responses if ($response instanceof ResponseInterface) { return $this->foundationFactory->createResponse($response); } return $response; } }
private $config; /** * @var \Concrete\Core\Utility\Service\Validation\Strings */ private $stringValidator; public function __construct(Repository $config, Strings $stringValidator) { $this->config = $config; $this->stringValidator = $stringValidator; } /** * @param \Concrete\Core\Http\Middleware\DelegateInterface $frame * @return Response */ public function process(Request $request, DelegateInterface $frame) { $response = $frame->next($request); if ($response->headers->has('X-Frame-Options') === false) { $x_frame_options = $this->config->get('concrete.security.misc.x_frame_options'); if ($this->stringValidator->notempty($x_frame_options)) { $response->headers->set('X-Frame-Options', $x_frame_options); } } return $response; } }
public function __construct( MiddlewareInterface $middleware, DelegateInterface $nextDelegate, HttpFoundationFactory $foundationFactory ) { $this->middleware = $middleware; $this->nextDelegate = $nextDelegate; $this->foundationFactory = $foundationFactory; } /** * Dispatch the next available middleware and return the response. * * @param Request $request * @return Response */ public function next(Request $request) { $response = $this->middleware->process($request, $this->nextDelegate); // Negotiate PSR7 responses if ($response instanceof ResponseInterface) { return $this->foundationFactory->createResponse($response); } return $response; } }
* @var \Concrete\Core\Cookie\ResponseCookieJar */ private $responseCookieJar; /** * @param \Concrete\Core\Cookie\ResponseCookieJar $responseCookieJar */ public function __construct(ResponseCookieJar $responseCookieJar) { $this->responseCookieJar = $responseCookieJar; } /** * {@inheritdoc} * * @see \Concrete\Core\Http\Middleware\MiddlewareInterface::process() */ public function process(Request $request, DelegateInterface $frame) { $response = $frame->next($request); $cleared = $this->responseCookieJar->getClearedCookies(); foreach ($cleared as $cookie) { $response->headers->clearCookie($cookie, DIR_REL . '/'); } $cookies = $this->responseCookieJar->getCookies(); foreach ($cookies as $cookie) { $response->headers->setCookie($cookie); } return $response; } }
public function __construct( MiddlewareInterface $middleware, DelegateInterface $nextDelegate, HttpFoundationFactory $foundationFactory ) { $this->middleware = $middleware; $this->nextDelegate = $nextDelegate; $this->foundationFactory = $foundationFactory; } /** * Dispatch the next available middleware and return the response. * * @param Request $request * @return Response */ public function next(Request $request) { $response = $this->middleware->process($request, $this->nextDelegate); // Negotiate PSR7 responses if ($response instanceof ResponseInterface) { return $this->foundationFactory->createResponse($response); } return $response; } }
* Middleware for applying state changes to the application * @package Concrete\Core\Http\Middleware */ class ApplicationMiddleware implements MiddlewareInterface, ApplicationAwareInterface { use ApplicationAwareTrait; /** * Apply the request instance to the request singleton * @param \Symfony\Component\HttpFoundation\Request $request * @param \Concrete\Core\Http\Middleware\DelegateInterface $frame * @return \Symfony\Component\HttpFoundation\Response */ public function process(Request $request, DelegateInterface $frame) { \Concrete\Core\Http\Request::setInstance($request); $this->app->instance('Concrete\Core\Http\Request', $request); return $frame->next($request); } }
public function __construct( MiddlewareInterface $middleware, DelegateInterface $nextDelegate, HttpFoundationFactory $foundationFactory ) { $this->middleware = $middleware; $this->nextDelegate = $nextDelegate; $this->foundationFactory = $foundationFactory; } /** * Dispatch the next available middleware and return the response. * * @param Request $request * @return Response */ public function next(Request $request) { $response = $this->middleware->process($request, $this->nextDelegate); // Negotiate PSR7 responses if ($response instanceof ResponseInterface) { return $this->foundationFactory->createResponse($response); } return $response; } }
public function withoutMiddleware(MiddlewareInterface $middleware) { $stack = clone $this; $stack->middleware = array_map(function($priorityGroup) use ($middleware) { return array_map(function($stackMiddleware) use ($middleware) { return $middleware === $stackMiddleware ? null : $stackMiddleware; }, $priorityGroup); }, $stack->middleware); return $stack; } /** * @inheritdoc */ public function process(Request $request) { $stack = $this->getStack(); return $stack->next($request); } /** * Reduce middleware into a stack of functions that each call the next * @return callable */ private function getStack() { $processed = []; foreach ($this->middlewareGenerator() as $middleware) { $processed[] = $middleware; } $middleware = array_reverse($processed); $stack = array_reduce($middleware, $this->getZipper(), $this->dispatcher); return $stack; }
*/ public function removeMiddleware(MiddlewareInterface $middleware) { $this->stack = $this->stack->withoutMiddleware($middleware); return $this; } /** * Take a request and pass it through middleware, then return the response * @param SymfonyRequest $request * @return SymfonyResponse */ public function handleRequest(SymfonyRequest $request) { $stack = $this->stack; if ($stack instanceof MiddlewareStack) { $stack = $stack->withDispatcher($this->app->make(DispatcherDelegate::class, [$this->dispatcher])); } return $stack->process($request); } }
// Register legacy config values 'registerLegacyConfigValues', // Handle loading permission keys 'handlePermissionKeys', // Handle eventing 'handleEventing', ]); } else { $this->initializeSystemTimezone(); $this->preloadClassAliases(); } // Create the request to use $request = $this->createRequest(); if (!$response) { $response = $this->server->handleRequest($request); } // Prepare and return the response return $response->prepare($request); } /** * Define the base url if not defined * This will define `BASE_URL` to whatever is resolved from the resolver. * * @deprecated In a future major version this will be part of HTTP middleware * * @return Response|void Returns a response if an error occurs */ protected function initializeLegacyURLDefinitions() { if (!defined('BASE_URL')) { $resolver = $this->getUrlResolver(); try {
$this->status = self::STATUS_ACTIVE; } } /** * Begin the runtime. */ public function run() { switch ($this->status) { case self::STATUS_ENDED: // We've already ended, lets just return return; case self::STATUS_INACTIVE: throw new \RuntimeException('Runtime has not yet booted.'); } $runner = $this->getRunner(); $response = $runner->run(); if ($response) { $this->sendResponse($response); } return $response; } /** * The method that handles properly sending a response. * * @param \Symfony\Component\HttpFoundation\Response $response */ protected function sendResponse(Response $response) { $response->send(); // Set the status to ended $this->status = self::STATUS_ENDED; }
* Include all autoloaders. * ---------------------------------------------------------------------------- */ require __DIR__ . '/bootstrap/autoload.php'; /* * ---------------------------------------------------------------------------- * Begin concrete5 startup. * ---------------------------------------------------------------------------- */ $app = require __DIR__ . '/bootstrap/start.php'; /** @var \Concrete\Core\Application\Application $app */ /* * ---------------------------------------------------------------------------- * Run the runtime. * ---------------------------------------------------------------------------- */ $runtime = $app->getRuntime(); if ($response = $runtime->run()) { /* * ------------------------------------------------------------------------ * Shut it down. * ------------------------------------------------------------------------ */ $app->shutdown(); } else { return $app; }
defined('DIR_CONFIG_SITE') or define('DIR_CONFIG_SITE', DIR_APPLICATION . '/config'); /** * ---------------------------------------------------------------------------- * Now that we've had the opportunity to load our config file, we know if we * have a DIRNAME_CORE_UPDATED constant, which lives in that file, and which * points to another core. If we have this constant, we exit this file * immeditely and proceed into the updated core. * ---------------------------------------------------------------------------- */ $update_file = DIR_CONFIG_SITE . '/update.php'; $updates = array(); if (file_exists($update_file)) { $updates = (array) include $update_file; } if (!defined('APP_UPDATED_PASSTHRU') && isset($updates['core'])) { define('APP_UPDATED_PASSTHRU', true); if (is_dir(DIR_BASE . '/' . DIRNAME_UPDATES . '/' . $updates['core'])) { require(DIR_BASE . '/' . DIRNAME_UPDATES . '/' . $updates['core'] . '/' . DIRNAME_CORE . '/' . 'dispatcher.php'); } else if(file_exists(DIRNAME_UPDATES . '/' . $updates['core'] . '/' . DIRNAME_CORE . '/' . 'dispatcher.php')){ require(DIRNAME_UPDATES . '/' . $updates['core'] . '/' . DIRNAME_CORE . '/' . 'dispatcher.php'); } else { die(sprintf('Invalid "%s" defined. Please remove it from %s.','update.core', $update_file)); } exit; } /** * ---------------------------------------------------------------------------- * ## If we're still here, we're proceeding through this concrete directory, * and it's time to load the rest of our hard-coded configuration options – * the one we don't need a database to tell us about. * * Namespacing and Autoloading * ---------------------------------------------------------------------------- */ define('NAMESPACE_SEGMENT_VENDOR', 'Concrete');
<?php /** * ---------------------------------------------------------------------------- * Set our own version of __DIR__ as $__DIR__ so we can include this file on PHP < 5.3 and have it not * die wholesale. * ---------------------------------------------------------------------------- */ $__DIR__ = dirname(__FILE__); /** * ---------------------------------------------------------------------------- * Set required constants, including directory names, attempt to include site configuration file with database * information, attempt to determine if we ought to skip to an updated core, etc... * ---------------------------------------------------------------------------- */ require $__DIR__ . '/bootstrap/configure.php'; /** * ---------------------------------------------------------------------------- * Include all autoloaders * ---------------------------------------------------------------------------- */ require $__DIR__ . '/bootstrap/autoload.php'; /** * ---------------------------------------------------------------------------- * Begin concrete5 startup. * ---------------------------------------------------------------------------- */ $cms = require $__DIR__ . '/bootstrap/start.php'; if (!$cms->isRunThroughCommandLineInterface()) {
<?php require('concrete/dispatcher.php');
Key | Value |
Version | 8.5.4 |
Installed Version | 8.5.4 |
Key | Value |
concrete.version | 8.5.4 |
concrete.version_installed | 8.5.4 |
concrete.version_db | 20200609145307 |
concrete.installed | true |
concrete.locale | en_US |
concrete.charset | UTF-8 |
concrete.charset_bom | |
concrete.maintenance_mode | false |
concrete.debug.display_errors | true |
concrete.debug.detail | debug |
concrete.debug.error_reporting | null |
concrete.proxy.host | null |
concrete.proxy.port | null |
concrete.proxy.user | null |
concrete.proxy.password | null |
concrete.upload.extensions | *.flv;*.jpg;*.gif;*.jpeg;*.ico;*.docx;*.xla;*.png;*.psd;*.swf;*.doc;*.txt;*.xls;*.xlsx;*.csv;*.pdf;*.tiff;*.rtf;*.m4a;*.mov;*.wmv;*.mpeg;*.mpg;*.wav;*.3gp;*.avi;*.m4v;*.mp4;*.mp3;*.qt;*.ppt;*.pptx;*.kml;*.xml;*.svg;*.webm;*.ogg;*.ogv |
concrete.upload.extensions_blacklist | *.php;*.php2;*.php3;*.php4;*.php5;*.php7;*.php8;*.phtml;*.phar;*.htaccess;*.pl;*.phpsh;*.pht;*.shtml;*.cgi |
concrete.upload.chunking.enabled | true |
concrete.upload.chunking.chunkSize | null |
concrete.export.csv.include_bom | false |
concrete.export.csv.datetime_format | ATOM |
concrete.interface.panel.page_relations | false |
concrete.mail.method | PHP_MAIL |
concrete.mail.methods.smtp.server | |
concrete.mail.methods.smtp.port | |
concrete.mail.methods.smtp.username | |
concrete.mail.methods.smtp.password | |
concrete.mail.methods.smtp.encryption | |
concrete.mail.methods.smtp.messages_per_connection | null |
concrete.cache.enabled | true |
concrete.cache.lifetime | 21600 |
concrete.cache.overrides | true |
concrete.cache.blocks | true |
concrete.cache.assets | true |
concrete.cache.theme_css | true |
concrete.cache.pages | 0 |
concrete.cache.doctrine_dev_mode | false |
concrete.cache.full_page_lifetime | default |
concrete.cache.full_page_lifetime_value | null |
concrete.cache.full_contents_assets_hash | false |
concrete.cache.directory | /home/elmuseol/public_html/application/files/cache |
concrete.cache.directory_relative | null |
concrete.cache.page.directory | /home/elmuseol/public_html/application/files/cache/pages |
concrete.cache.page.adapter | file |
concrete.cache.levels.overrides.drivers.core_ephemeral.class | \Stash\Driver\Ephemeral |
concrete.cache.levels.overrides.drivers.core_filesystem.class | Concrete\Core\Cache\Driver\FileSystemStashDriver |
concrete.cache.levels.overrides.drivers.core_filesystem.options.path | /home/elmuseol/public_html/application/files/cache/overrides |
concrete.cache.levels.overrides.drivers.core_filesystem.options.dirPermissions | 511 |
concrete.cache.levels.overrides.drivers.core_filesystem.options.filePermissions | 438 |
concrete.cache.levels.overrides.drivers.redis.class | Concrete\Core\Cache\Driver\RedisStashDriver |
concrete.cache.levels.overrides.drivers.redis.options.prefix | c5_overrides |
concrete.cache.levels.overrides.drivers.redis.options.database | 0 |
concrete.cache.levels.overrides.preferred_driver | core_filesystem |
concrete.cache.levels.expensive.drivers.core_ephemeral.class | \Stash\Driver\Ephemeral |
concrete.cache.levels.expensive.drivers.core_filesystem.class | Concrete\Core\Cache\Driver\FileSystemStashDriver |
concrete.cache.levels.expensive.drivers.core_filesystem.options.path | /home/elmuseol/public_html/application/files/cache/expensive |
concrete.cache.levels.expensive.drivers.core_filesystem.options.dirPermissions | 511 |
concrete.cache.levels.expensive.drivers.core_filesystem.options.filePermissions | 438 |
concrete.cache.levels.expensive.drivers.redis.class | Concrete\Core\Cache\Driver\RedisStashDriver |
concrete.cache.levels.expensive.drivers.redis.options.prefix | c5_expensive |
concrete.cache.levels.expensive.drivers.redis.options.database | 0 |
concrete.cache.levels.expensive.preferred_driver | core_filesystem |
concrete.cache.levels.object.drivers.core_ephemeral.class | \Stash\Driver\Ephemeral |
concrete.cache.levels.object.drivers.redis.class | Concrete\Core\Cache\Driver\RedisStashDriver |
concrete.cache.levels.object.drivers.redis.options.prefix | c5_object |
concrete.cache.levels.object.drivers.redis.options.database | 0 |
concrete.cache.levels.object.preferred_driver | core_ephemeral |
concrete.cache.clear.thumbnails | false |
concrete.design.enable_custom | true |
concrete.design.enable_layouts | true |
concrete.log.emails | true |
concrete.log.errors | true |
concrete.log.spam | false |
concrete.log.api | false |
concrete.log.enable_dashboard_report | true |
concrete.log.configuration.mode | simple |
concrete.log.configuration.simple.core_logging_level | NOTICE |
concrete.log.configuration.simple.handler | database |
concrete.log.configuration.simple.file.file | |
concrete.jobs.enable_scheduling | true |
concrete.filesystem.temp_directory | null |
concrete.filesystem.permissions.file | 438 |
concrete.filesystem.permissions.directory | 511 |
concrete.email.enabled | true |
concrete.email.default.address | concrete5-noreply@concrete5 |
concrete.email.default.name | |
concrete.email.form_block.address | false |
concrete.email.forgot_password.address | null |
concrete.email.forgot_password.name | null |
concrete.email.validate_registration.address | null |
concrete.email.validate_registration.name | null |
concrete.email.workflow_notification.address | null |
concrete.email.workflow_notification.name | null |
concrete.form.store_form_submissions | auto |
concrete.marketplace.enabled | true |
concrete.marketplace.request_timeout | 30 |
concrete.marketplace.token | null |
concrete.marketplace.site_token | null |
concrete.marketplace.intelligent_search | true |
concrete.marketplace.log_requests | false |
concrete.external.intelligent_search_help | true |
concrete.external.news | true |
concrete.misc.user_timezones | false |
concrete.misc.package_backup_directory | /home/elmuseol/public_html/application/files/trash |
concrete.misc.enable_progressive_page_reindex | true |
concrete.misc.mobile_theme_id | 0 |
concrete.misc.sitemap_approve_immediately | true |
concrete.misc.enable_translate_locale_en_us | false |
concrete.misc.page_search_index_lifetime | 259200 |
concrete.misc.enable_trash_can | true |
concrete.misc.app_version_display_in_header | true |
concrete.misc.default_jpeg_image_compression | 80 |
concrete.misc.default_png_image_compression | 9 |
concrete.misc.default_thumbnail_format | auto |
concrete.misc.inplace_image_operations_limit | 4194304 |
concrete.misc.basic_thumbnailer_generation_strategy | now |
concrete.misc.help_overlay | true |
concrete.misc.require_version_comments | false |
concrete.misc.enable_move_blocktypes_across_sets | false |
concrete.misc.image_editor_cors_policy.enable_cross_origin | false |
concrete.misc.image_editor_cors_policy.anonymous_request | true |
concrete.misc.generator_tag_display_in_header | true |
concrete.misc.access_entity_updated | 1600196777 |
concrete.misc.latest_version | 8.5.6 |
concrete.misc.do_page_reindex_check | false |
concrete.misc.login_redirect | DESKTOP |
concrete.theme.compress_preprocessor_output | true |
concrete.theme.generate_less_sourcemap | false |
concrete.updates.enable_auto_update_packages | false |
concrete.updates.enable_permissions_protection | true |
concrete.updates.check_threshold | 172800 |
concrete.updates.services.get_available_updates | http://www.concrete5.org/tools/update_core |
concrete.updates.services.inspect_update | http://www.concrete5.org/tools/inspect_update |
concrete.updates.skip_core | false |
concrete.paths.trash | /!trash |
concrete.paths.drafts | /!drafts |
concrete.icons.page_template.width | 120 |
concrete.icons.page_template.height | 90 |
concrete.icons.theme_thumbnail.width | 120 |
concrete.icons.theme_thumbnail.height | 90 |
concrete.icons.file_manager_listing.handle | file_manager_listing |
concrete.icons.file_manager_listing.width | 60 |
concrete.icons.file_manager_listing.height | 60 |
concrete.icons.file_manager_detail.handle | file_manager_detail |
concrete.icons.file_manager_detail.width | 400 |
concrete.icons.file_manager_detail.height | 400 |
concrete.icons.user_avatar.width | 80 |
concrete.icons.user_avatar.height | 80 |
concrete.icons.user_avatar.default | /updates/concrete5-8.5.4/concrete/images/avatar_none.png |
concrete.file_manager.images.use_exif_data_to_rotate_images | false |
concrete.file_manager.images.manipulation_library | gd |
concrete.file_manager.images.create_high_dpi_thumbnails | true |
concrete.file_manager.images.preview_image_size | small |
concrete.file_manager.images.preview_image_popover | true |
concrete.file_manager.images.svg_sanitization.action | sanitize |
concrete.file_manager.images.svg_sanitization.allowed_tags | |
concrete.file_manager.images.svg_sanitization.allowed_attributes | |
concrete.file_manager.images.image_editor_save_area_background_color | |
concrete.file_manager.items_per_page_options.0 | 10 |
concrete.file_manager.items_per_page_options.1 | 25 |
concrete.file_manager.items_per_page_options.2 | 50 |
concrete.file_manager.items_per_page_options.3 | 100 |
concrete.file_manager.items_per_page_options.4 | 250 |
concrete.file_manager.results | 10 |
concrete.search_users.results | 10 |
concrete.sitemap_xml.file | sitemap.xml |
concrete.sitemap_xml.frequency | weekly |
concrete.sitemap_xml.priority | 0.5 |
concrete.accessibility.toolbar_titles | false |
concrete.accessibility.toolbar_large_font | false |
concrete.accessibility.display_help_system | true |
concrete.accessibility.toolbar_tooltips | true |
concrete.i18n.choose_language_login | false |
concrete.i18n.auto_install_package_languages | true |
concrete.i18n.community_translation.entry_point | http://translate.concrete5.org/api |
concrete.i18n.community_translation.api_token | |
concrete.i18n.community_translation.progress_limit | 60 |
concrete.i18n.community_translation.cache_lifetime | 3600 |
concrete.i18n.community_translation.package_url | https://translate.concrete5.org/translate/package |
concrete.urls.concrete5 | http://www.concrete5.org |
concrete.urls.concrete5_secure | https://www.concrete5.org |
concrete.urls.newsflow | http://newsflow.concrete5.org |
concrete.urls.background_feed | //backgroundimages.concrete5.org/wallpaper |
concrete.urls.privacy_policy | //www.concrete5.org/legal/privacy-policy |
concrete.urls.background_feed_secure | https://backgroundimages.concrete5.org/wallpaper |
concrete.urls.background_info | http://backgroundimages.concrete5.org/get_image_data.php |
concrete.urls.videos | https://www.youtube.com/user/concrete5cms/videos |
concrete.urls.help.developer | http://documentation.concrete5.org/developers |
concrete.urls.help.user | http://documentation.concrete5.org/editors |
concrete.urls.help.forum | http://www.concrete5.org/community/forums |
concrete.urls.help.slack | https://www.concrete5.org/slack |
concrete.urls.paths.menu_help_service | /tools/get_remote_help_list/ |
concrete.urls.paths.site_page | /private/sites |
concrete.urls.paths.newsflow_slot_content | /tools/slot_content/ |
concrete.urls.paths.marketplace.connect | /marketplace/connect |
concrete.urls.paths.marketplace.connect_success | /marketplace/connect/-/connected |
concrete.urls.paths.marketplace.connect_validate | /marketplace/connect/-/validate |
concrete.urls.paths.marketplace.connect_new_token | /marketplace/connect/-/generate_token |
concrete.urls.paths.marketplace.checkout | /cart/-/add |
concrete.urls.paths.marketplace.purchases | /marketplace/connect/-/get_available_licenses |
concrete.urls.paths.marketplace.item_information | /marketplace/connect/-/get_item_information |
concrete.urls.paths.marketplace.item_free_license | /marketplace/connect/-/enable_free_license |
concrete.urls.paths.marketplace.remote_item_list | /marketplace/ |
concrete.white_label.logo | false |
concrete.white_label.name | false |
concrete.white_label.background_image | null |
concrete.session.name | CONCRETE5 |
concrete.session.handler | file |
concrete.session.redis.database | 1 |
concrete.session.save_path | null |
concrete.session.max_lifetime | 7200 |
concrete.session.gc_probability | 1 |
concrete.session.gc_divisor | 100 |
concrete.session.cookie.cookie_path | false |
concrete.session.cookie.cookie_lifetime | 0 |
concrete.session.cookie.cookie_domain | false |
concrete.session.cookie.cookie_secure | false |
concrete.session.cookie.cookie_httponly | true |
concrete.session.cookie.cookie_raw | false |
concrete.session.cookie.cookie_samesite | null |
concrete.session.remember_me.lifetime | 1209600 |
concrete.user.registration.enabled | false |
concrete.user.registration.type | disabled |
concrete.user.registration.captcha | true |
concrete.user.registration.email_registration | false |
concrete.user.registration.display_username_field | true |
concrete.user.registration.display_confirm_password_field | true |
concrete.user.registration.validate_email | false |
concrete.user.registration.approval | false |
concrete.user.registration.notification | false |
concrete.user.group.badge.default_point_value | 50 |
concrete.user.username.maximum | 64 |
concrete.user.username.minimum | 3 |
concrete.user.username.allowed_characters.boundary | A-Za-z0-9 |
concrete.user.username.allowed_characters.middle | A-Za-z0-9_\. |
concrete.user.username.allowed_characters.requirement_string | A username may only contain letters, numbers, dots (not at the beginning/end), and underscores (not at the beginning/end). |
concrete.user.username.allowed_characters.error_string | A username may only contain letters, numbers, dots (not at the beginning/end), and underscores (not at the beginning/end). |
concrete.user.password.maximum | 128 |
concrete.user.password.minimum | 5 |
concrete.user.password.required_special_characters | 0 |
concrete.user.password.required_lower_case | 0 |
concrete.user.password.required_upper_case | 0 |
concrete.user.password.reuse | 0 |
concrete.user.password.hash_portable | false |
concrete.user.password.hash_cost_log2 | 12 |
concrete.user.password.legacy_salt | |
concrete.user.email.test_mx_record | false |
concrete.user.email.strict | true |
concrete.user.private_messages.throttle_max | 20 |
concrete.user.private_messages.throttle_max_timespan | 15 |
concrete.user.deactivation.enable_login_threshold_deactivation | false |
concrete.user.deactivation.login.threshold | 120 |
concrete.user.deactivation.authentication_failure.enabled | false |
concrete.user.deactivation.authentication_failure.amount | 5 |
concrete.user.deactivation.authentication_failure.duration | 300 |
concrete.user.deactivation.message | This user is inactive. Please contact us regarding this account. |
concrete.spam.whitelist_group | 0 |
concrete.spam.notify_email | |
concrete.calendar.colors.text | #ffffff |
concrete.calendar.colors.background | #3A87AD |
concrete.security.session.invalidate_on_user_agent_mismatch | true |
concrete.security.session.invalidate_on_ip_mismatch | true |
concrete.security.session.invalidate_inactive_users.enabled | false |
concrete.security.session.invalidate_inactive_users.time | 300 |
concrete.security.misc.x_frame_options | SAMEORIGIN |
concrete.permissions.forward_to_login | true |
concrete.permissions.model | simple |
concrete.seo.exclude_words | a, an, as, at, before, but, by, for, from, is, in, into, like, of, off, on, onto, per, since, than, the, this, that, to, up, via, with |
concrete.seo.url_rewriting | 0 |
concrete.seo.url_rewriting_all | false |
concrete.seo.redirect_to_canonical_url | 0 |
concrete.seo.canonical_url | http://elmuseolatino.org |
concrete.seo.canonical_url_alternative | null |
concrete.seo.trailing_slash | false |
concrete.seo.title_format | %2$s :: %1$s |
concrete.seo.title_segment_separator | :: |
concrete.seo.page_path_separator | - |
concrete.seo.group_name_separator | / |
concrete.seo.segment_max_length | 128 |
concrete.seo.paging_string | ccm_paging_p |
concrete.seo.canonical_ssl_url | |
concrete.statistics.track_downloads | true |
concrete.limits.sitemap_pages | 100 |
concrete.limits.delete_pages | 100 |
concrete.limits.copy_pages | 10 |
concrete.limits.page_search_index_batch | 200 |
concrete.limits.job_queue_batch | 10 |
concrete.limits.style_customizer.size_min | -50 |
concrete.limits.style_customizer.size_max | 200 |
concrete.page.search.always_reindex | false |
concrete.composer.idle_timeout | 1 |
concrete.api.enabled | false |
concrete.api.grant_types.client_credentials | true |
concrete.api.grant_types.authorization_code | true |
concrete.api.grant_types.password_credentials | false |
concrete.api.grant_types.refresh_token | true |
concrete.mutex.semaphore.priority | 100 |
concrete.mutex.semaphore.class | Concrete\Core\System\Mutex\SemaphoreMutex |
concrete.mutex.file_lock.priority | 50 |
concrete.mutex.file_lock.class | Concrete\Core\System\Mutex\FileLockMutex |
concrete.site | El Museo Latino |
concrete.version_db_installed | 20200609145307 |
Key | Value |
TZ | America/Los_Angeles |
REDIRECT_REDIRECT_UNIQUE_ID | ZgUybjU4AANDVO3jE5htvQAAAAM |
REDIRECT_REDIRECT_SCRIPT_URL | /events/calendar |
REDIRECT_REDIRECT_SCRIPT_URI | http://elmuseolatino.org/events/calendar |
REDIRECT_REDIRECT_STATUS | 200 |
REDIRECT_UNIQUE_ID | ZgUybjU4AANDVO3jE5htvQAAAAM |
REDIRECT_SCRIPT_URL | /events/calendar |
REDIRECT_SCRIPT_URI | http://elmuseolatino.org/events/calendar |
REDIRECT_HANDLER | application/x-httpd-ea-php74 |
REDIRECT_STATUS | 200 |
UNIQUE_ID | ZgUybjU4AANDVO3jE5htvQAAAAM |
SCRIPT_URL | /events/calendar |
SCRIPT_URI | http://elmuseolatino.org/events/calendar |
HTTP_ACCEPT | */* |
HTTP_USER_AGENT | claudebot |
HTTP_HOST | elmuseolatino.org |
PATH | /usr/local/jdk/bin:/usr/kerberos/sbin:/usr/kerberos/bin:/usr/local/sbin:/usr/local/bin:/sbin:/bin:/usr/sbin:/usr/bin:/usr/X11R6/bin:/usr/local/bin:/usr/X11R6/bin:/root/bin:/opt/bin |
SERVER_SIGNATURE | |
SERVER_SOFTWARE | Apache |
SERVER_NAME | elmuseolatino.org |
SERVER_ADDR | 204.152.217.50 |
SERVER_PORT | 80 |
REMOTE_ADDR | 44.215.110.142 |
DOCUMENT_ROOT | /home/elmuseol/public_html |
REQUEST_SCHEME | http |
CONTEXT_PREFIX | /cgi-sys |
CONTEXT_DOCUMENT_ROOT | /usr/local/cpanel/cgi-sys/ |
SERVER_ADMIN | webmaster@elmuseolatino.org |
SCRIPT_FILENAME | /home/elmuseol/public_html/index.php |
REMOTE_PORT | 46264 |
REDIRECT_URL | /index.php |
GATEWAY_INTERFACE | CGI/1.1 |
SERVER_PROTOCOL | HTTP/1.1 |
REQUEST_METHOD | GET |
QUERY_STRING | |
REQUEST_URI | /events/calendar |
SCRIPT_NAME | /index.php |
ORIG_SCRIPT_FILENAME | /usr/local/cpanel/cgi-sys/ea-php74 |
ORIG_PATH_INFO | /index.php |
ORIG_PATH_TRANSLATED | /home/elmuseol/public_html/index.php |
ORIG_SCRIPT_NAME | /cgi-sys/ea-php74 |
PHP_SELF | /index.php |
REQUEST_TIME_FLOAT | 1711616622.5626 |
REQUEST_TIME | 1711616622 |
argv | Array ( ) |
argc | 0 |