rework from legacy code on legacy container with php 5. Ahora si, todos los otros commits eran cualca, estaba mandando el stash a . y estaba un dir encima de la raiz del repo
This commit is contained in:
parent
3fe938ac5d
commit
f3838d8398
@ -1,7 +1,14 @@
|
||||
{
|
||||
"name": "slim/slim-skeleton",
|
||||
"description": "Groups Geometry and Dynamics, ICM2018 Satellite, Web Project",
|
||||
"keywords": ["ICM2018", "GGDWorkshop", "Montevideo","Math","Groups","Geometry"],
|
||||
"keywords": [
|
||||
"ICM2018",
|
||||
"GGDWorkshop",
|
||||
"Montevideo",
|
||||
"Math",
|
||||
"Groups",
|
||||
"Geometry"
|
||||
],
|
||||
"homepage": "https://ggdworkshop.cmat.edu.uy",
|
||||
"license": "GPLv2",
|
||||
"authors": [
|
||||
@ -12,24 +19,15 @@
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"php": ">=5.5.0",
|
||||
"slim/slim": "^3.1",
|
||||
"php": ">=8.2",
|
||||
"slim/slim": "^4.14",
|
||||
"monolog/monolog": "^1.17",
|
||||
"slim/twig-view": "^2.3",
|
||||
"slim/twig-view": "^3.4",
|
||||
"google/recaptcha": "^1.1",
|
||||
"kanellov/slim-twig-flash": "^0.2.0",
|
||||
"phpmailer/phpmailer": "~6.0",
|
||||
"tuupola/slim-basic-auth": "^3.2",
|
||||
"symfony/yaml": "^5.0"
|
||||
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": ">=4.8 < 6.0"
|
||||
},
|
||||
"autoload-dev": {
|
||||
"psr-4": {
|
||||
"Tests\\": "tests/"
|
||||
}
|
||||
"slim/flash": "^0.4.0",
|
||||
"slim/psr7": "^1.7",
|
||||
"php-di/php-di": "^7.0",
|
||||
"symfony/yaml": "^7.1"
|
||||
},
|
||||
"config": {
|
||||
"process-timeout": 0
|
||||
@ -38,5 +36,4 @@
|
||||
"start": "php -S localhost:8080 -t public",
|
||||
"test": "phpunit"
|
||||
}
|
||||
|
||||
}
|
2549
composer.lock
generated
2549
composer.lock
generated
File diff suppressed because it is too large
Load Diff
45
nginx.template (1).conf
Executable file
45
nginx.template (1).conf
Executable file
@ -0,0 +1,45 @@
|
||||
worker_processes 5;
|
||||
daemon off;
|
||||
|
||||
worker_rlimit_nofile 8192;
|
||||
|
||||
events {
|
||||
worker_connections 4096; # Default: 1024
|
||||
}
|
||||
|
||||
http {
|
||||
include $!{nginx}/conf/mime.types;
|
||||
index index.html index.htm index.php;
|
||||
|
||||
default_type application/octet-stream;
|
||||
log_format main '$remote_addr - $remote_user [$time_local] $status '
|
||||
'"$request" $body_bytes_sent "$http_referer" '
|
||||
'"$http_user_agent" "$http_x_forwarded_for"';
|
||||
access_log /dev/stdout;
|
||||
error_log /dev/stdout;
|
||||
sendfile on;
|
||||
tcp_nopush on;
|
||||
server_names_hash_bucket_size 128; # this seems to be required for some vhosts
|
||||
|
||||
server {
|
||||
listen 80;
|
||||
server_name localhost;
|
||||
index index.php index.html index.html;
|
||||
add_header X-Frame-Options "SAMEORIGIN";
|
||||
add_header X-Content-Type-Options "nosniff";
|
||||
charset utf-8;
|
||||
root /app/public;
|
||||
location / {
|
||||
try_files $uri /index.php$is_args$args;
|
||||
}
|
||||
location ~ \.php$ {
|
||||
try_files $uri =404;
|
||||
fastcgi_split_path_info ^(.+\.php)(/.+)$;
|
||||
fastcgi_pass 127.0.0.1:9000;
|
||||
fastcgi_index index.php;
|
||||
fastcgi_param SCRIPT_FILENAME $realpath_root$fastcgi_script_name;
|
||||
include $!{nginx}/conf/fastcgi_params;
|
||||
include $!{nginx}/conf/fastcgi.conf;
|
||||
}
|
||||
}
|
||||
}
|
@ -1,9 +1,28 @@
|
||||
<?php
|
||||
class DB{
|
||||
private $pdo;
|
||||
public static $instance = null;
|
||||
private $pdo=null;
|
||||
|
||||
public function __construct($dbpdo){
|
||||
$this->pdo = $dbpdo;
|
||||
public static function opendatabase(){
|
||||
$instance = self::$instance;
|
||||
try{
|
||||
if($instance==null){
|
||||
$instance=new PDO("sqlite:".__DIR__."/../db/clam2021.db","","",array(
|
||||
PDO::ATTR_PERSISTENT => true
|
||||
));
|
||||
$instance->setAttribute( \PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION );
|
||||
$instance->setAttribute(\PDO::ATTR_DEFAULT_FETCH_MODE, \PDO::FETCH_ASSOC);
|
||||
}
|
||||
return $instance;
|
||||
}catch(PDOException $e){
|
||||
// logerror($e->getMessage(), "opendatabase");
|
||||
// print "Error in openhrsedb ".$e->getMessage();
|
||||
throw($e);
|
||||
}
|
||||
}
|
||||
public function __construct(){
|
||||
$this->pdo = DB::opendatabase();
|
||||
// var_dump($this->pdo);
|
||||
}
|
||||
|
||||
public function loadSchema($schema_file){
|
@ -1,39 +1,60 @@
|
||||
<?php
|
||||
// DIC configuration
|
||||
use Symfony\Component\Yaml\Yaml;
|
||||
$container = $app->getContainer();
|
||||
use DI\Container;
|
||||
use Slim\Flash\Messages;
|
||||
|
||||
$container['flash'] = function($c){
|
||||
$container = new Container();
|
||||
|
||||
|
||||
$container->set('settings', function(){
|
||||
return [
|
||||
'displayErrorDetails' => true, // set to false in production
|
||||
'addContentLengthHeader' => false, // Allow the web server to send the content-length header
|
||||
'debug' => false,
|
||||
'testing' => false,
|
||||
'close_registration' => true,
|
||||
|
||||
// Renderer settings
|
||||
'renderer' => [
|
||||
'template_path' => __DIR__ . '/../templates/',
|
||||
//'cache_path' => __DIR__.'/../templates/.cache/',
|
||||
'cache_path' => false,
|
||||
'autoreload' => true,
|
||||
'debug' => true
|
||||
],
|
||||
|
||||
|
||||
'db' => [
|
||||
'schema' => __DIR__."/../db/schema.sql",
|
||||
'load_schema' => __DIR__."/../db/.schema.lock"
|
||||
],
|
||||
'recaptcha' => [
|
||||
'secret' => "6LesRDsUAAAAAA6t3UgL4U4Foc9njmXX-8HIiLj_",
|
||||
'secrettest' => "6LeIxAcTAAAAAGG-vFI1TnRWxMZNFuojJ4WifJWe",
|
||||
'sitekey' => "6LesRDsUAAAAAJvyoODvjiza9u75qEGJmbKHEV6s",
|
||||
'sitekeytest' => "6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI"
|
||||
],
|
||||
|
||||
];
|
||||
});
|
||||
|
||||
$container->set('flash', function($c){
|
||||
$storage = [];
|
||||
return new Messages($storage);
|
||||
return new \Slim\Flash\Messages();
|
||||
};
|
||||
|
||||
$container['renderer'] = function ($c) {
|
||||
$settings = $c->get('settings')['renderer'];
|
||||
|
||||
$view = new Slim\Views\Twig($settings['template_path'],[
|
||||
'cache' => $settings['cache_path'],
|
||||
});
|
||||
|
||||
|
||||
]);
|
||||
|
||||
$view->addExtension(new Knlv\Slim\Views\TwigMessages(
|
||||
$c->get('flash')
|
||||
));
|
||||
$noticias = Yaml::parseFile(__DIR__."/../data/noticias.yml");
|
||||
$sponsors = Yaml::parseFile(__DIR__."/../data/sponsors.yml");
|
||||
$view->getEnvironment()->addGlobal('noticias',$noticias);
|
||||
$view->getEnvironment()->addGlobal('sponsors',$sponsors);
|
||||
|
||||
return $view;
|
||||
};
|
||||
|
||||
$container['db'] = function ($c) {
|
||||
$dbconf = $c->get('settings')['db'];
|
||||
$container->set('db', function ($c) {
|
||||
$dbconf = [
|
||||
'schema' => __DIR__."/../db/schema.sql",
|
||||
'load_schema' => __DIR__."/../db/.schema.lock"
|
||||
];
|
||||
$db = new DB();
|
||||
try{
|
||||
$pdo = new PDO('sqlite:'.$dbconf['path']);
|
||||
$pdo->setAttribute( \PDO::ATTR_ERRMODE, \PDO::ERRMODE_EXCEPTION );
|
||||
$pdo->setAttribute(\PDO::ATTR_DEFAULT_FETCH_MODE, \PDO::FETCH_ASSOC);
|
||||
$db = new DB($pdo);
|
||||
|
||||
if(!file_exists($dbconf['load_schema'])){
|
||||
$db->loadSchema($dbconf['schema']);
|
||||
touch($dbconf['load_schema']);
|
||||
@ -44,16 +65,5 @@ $container['db'] = function ($c) {
|
||||
echo $e->getMessage();
|
||||
}
|
||||
return $db;
|
||||
};
|
||||
// monolog
|
||||
$container['logger'] = function ($c) {
|
||||
$settings = $c->get('settings')['logger'];
|
||||
$logger = new Monolog\Logger($settings['name']);
|
||||
$logger->pushProcessor(new Monolog\Processor\UidProcessor());
|
||||
$logger->pushHandler(new Monolog\Handler\StreamHandler($settings['path'], $settings['level']));
|
||||
return $logger;
|
||||
};
|
||||
});
|
||||
|
||||
/*$container['mailer'] =function ($c){
|
||||
|
||||
};*/
|
||||
|
@ -1,4 +1,12 @@
|
||||
<?php
|
||||
|
||||
// Application middleware
|
||||
|
||||
// e.g: $app->add(new \Slim\Csrf\Guard);
|
||||
use Slim\Views\Twig;
|
||||
use Slim\Views\TwigMiddleware;
|
||||
|
||||
// Create Twig
|
||||
$twig = Twig::create(__DIR__ . '/../templates', ['cache' => false]);
|
||||
|
||||
// Add Twig-View Middleware
|
||||
$app->add(TwigMiddleware::create($app, $twig));
|
119
src/routes.php
119
src/routes.php
@ -1,8 +1,10 @@
|
||||
<?php
|
||||
|
||||
use Slim\Http\Request;
|
||||
use Slim\Http\Response;
|
||||
use Psr\Http\Message\ResponseInterface as Response;
|
||||
use Psr\Http\Message\ServerRequestInterface as Request;
|
||||
use Slim\Views\Twig;
|
||||
use Symfony\Component\Yaml\Yaml;
|
||||
|
||||
function getSesiones($id=NULL){
|
||||
$sesiones = Yaml::parseFile(__DIR__."/../data/sesiones.yml");
|
||||
|
||||
@ -54,33 +56,36 @@ function getEventos($tipo){
|
||||
}
|
||||
}
|
||||
// Routes
|
||||
$app->add(new Tuupola\Middleware\HttpBasicAuthentication([
|
||||
"path" => ["/inscriptos", "inscriptoscsv"], /* or ["/admin", "/api"] */
|
||||
"realm" => "Protected",
|
||||
"secure" => false,
|
||||
"users" => [
|
||||
"admin" => "puntofijo"
|
||||
]
|
||||
]));
|
||||
// $app->add(new Tuupola\Middleware\HttpBasicAuthentication([
|
||||
// "path" => ["/inscriptos", "inscriptoscsv"], /* or ["/admin", "/api"] */
|
||||
// "realm" => "Protected",
|
||||
// "secure" => false,
|
||||
// "users" => [
|
||||
// "admin" => "puntofijo"
|
||||
// ]
|
||||
// ]));
|
||||
|
||||
$app->get('/', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/' route");
|
||||
return $this->renderer->render($response, 'index.html', $args);
|
||||
////$this->logger->info("GDDWorkshop '/' route");
|
||||
$view = Twig::fromRequest($request);
|
||||
return $view->render($response, 'index.html', $args);
|
||||
});
|
||||
$app->get('/descripcion', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/descripcion' route");
|
||||
return $this->renderer->render($response, 'descripcion.html', $args);
|
||||
$view = Twig::fromRequest($request);
|
||||
//$this->logger->info("GDDWorkshop '/descripcion' route");
|
||||
return $view->render($response, 'descripcion.html', $args);
|
||||
});
|
||||
|
||||
$app->get('/registrarse', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/registrtion' route");
|
||||
$view = Twig::fromRequest($request);
|
||||
//$this->logger->info("GDDWorkshop '/registrtion' route");
|
||||
$recapsitekey = $this->settings["recaptcha"]["sitekey"];
|
||||
if($this->settings["testing"]){
|
||||
$recapsitekey = $this->settings["recaptcha"]["sitekeytest"];
|
||||
}
|
||||
$hoy=strtotime(date("Y-m-d H:i:s"));
|
||||
$fechaCierre = strtotime($this->settings['close_registration']);
|
||||
return $this->renderer->render($response, 'registration.html',
|
||||
return $view->render($response, 'registration.html',
|
||||
[
|
||||
'closed' => $hoy>$fechaCierre,
|
||||
'sitekey' => $recapsitekey
|
||||
@ -89,8 +94,9 @@ $app->get('/registrarse', function (Request $request, Response $response, array
|
||||
|
||||
|
||||
$app->get('/participantes', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/participants' route");
|
||||
$db = $this->db;
|
||||
$view = Twig::fromRequest($request);
|
||||
//$this->logger->info("GDDWorkshop '/participants' route");
|
||||
$db = $this->get('db');
|
||||
$data = $db->getAll();
|
||||
$result = array('Estudiante de grado'=>array(),'Estudiante de posgrado'=>array(),'Profesor'=>array(),'Posdoctorando'=>array(),'Otro'=>array());
|
||||
foreach ($data as $element) {
|
||||
@ -114,26 +120,28 @@ $app->get('/participantes', function (Request $request, Response $response, arra
|
||||
}
|
||||
//echo '<pre>' . json_encode($result,JSON_PRETTY_PRINT). '</pre>';
|
||||
|
||||
return $this->renderer->render($response, 'participants.html', ['registros' => $result]);
|
||||
return $view->render($response, 'participants.html', ['registros' => $result]);
|
||||
});
|
||||
|
||||
|
||||
$app->get('/comites', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/committess' route");
|
||||
//$this->logger->info("GDDWorkshop '/committess' route");
|
||||
$view = Twig::fromRequest($request);
|
||||
$comites = Yaml::parseFile(__DIR__."/../data/comites.yml");
|
||||
//$strcomites = file_get_contents(__DIR__."/../data/comites.json");
|
||||
//$comites = json_decode($strcomites,true);
|
||||
//echo "<pre>".var_export($comites,true)."</pre>";
|
||||
return $this->renderer->render($response, 'committess.html',['comites' => $comites]);
|
||||
return $view->render($response, 'committess.html',['comites' => $comites]);
|
||||
});
|
||||
|
||||
$app->get('/informacion-practica', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/practicalinfo' route");
|
||||
return $this->renderer->render($response, 'practicalinfo.html', $args);
|
||||
//$this->logger->info("GDDWorkshop '/practicalinfo' route");
|
||||
$view = Twig::fromRequest($request);
|
||||
return $view->render($response, 'practicalinfo.html', $args);
|
||||
});
|
||||
|
||||
$app->get('/conferencias', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/charlas' route");
|
||||
//$this->logger->info("GDDWorkshop '/charlas' route");
|
||||
//$strcharlas = file_get_contents(__DIR__."/../data/conferencias.json");
|
||||
|
||||
$charlas = Yaml::parseFile(__DIR__."/../data/conferencias.yml");
|
||||
@ -160,12 +168,13 @@ $app->get('/conferencias', function (Request $request, Response $response, array
|
||||
}
|
||||
}
|
||||
//return $response->withJson($charlas);
|
||||
return $this->renderer->render($response, 'conferencias.html',
|
||||
$view = Twig::fromRequest($request);
|
||||
return $view->render($response, 'conferencias.html',
|
||||
['charlas' => $charlas]);
|
||||
});
|
||||
$app->group('/sesiones',function($app){
|
||||
$app->get('', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/sesiones' route");
|
||||
//$this->logger->info("GDDWorkshop '/sesiones' route");
|
||||
/*$sesiones = Yaml::parseFile(__DIR__."/../data/sesiones.yml");
|
||||
|
||||
function removeAccents($string) {
|
||||
@ -180,7 +189,8 @@ $app->group('/sesiones',function($app){
|
||||
$sesiones = getSesiones();
|
||||
|
||||
//echo "<pre>".var_export($sesiones,true)."</pre>";
|
||||
return $this->renderer->render($response, 'sesiones.html', ["sesiones"=>array_chunk($sesiones,5,true)]);
|
||||
$view = Twig::fromRequest($request);
|
||||
return $view->render($response, 'sesiones.html', ["sesiones"=>array_chunk($sesiones,5,true)]);
|
||||
});
|
||||
$app->get('/{sesionId}', function (Request $request, Response $response, array $args) {
|
||||
$sesion = getSesiones($args['sesionId']);
|
||||
@ -197,7 +207,8 @@ $app->group('/sesiones',function($app){
|
||||
return $acc;
|
||||
},[]);
|
||||
|
||||
return $this->renderer->render($response, 'sesion.html', ["sesion"=>$sesion,"charlas"=>$charlas]);
|
||||
$view = Twig::fromRequest($request);
|
||||
return $view->render($response, 'sesion.html', ["sesion"=>$sesion,"charlas"=>$charlas]);
|
||||
|
||||
});
|
||||
$app->get('/group/{sesionId}', function (Request $request, Response $response, array $args) {
|
||||
@ -217,7 +228,7 @@ $app->group('/sesiones',function($app){
|
||||
},[]);
|
||||
//echo '<pre>' . json_encode($result,JSON_PRETTY_PRINT). '</pre>';
|
||||
return $response->withJson($charlas);
|
||||
//return $this->renderer->render($response, 'sesion.html', ["sesion"=>$sesion]);
|
||||
//return $view->render($response, 'sesion.html', ["sesion"=>$sesion]);
|
||||
|
||||
});
|
||||
|
||||
@ -226,20 +237,22 @@ $app->group('/sesiones',function($app){
|
||||
|
||||
|
||||
$app->get('/calendario', function (Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/program' route");
|
||||
return $this->renderer->render($response, 'program.html', $args);
|
||||
//$this->logger->info("GDDWorkshop '/program' route");
|
||||
$view = Twig::fromRequest($request);
|
||||
return $view->render($response, 'program.html', $args);
|
||||
});
|
||||
|
||||
$app->get('/inscriptos', function(Request $request, Response $response, array $args){
|
||||
$this->logger->info("GDDWorkshop '/practicalinfo' route");
|
||||
$db = $this->db;
|
||||
//$this->logger->info("GDDWorkshop '/practicalinfo' route");
|
||||
$db = $this->get('db');
|
||||
$data = $db->getAll();
|
||||
return $this->renderer->render($response, 'inscriptos.html', ["registros" => $data]);
|
||||
$view = Twig::fromRequest($request);
|
||||
return $view->render($response, 'inscriptos.html', ["registros" => $data]);
|
||||
});
|
||||
|
||||
$app->get('/inscriptoscsv', function(Request $request, Response $response, array $args){
|
||||
$this->logger->info("GDDWorkshop '/practicalinfo' route");
|
||||
$dbfile = $this->settings['db']['path'];
|
||||
//$this->logger->info("GDDWorkshop '/practicalinfo' route");
|
||||
$dbfile = $this->get('settings')['db']['path'];
|
||||
$file = 'inscriptos-surface2018.csv';
|
||||
exec('sqlite3 -header -csv '.$dbfile.' "select * from registro" > "'.$file.'"');
|
||||
|
||||
@ -268,7 +281,6 @@ $mw = function ($request, $response, $next) {
|
||||
// API ROUTES
|
||||
$app->group('/api', function($app){
|
||||
$app->get("/eventos/{tipo:cursos|plenarias|semiplenarias|publicas|premiados|genero}",function(Request $request, Response $response, array $args) {
|
||||
|
||||
if($args['tipo']=="publicas")
|
||||
$tipo="Públicas";
|
||||
else if($args['tipo']=="genero")
|
||||
@ -294,11 +306,16 @@ $app->group('/api', function($app){
|
||||
);
|
||||
}
|
||||
}
|
||||
$newres = $response->withJson($cursos);
|
||||
|
||||
$payload = json_encode($cursos);
|
||||
}
|
||||
else
|
||||
$newres = $response->withJson(getEventos($tipo));
|
||||
return $newres;
|
||||
$payload = json_encode(getEventos($tipo));
|
||||
|
||||
$response->getBody()->write($payload);
|
||||
return $response
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->withStatus(201);
|
||||
});
|
||||
$app->group("/eventos/sesiones/", function($app){
|
||||
$app->get("",function(Request $request, Response $response, array $args){
|
||||
@ -333,18 +350,26 @@ $app->group('/api', function($app){
|
||||
foreach ($sesiones as $ses){
|
||||
|
||||
}
|
||||
return $response->withJson($sesionesEventos);
|
||||
$payload = json_encode($sesionesEventos);
|
||||
$response->getBody()->write($payload);
|
||||
return $response
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->withStatus(201);
|
||||
});
|
||||
$app->get("/{sesionId}",function(Request $request, Response $response, array $args) {
|
||||
|
||||
$newres = $response->withJson(getSesiones($args['sesionId']));
|
||||
return $newres;
|
||||
$payload = $response->withJson(getSesiones($args['sesionId']));
|
||||
$response->getBody()->write($payload);
|
||||
return $response
|
||||
->withHeader('Content-Type', 'application/json')
|
||||
->withStatus(201);
|
||||
|
||||
});
|
||||
|
||||
});
|
||||
|
||||
$app->get("/test", function(Request $request, Response $response, array $args) {
|
||||
$this->logger->info("GDDWorkshop '/api/test' route");
|
||||
//$this->logger->info("GDDWorkshop '/api/test' route");
|
||||
return var_dump($request);
|
||||
|
||||
});
|
||||
@ -352,7 +377,7 @@ $app->group('/api', function($app){
|
||||
$app->post('/register', function (Request $request, Response $response, array $args) {
|
||||
$messages = $this->flash;
|
||||
$data = $request->getParsedBody();
|
||||
$db = $this->db;
|
||||
$db = $this->get('db');
|
||||
$hoy=strtotime(date("Y-m-d H:i:s"));
|
||||
$fechaCierre = strtotime($this->settings['close_registration']);
|
||||
if($hoy>$fechaCierre){
|
||||
@ -405,7 +430,7 @@ $app->group('/api', function($app){
|
||||
$messages->addMessageNow("submit-register-err", $data['email']." ya está registrado<br/>"
|
||||
."Contacte a: <b>clam2021@fing.edu.uy</b>");
|
||||
}catch (Exception $e){
|
||||
$this->logger->debug("Submit register DB error: ".$e->getMessage());
|
||||
//$this->logger->debug("Submit register DB error: ".$e->getMessage());
|
||||
$messages->addMessageNow("submit-register-err", "DB error: ".$e->getMessage());
|
||||
}
|
||||
}
|
||||
@ -420,7 +445,7 @@ $app->group('/api', function($app){
|
||||
try{
|
||||
$db->insert($data);
|
||||
}catch (Exception $e){
|
||||
$this->logger->debug("Submit register DB error: ".$e->getMessage());
|
||||
//$this->logger->debug("Submit register DB error: ".$e->getMessage());
|
||||
$messages->addMessageNow("submit-register-err", "DB error: ".$e->getMessage());
|
||||
}
|
||||
$arrayresponse = array("success" => true,
|
||||
|
@ -1,38 +0,0 @@
|
||||
<?php
|
||||
return [
|
||||
'settings' => [
|
||||
'displayErrorDetails' => true, // set to false in production
|
||||
'addContentLengthHeader' => false, // Allow the web server to send the content-length header
|
||||
'debug' => true,
|
||||
'testing' => false,
|
||||
'close_registration' => "2021-09-08T23:59:00-0300",
|
||||
|
||||
// Renderer settings
|
||||
'renderer' => [
|
||||
'template_path' => __DIR__ . '/../templates/',
|
||||
//'cache_path' => __DIR__.'/../templates/.cache/',
|
||||
'cache_path' => false,
|
||||
'autoreload' => true,
|
||||
'debug' => true
|
||||
],
|
||||
|
||||
// Monolog settings
|
||||
'logger' => [
|
||||
'name' => 'slim-app',
|
||||
'path' => isset($_ENV['docker']) ? 'php://stdout' : __DIR__ . '/../logs/app.log',
|
||||
'level' => \Monolog\Logger::DEBUG,
|
||||
],
|
||||
'db' => [
|
||||
'path' => __DIR__."/../db/clam2021.db",
|
||||
'schema' => __DIR__."/../db/schema.sql",
|
||||
'load_schema' => __DIR__."/../db/.schema.lock"
|
||||
],
|
||||
'recaptcha' => [
|
||||
'secret' => "6LesRDsUAAAAAA6t3UgL4U4Foc9njmXX-8HIiLj_",
|
||||
'secrettest' => "6LeIxAcTAAAAAGG-vFI1TnRWxMZNFuojJ4WifJWe",
|
||||
'sitekey' => "6LesRDsUAAAAAJvyoODvjiza9u75qEGJmbKHEV6s",
|
||||
'sitekeytest' => "6LeIxAcTAAAAAJcZVRqyHh71UMIEGNQ_MXjiZKhI"
|
||||
],
|
||||
|
||||
],
|
||||
];
|
18
vendor/autoload.php
vendored
18
vendor/autoload.php
vendored
@ -2,6 +2,24 @@
|
||||
|
||||
// autoload.php @generated by Composer
|
||||
|
||||
if (PHP_VERSION_ID < 50600) {
|
||||
if (!headers_sent()) {
|
||||
header('HTTP/1.1 500 Internal Server Error');
|
||||
}
|
||||
$err = 'Composer 2.3.0 dropped support for autoloading on PHP <5.6 and you are running '.PHP_VERSION.', please upgrade PHP or use Composer 2.2 LTS via "composer self-update --2.2". Aborting.'.PHP_EOL;
|
||||
if (!ini_get('display_errors')) {
|
||||
if (PHP_SAPI === 'cli' || PHP_SAPI === 'phpdbg') {
|
||||
fwrite(STDERR, $err);
|
||||
} elseif (!headers_sent()) {
|
||||
echo $err;
|
||||
}
|
||||
}
|
||||
trigger_error(
|
||||
$err,
|
||||
E_USER_ERROR
|
||||
);
|
||||
}
|
||||
|
||||
require_once __DIR__ . '/composer/autoload_real.php';
|
||||
|
||||
return ComposerAutoloaderInit0dd15d1e9d08041097652a874300c62a::getLoader();
|
||||
|
1
vendor/bin/phpunit
vendored
1
vendor/bin/phpunit
vendored
@ -1 +0,0 @@
|
||||
../phpunit/phpunit/phpunit
|
178
vendor/composer/ClassLoader.php
vendored
178
vendor/composer/ClassLoader.php
vendored
@ -37,57 +37,126 @@ namespace Composer\Autoload;
|
||||
*
|
||||
* @author Fabien Potencier <fabien@symfony.com>
|
||||
* @author Jordi Boggiano <j.boggiano@seld.be>
|
||||
* @see http://www.php-fig.org/psr/psr-0/
|
||||
* @see http://www.php-fig.org/psr/psr-4/
|
||||
* @see https://www.php-fig.org/psr/psr-0/
|
||||
* @see https://www.php-fig.org/psr/psr-4/
|
||||
*/
|
||||
class ClassLoader
|
||||
{
|
||||
/** @var \Closure(string):void */
|
||||
private static $includeFile;
|
||||
|
||||
/** @var string|null */
|
||||
private $vendorDir;
|
||||
|
||||
// PSR-4
|
||||
/**
|
||||
* @var array<string, array<string, int>>
|
||||
*/
|
||||
private $prefixLengthsPsr4 = array();
|
||||
/**
|
||||
* @var array<string, list<string>>
|
||||
*/
|
||||
private $prefixDirsPsr4 = array();
|
||||
/**
|
||||
* @var list<string>
|
||||
*/
|
||||
private $fallbackDirsPsr4 = array();
|
||||
|
||||
// PSR-0
|
||||
/**
|
||||
* List of PSR-0 prefixes
|
||||
*
|
||||
* Structured as array('F (first letter)' => array('Foo\Bar (full prefix)' => array('path', 'path2')))
|
||||
*
|
||||
* @var array<string, array<string, list<string>>>
|
||||
*/
|
||||
private $prefixesPsr0 = array();
|
||||
/**
|
||||
* @var list<string>
|
||||
*/
|
||||
private $fallbackDirsPsr0 = array();
|
||||
|
||||
/** @var bool */
|
||||
private $useIncludePath = false;
|
||||
|
||||
/**
|
||||
* @var array<string, string>
|
||||
*/
|
||||
private $classMap = array();
|
||||
|
||||
/** @var bool */
|
||||
private $classMapAuthoritative = false;
|
||||
|
||||
/**
|
||||
* @var array<string, bool>
|
||||
*/
|
||||
private $missingClasses = array();
|
||||
|
||||
/** @var string|null */
|
||||
private $apcuPrefix;
|
||||
|
||||
/**
|
||||
* @var array<string, self>
|
||||
*/
|
||||
private static $registeredLoaders = array();
|
||||
|
||||
/**
|
||||
* @param string|null $vendorDir
|
||||
*/
|
||||
public function __construct($vendorDir = null)
|
||||
{
|
||||
$this->vendorDir = $vendorDir;
|
||||
self::initializeIncludeClosure();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array<string, list<string>>
|
||||
*/
|
||||
public function getPrefixes()
|
||||
{
|
||||
if (!empty($this->prefixesPsr0)) {
|
||||
return call_user_func_array('array_merge', $this->prefixesPsr0);
|
||||
return call_user_func_array('array_merge', array_values($this->prefixesPsr0));
|
||||
}
|
||||
|
||||
return array();
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array<string, list<string>>
|
||||
*/
|
||||
public function getPrefixesPsr4()
|
||||
{
|
||||
return $this->prefixDirsPsr4;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return list<string>
|
||||
*/
|
||||
public function getFallbackDirs()
|
||||
{
|
||||
return $this->fallbackDirsPsr0;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return list<string>
|
||||
*/
|
||||
public function getFallbackDirsPsr4()
|
||||
{
|
||||
return $this->fallbackDirsPsr4;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return array<string, string> Array of classname => path
|
||||
*/
|
||||
public function getClassMap()
|
||||
{
|
||||
return $this->classMap;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param array $classMap Class to filename map
|
||||
* @param array<string, string> $classMap Class to filename map
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function addClassMap(array $classMap)
|
||||
{
|
||||
@ -103,21 +172,24 @@ class ClassLoader
|
||||
* appending or prepending to the ones previously set for this prefix.
|
||||
*
|
||||
* @param string $prefix The prefix
|
||||
* @param array|string $paths The PSR-0 root directories
|
||||
* @param list<string>|string $paths The PSR-0 root directories
|
||||
* @param bool $prepend Whether to prepend the directories
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function add($prefix, $paths, $prepend = false)
|
||||
{
|
||||
$paths = (array) $paths;
|
||||
if (!$prefix) {
|
||||
if ($prepend) {
|
||||
$this->fallbackDirsPsr0 = array_merge(
|
||||
(array) $paths,
|
||||
$paths,
|
||||
$this->fallbackDirsPsr0
|
||||
);
|
||||
} else {
|
||||
$this->fallbackDirsPsr0 = array_merge(
|
||||
$this->fallbackDirsPsr0,
|
||||
(array) $paths
|
||||
$paths
|
||||
);
|
||||
}
|
||||
|
||||
@ -126,19 +198,19 @@ class ClassLoader
|
||||
|
||||
$first = $prefix[0];
|
||||
if (!isset($this->prefixesPsr0[$first][$prefix])) {
|
||||
$this->prefixesPsr0[$first][$prefix] = (array) $paths;
|
||||
$this->prefixesPsr0[$first][$prefix] = $paths;
|
||||
|
||||
return;
|
||||
}
|
||||
if ($prepend) {
|
||||
$this->prefixesPsr0[$first][$prefix] = array_merge(
|
||||
(array) $paths,
|
||||
$paths,
|
||||
$this->prefixesPsr0[$first][$prefix]
|
||||
);
|
||||
} else {
|
||||
$this->prefixesPsr0[$first][$prefix] = array_merge(
|
||||
$this->prefixesPsr0[$first][$prefix],
|
||||
(array) $paths
|
||||
$paths
|
||||
);
|
||||
}
|
||||
}
|
||||
@ -148,24 +220,27 @@ class ClassLoader
|
||||
* appending or prepending to the ones previously set for this namespace.
|
||||
*
|
||||
* @param string $prefix The prefix/namespace, with trailing '\\'
|
||||
* @param array|string $paths The PSR-4 base directories
|
||||
* @param list<string>|string $paths The PSR-4 base directories
|
||||
* @param bool $prepend Whether to prepend the directories
|
||||
*
|
||||
* @throws \InvalidArgumentException
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function addPsr4($prefix, $paths, $prepend = false)
|
||||
{
|
||||
$paths = (array) $paths;
|
||||
if (!$prefix) {
|
||||
// Register directories for the root namespace.
|
||||
if ($prepend) {
|
||||
$this->fallbackDirsPsr4 = array_merge(
|
||||
(array) $paths,
|
||||
$paths,
|
||||
$this->fallbackDirsPsr4
|
||||
);
|
||||
} else {
|
||||
$this->fallbackDirsPsr4 = array_merge(
|
||||
$this->fallbackDirsPsr4,
|
||||
(array) $paths
|
||||
$paths
|
||||
);
|
||||
}
|
||||
} elseif (!isset($this->prefixDirsPsr4[$prefix])) {
|
||||
@ -175,18 +250,18 @@ class ClassLoader
|
||||
throw new \InvalidArgumentException("A non-empty PSR-4 prefix must end with a namespace separator.");
|
||||
}
|
||||
$this->prefixLengthsPsr4[$prefix[0]][$prefix] = $length;
|
||||
$this->prefixDirsPsr4[$prefix] = (array) $paths;
|
||||
$this->prefixDirsPsr4[$prefix] = $paths;
|
||||
} elseif ($prepend) {
|
||||
// Prepend directories for an already registered namespace.
|
||||
$this->prefixDirsPsr4[$prefix] = array_merge(
|
||||
(array) $paths,
|
||||
$paths,
|
||||
$this->prefixDirsPsr4[$prefix]
|
||||
);
|
||||
} else {
|
||||
// Append directories for an already registered namespace.
|
||||
$this->prefixDirsPsr4[$prefix] = array_merge(
|
||||
$this->prefixDirsPsr4[$prefix],
|
||||
(array) $paths
|
||||
$paths
|
||||
);
|
||||
}
|
||||
}
|
||||
@ -196,7 +271,9 @@ class ClassLoader
|
||||
* replacing any others previously set for this prefix.
|
||||
*
|
||||
* @param string $prefix The prefix
|
||||
* @param array|string $paths The PSR-0 base directories
|
||||
* @param list<string>|string $paths The PSR-0 base directories
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function set($prefix, $paths)
|
||||
{
|
||||
@ -212,9 +289,11 @@ class ClassLoader
|
||||
* replacing any others previously set for this namespace.
|
||||
*
|
||||
* @param string $prefix The prefix/namespace, with trailing '\\'
|
||||
* @param array|string $paths The PSR-4 base directories
|
||||
* @param list<string>|string $paths The PSR-4 base directories
|
||||
*
|
||||
* @throws \InvalidArgumentException
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function setPsr4($prefix, $paths)
|
||||
{
|
||||
@ -234,6 +313,8 @@ class ClassLoader
|
||||
* Turns on searching the include path for class files.
|
||||
*
|
||||
* @param bool $useIncludePath
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function setUseIncludePath($useIncludePath)
|
||||
{
|
||||
@ -256,6 +337,8 @@ class ClassLoader
|
||||
* that have not been registered with the class map.
|
||||
*
|
||||
* @param bool $classMapAuthoritative
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function setClassMapAuthoritative($classMapAuthoritative)
|
||||
{
|
||||
@ -276,6 +359,8 @@ class ClassLoader
|
||||
* APCu prefix to use to cache found/not-found classes, if the extension is enabled.
|
||||
*
|
||||
* @param string|null $apcuPrefix
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function setApcuPrefix($apcuPrefix)
|
||||
{
|
||||
@ -296,33 +381,55 @@ class ClassLoader
|
||||
* Registers this instance as an autoloader.
|
||||
*
|
||||
* @param bool $prepend Whether to prepend the autoloader or not
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function register($prepend = false)
|
||||
{
|
||||
spl_autoload_register(array($this, 'loadClass'), true, $prepend);
|
||||
|
||||
if (null === $this->vendorDir) {
|
||||
return;
|
||||
}
|
||||
|
||||
if ($prepend) {
|
||||
self::$registeredLoaders = array($this->vendorDir => $this) + self::$registeredLoaders;
|
||||
} else {
|
||||
unset(self::$registeredLoaders[$this->vendorDir]);
|
||||
self::$registeredLoaders[$this->vendorDir] = $this;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Unregisters this instance as an autoloader.
|
||||
*
|
||||
* @return void
|
||||
*/
|
||||
public function unregister()
|
||||
{
|
||||
spl_autoload_unregister(array($this, 'loadClass'));
|
||||
|
||||
if (null !== $this->vendorDir) {
|
||||
unset(self::$registeredLoaders[$this->vendorDir]);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Loads the given class or interface.
|
||||
*
|
||||
* @param string $class The name of the class
|
||||
* @return bool|null True if loaded, null otherwise
|
||||
* @return true|null True if loaded, null otherwise
|
||||
*/
|
||||
public function loadClass($class)
|
||||
{
|
||||
if ($file = $this->findFile($class)) {
|
||||
includeFile($file);
|
||||
$includeFile = self::$includeFile;
|
||||
$includeFile($file);
|
||||
|
||||
return true;
|
||||
}
|
||||
|
||||
return null;
|
||||
}
|
||||
|
||||
/**
|
||||
@ -367,6 +474,21 @@ class ClassLoader
|
||||
return $file;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns the currently registered loaders keyed by their corresponding vendor directories.
|
||||
*
|
||||
* @return array<string, self>
|
||||
*/
|
||||
public static function getRegisteredLoaders()
|
||||
{
|
||||
return self::$registeredLoaders;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param string $class
|
||||
* @param string $ext
|
||||
* @return string|false
|
||||
*/
|
||||
private function findFileWithExtension($class, $ext)
|
||||
{
|
||||
// PSR-4 lookup
|
||||
@ -432,14 +554,26 @@ class ClassLoader
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return void
|
||||
*/
|
||||
private static function initializeIncludeClosure()
|
||||
{
|
||||
if (self::$includeFile !== null) {
|
||||
return;
|
||||
}
|
||||
|
||||
/**
|
||||
* Scope isolated include.
|
||||
*
|
||||
* Prevents access to $this/self from included files.
|
||||
*
|
||||
* @param string $file
|
||||
* @return void
|
||||
*/
|
||||
function includeFile($file)
|
||||
{
|
||||
self::$includeFile = \Closure::bind(static function($file) {
|
||||
include $file;
|
||||
}, null, null);
|
||||
}
|
||||
}
|
||||
|
475
vendor/composer/autoload_classmap.php
vendored
475
vendor/composer/autoload_classmap.php
vendored
@ -2,473 +2,16 @@
|
||||
|
||||
// autoload_classmap.php @generated by Composer
|
||||
|
||||
$vendorDir = dirname(dirname(__FILE__));
|
||||
$vendorDir = dirname(__DIR__);
|
||||
$baseDir = dirname($vendorDir);
|
||||
|
||||
return array(
|
||||
'File_Iterator' => $vendorDir . '/phpunit/php-file-iterator/src/Iterator.php',
|
||||
'File_Iterator_Facade' => $vendorDir . '/phpunit/php-file-iterator/src/Facade.php',
|
||||
'File_Iterator_Factory' => $vendorDir . '/phpunit/php-file-iterator/src/Factory.php',
|
||||
'PHPUnit\\Framework\\Assert' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/Assert.php',
|
||||
'PHPUnit\\Framework\\AssertionFailedError' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/AssertionFailedError.php',
|
||||
'PHPUnit\\Framework\\BaseTestListener' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/BaseTestListener.php',
|
||||
'PHPUnit\\Framework\\Test' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/Test.php',
|
||||
'PHPUnit\\Framework\\TestCase' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/TestCase.php',
|
||||
'PHPUnit\\Framework\\TestListener' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/TestListener.php',
|
||||
'PHPUnit\\Framework\\TestSuite' => $vendorDir . '/phpunit/phpunit/src/ForwardCompatibility/TestSuite.php',
|
||||
'PHPUnit_Exception' => $vendorDir . '/phpunit/phpunit/src/Exception.php',
|
||||
'PHPUnit_Extensions_GroupTestSuite' => $vendorDir . '/phpunit/phpunit/src/Extensions/GroupTestSuite.php',
|
||||
'PHPUnit_Extensions_PhptTestCase' => $vendorDir . '/phpunit/phpunit/src/Extensions/PhptTestCase.php',
|
||||
'PHPUnit_Extensions_PhptTestSuite' => $vendorDir . '/phpunit/phpunit/src/Extensions/PhptTestSuite.php',
|
||||
'PHPUnit_Extensions_RepeatedTest' => $vendorDir . '/phpunit/phpunit/src/Extensions/RepeatedTest.php',
|
||||
'PHPUnit_Extensions_TestDecorator' => $vendorDir . '/phpunit/phpunit/src/Extensions/TestDecorator.php',
|
||||
'PHPUnit_Extensions_TicketListener' => $vendorDir . '/phpunit/phpunit/src/Extensions/TicketListener.php',
|
||||
'PHPUnit_Framework_Assert' => $vendorDir . '/phpunit/phpunit/src/Framework/Assert.php',
|
||||
'PHPUnit_Framework_AssertionFailedError' => $vendorDir . '/phpunit/phpunit/src/Framework/AssertionFailedError.php',
|
||||
'PHPUnit_Framework_BaseTestListener' => $vendorDir . '/phpunit/phpunit/src/Framework/BaseTestListener.php',
|
||||
'PHPUnit_Framework_CodeCoverageException' => $vendorDir . '/phpunit/phpunit/src/Framework/CodeCoverageException.php',
|
||||
'PHPUnit_Framework_Constraint' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint.php',
|
||||
'PHPUnit_Framework_Constraint_And' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/And.php',
|
||||
'PHPUnit_Framework_Constraint_ArrayHasKey' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ArrayHasKey.php',
|
||||
'PHPUnit_Framework_Constraint_ArraySubset' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php',
|
||||
'PHPUnit_Framework_Constraint_Attribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Attribute.php',
|
||||
'PHPUnit_Framework_Constraint_Callback' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Callback.php',
|
||||
'PHPUnit_Framework_Constraint_ClassHasAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ClassHasAttribute.php',
|
||||
'PHPUnit_Framework_Constraint_ClassHasStaticAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ClassHasStaticAttribute.php',
|
||||
'PHPUnit_Framework_Constraint_Composite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Composite.php',
|
||||
'PHPUnit_Framework_Constraint_Count' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Count.php',
|
||||
'PHPUnit_Framework_Constraint_DirectoryExists' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/DirectoryExists.php',
|
||||
'PHPUnit_Framework_Constraint_Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Exception.php',
|
||||
'PHPUnit_Framework_Constraint_ExceptionCode' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ExceptionCode.php',
|
||||
'PHPUnit_Framework_Constraint_ExceptionMessage' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessage.php',
|
||||
'PHPUnit_Framework_Constraint_ExceptionMessageRegExp' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessageRegExp.php',
|
||||
'PHPUnit_Framework_Constraint_FileExists' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/FileExists.php',
|
||||
'PHPUnit_Framework_Constraint_GreaterThan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/GreaterThan.php',
|
||||
'PHPUnit_Framework_Constraint_IsAnything' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsAnything.php',
|
||||
'PHPUnit_Framework_Constraint_IsEmpty' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsEmpty.php',
|
||||
'PHPUnit_Framework_Constraint_IsEqual' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsEqual.php',
|
||||
'PHPUnit_Framework_Constraint_IsFalse' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsFalse.php',
|
||||
'PHPUnit_Framework_Constraint_IsFinite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsFinite.php',
|
||||
'PHPUnit_Framework_Constraint_IsIdentical' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php',
|
||||
'PHPUnit_Framework_Constraint_IsInfinite' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsInfinite.php',
|
||||
'PHPUnit_Framework_Constraint_IsInstanceOf' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php',
|
||||
'PHPUnit_Framework_Constraint_IsJson' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsJson.php',
|
||||
'PHPUnit_Framework_Constraint_IsNan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsNan.php',
|
||||
'PHPUnit_Framework_Constraint_IsNull' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsNull.php',
|
||||
'PHPUnit_Framework_Constraint_IsReadable' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsReadable.php',
|
||||
'PHPUnit_Framework_Constraint_IsTrue' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsTrue.php',
|
||||
'PHPUnit_Framework_Constraint_IsType' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsType.php',
|
||||
'PHPUnit_Framework_Constraint_IsWritable' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/IsWritable.php',
|
||||
'PHPUnit_Framework_Constraint_JsonMatches' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php',
|
||||
'PHPUnit_Framework_Constraint_JsonMatches_ErrorMessageProvider' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/JsonMatches/ErrorMessageProvider.php',
|
||||
'PHPUnit_Framework_Constraint_LessThan' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/LessThan.php',
|
||||
'PHPUnit_Framework_Constraint_Not' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Not.php',
|
||||
'PHPUnit_Framework_Constraint_ObjectHasAttribute' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/ObjectHasAttribute.php',
|
||||
'PHPUnit_Framework_Constraint_Or' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Or.php',
|
||||
'PHPUnit_Framework_Constraint_PCREMatch' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/PCREMatch.php',
|
||||
'PHPUnit_Framework_Constraint_SameSize' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/SameSize.php',
|
||||
'PHPUnit_Framework_Constraint_StringContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringContains.php',
|
||||
'PHPUnit_Framework_Constraint_StringEndsWith' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringEndsWith.php',
|
||||
'PHPUnit_Framework_Constraint_StringMatches' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringMatches.php',
|
||||
'PHPUnit_Framework_Constraint_StringStartsWith' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/StringStartsWith.php',
|
||||
'PHPUnit_Framework_Constraint_TraversableContains' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php',
|
||||
'PHPUnit_Framework_Constraint_TraversableContainsOnly' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsOnly.php',
|
||||
'PHPUnit_Framework_Constraint_Xor' => $vendorDir . '/phpunit/phpunit/src/Framework/Constraint/Xor.php',
|
||||
'PHPUnit_Framework_CoveredCodeNotExecutedException' => $vendorDir . '/phpunit/phpunit/src/Framework/CoveredCodeNotExecutedException.php',
|
||||
'PHPUnit_Framework_Error' => $vendorDir . '/phpunit/phpunit/src/Framework/Error.php',
|
||||
'PHPUnit_Framework_Error_Deprecated' => $vendorDir . '/phpunit/phpunit/src/Framework/Error/Deprecated.php',
|
||||
'PHPUnit_Framework_Error_Notice' => $vendorDir . '/phpunit/phpunit/src/Framework/Error/Notice.php',
|
||||
'PHPUnit_Framework_Error_Warning' => $vendorDir . '/phpunit/phpunit/src/Framework/Error/Warning.php',
|
||||
'PHPUnit_Framework_Exception' => $vendorDir . '/phpunit/phpunit/src/Framework/Exception.php',
|
||||
'PHPUnit_Framework_ExceptionWrapper' => $vendorDir . '/phpunit/phpunit/src/Framework/ExceptionWrapper.php',
|
||||
'PHPUnit_Framework_ExpectationFailedException' => $vendorDir . '/phpunit/phpunit/src/Framework/ExpectationFailedException.php',
|
||||
'PHPUnit_Framework_IncompleteTest' => $vendorDir . '/phpunit/phpunit/src/Framework/IncompleteTest.php',
|
||||
'PHPUnit_Framework_IncompleteTestCase' => $vendorDir . '/phpunit/phpunit/src/Framework/IncompleteTestCase.php',
|
||||
'PHPUnit_Framework_IncompleteTestError' => $vendorDir . '/phpunit/phpunit/src/Framework/IncompleteTestError.php',
|
||||
'PHPUnit_Framework_InvalidCoversTargetException' => $vendorDir . '/phpunit/phpunit/src/Framework/InvalidCoversTargetException.php',
|
||||
'PHPUnit_Framework_MissingCoversAnnotationException' => $vendorDir . '/phpunit/phpunit/src/Framework/MissingCoversAnnotationException.php',
|
||||
'PHPUnit_Framework_MockObject_BadMethodCallException' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Exception/BadMethodCallException.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Identity' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Identity.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_InvocationMocker' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/InvocationMocker.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Match' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Match.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_MethodNameMatch' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/MethodNameMatch.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Namespace' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Namespace.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_ParametersMatch' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/ParametersMatch.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Stub' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Stub.php',
|
||||
'PHPUnit_Framework_MockObject_Exception' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Exception/Exception.php',
|
||||
'PHPUnit_Framework_MockObject_Generator' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Generator.php',
|
||||
'PHPUnit_Framework_MockObject_Invocation' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invocation.php',
|
||||
'PHPUnit_Framework_MockObject_InvocationMocker' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/InvocationMocker.php',
|
||||
'PHPUnit_Framework_MockObject_Invocation_Object' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invocation/Object.php',
|
||||
'PHPUnit_Framework_MockObject_Invocation_Static' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invocation/Static.php',
|
||||
'PHPUnit_Framework_MockObject_Invokable' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invokable.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_AnyInvokedCount' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/AnyInvokedCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_AnyParameters' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/AnyParameters.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_ConsecutiveParameters' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/ConsecutiveParameters.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_Invocation' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/Invocation.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtIndex' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtIndex.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtLeastCount' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtLeastCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtLeastOnce' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtLeastOnce.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtMostCount' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtMostCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedCount' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedRecorder' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedRecorder.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_MethodName' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/MethodName.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_Parameters' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/Parameters.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_StatelessInvocation' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/StatelessInvocation.php',
|
||||
'PHPUnit_Framework_MockObject_MockBuilder' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/MockBuilder.php',
|
||||
'PHPUnit_Framework_MockObject_MockObject' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/MockObject.php',
|
||||
'PHPUnit_Framework_MockObject_RuntimeException' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Exception/RuntimeException.php',
|
||||
'PHPUnit_Framework_MockObject_Stub' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ConsecutiveCalls' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ConsecutiveCalls.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_Exception' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/Exception.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_MatcherCollection' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/MatcherCollection.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_Return' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/Return.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnArgument' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnArgument.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnCallback' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnCallback.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnReference' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnReference.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnSelf' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnSelf.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnValueMap' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnValueMap.php',
|
||||
'PHPUnit_Framework_MockObject_Verifiable' => $vendorDir . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Verifiable.php',
|
||||
'PHPUnit_Framework_OutputError' => $vendorDir . '/phpunit/phpunit/src/Framework/OutputError.php',
|
||||
'PHPUnit_Framework_RiskyTest' => $vendorDir . '/phpunit/phpunit/src/Framework/RiskyTest.php',
|
||||
'PHPUnit_Framework_RiskyTestError' => $vendorDir . '/phpunit/phpunit/src/Framework/RiskyTestError.php',
|
||||
'PHPUnit_Framework_SelfDescribing' => $vendorDir . '/phpunit/phpunit/src/Framework/SelfDescribing.php',
|
||||
'PHPUnit_Framework_SkippedTest' => $vendorDir . '/phpunit/phpunit/src/Framework/SkippedTest.php',
|
||||
'PHPUnit_Framework_SkippedTestCase' => $vendorDir . '/phpunit/phpunit/src/Framework/SkippedTestCase.php',
|
||||
'PHPUnit_Framework_SkippedTestError' => $vendorDir . '/phpunit/phpunit/src/Framework/SkippedTestError.php',
|
||||
'PHPUnit_Framework_SkippedTestSuiteError' => $vendorDir . '/phpunit/phpunit/src/Framework/SkippedTestSuiteError.php',
|
||||
'PHPUnit_Framework_SyntheticError' => $vendorDir . '/phpunit/phpunit/src/Framework/SyntheticError.php',
|
||||
'PHPUnit_Framework_Test' => $vendorDir . '/phpunit/phpunit/src/Framework/Test.php',
|
||||
'PHPUnit_Framework_TestCase' => $vendorDir . '/phpunit/phpunit/src/Framework/TestCase.php',
|
||||
'PHPUnit_Framework_TestFailure' => $vendorDir . '/phpunit/phpunit/src/Framework/TestFailure.php',
|
||||
'PHPUnit_Framework_TestListener' => $vendorDir . '/phpunit/phpunit/src/Framework/TestListener.php',
|
||||
'PHPUnit_Framework_TestResult' => $vendorDir . '/phpunit/phpunit/src/Framework/TestResult.php',
|
||||
'PHPUnit_Framework_TestSuite' => $vendorDir . '/phpunit/phpunit/src/Framework/TestSuite.php',
|
||||
'PHPUnit_Framework_TestSuite_DataProvider' => $vendorDir . '/phpunit/phpunit/src/Framework/TestSuite/DataProvider.php',
|
||||
'PHPUnit_Framework_UnintentionallyCoveredCodeError' => $vendorDir . '/phpunit/phpunit/src/Framework/UnintentionallyCoveredCodeError.php',
|
||||
'PHPUnit_Framework_Warning' => $vendorDir . '/phpunit/phpunit/src/Framework/Warning.php',
|
||||
'PHPUnit_Framework_WarningTestCase' => $vendorDir . '/phpunit/phpunit/src/Framework/WarningTestCase.php',
|
||||
'PHPUnit_Runner_BaseTestRunner' => $vendorDir . '/phpunit/phpunit/src/Runner/BaseTestRunner.php',
|
||||
'PHPUnit_Runner_Exception' => $vendorDir . '/phpunit/phpunit/src/Runner/Exception.php',
|
||||
'PHPUnit_Runner_Filter_Factory' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/Factory.php',
|
||||
'PHPUnit_Runner_Filter_GroupFilterIterator' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/Group.php',
|
||||
'PHPUnit_Runner_Filter_Group_Exclude' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/Group/Exclude.php',
|
||||
'PHPUnit_Runner_Filter_Group_Include' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/Group/Include.php',
|
||||
'PHPUnit_Runner_Filter_Test' => $vendorDir . '/phpunit/phpunit/src/Runner/Filter/Test.php',
|
||||
'PHPUnit_Runner_StandardTestSuiteLoader' => $vendorDir . '/phpunit/phpunit/src/Runner/StandardTestSuiteLoader.php',
|
||||
'PHPUnit_Runner_TestSuiteLoader' => $vendorDir . '/phpunit/phpunit/src/Runner/TestSuiteLoader.php',
|
||||
'PHPUnit_Runner_Version' => $vendorDir . '/phpunit/phpunit/src/Runner/Version.php',
|
||||
'PHPUnit_TextUI_Command' => $vendorDir . '/phpunit/phpunit/src/TextUI/Command.php',
|
||||
'PHPUnit_TextUI_ResultPrinter' => $vendorDir . '/phpunit/phpunit/src/TextUI/ResultPrinter.php',
|
||||
'PHPUnit_TextUI_TestRunner' => $vendorDir . '/phpunit/phpunit/src/TextUI/TestRunner.php',
|
||||
'PHPUnit_Util_Blacklist' => $vendorDir . '/phpunit/phpunit/src/Util/Blacklist.php',
|
||||
'PHPUnit_Util_Configuration' => $vendorDir . '/phpunit/phpunit/src/Util/Configuration.php',
|
||||
'PHPUnit_Util_ConfigurationGenerator' => $vendorDir . '/phpunit/phpunit/src/Util/ConfigurationGenerator.php',
|
||||
'PHPUnit_Util_ErrorHandler' => $vendorDir . '/phpunit/phpunit/src/Util/ErrorHandler.php',
|
||||
'PHPUnit_Util_Fileloader' => $vendorDir . '/phpunit/phpunit/src/Util/Fileloader.php',
|
||||
'PHPUnit_Util_Filesystem' => $vendorDir . '/phpunit/phpunit/src/Util/Filesystem.php',
|
||||
'PHPUnit_Util_Filter' => $vendorDir . '/phpunit/phpunit/src/Util/Filter.php',
|
||||
'PHPUnit_Util_Getopt' => $vendorDir . '/phpunit/phpunit/src/Util/Getopt.php',
|
||||
'PHPUnit_Util_GlobalState' => $vendorDir . '/phpunit/phpunit/src/Util/GlobalState.php',
|
||||
'PHPUnit_Util_InvalidArgumentHelper' => $vendorDir . '/phpunit/phpunit/src/Util/InvalidArgumentHelper.php',
|
||||
'PHPUnit_Util_Log_JSON' => $vendorDir . '/phpunit/phpunit/src/Util/Log/JSON.php',
|
||||
'PHPUnit_Util_Log_JUnit' => $vendorDir . '/phpunit/phpunit/src/Util/Log/JUnit.php',
|
||||
'PHPUnit_Util_Log_TAP' => $vendorDir . '/phpunit/phpunit/src/Util/Log/TAP.php',
|
||||
'PHPUnit_Util_Log_TeamCity' => $vendorDir . '/phpunit/phpunit/src/Util/Log/TeamCity.php',
|
||||
'PHPUnit_Util_PHP' => $vendorDir . '/phpunit/phpunit/src/Util/PHP.php',
|
||||
'PHPUnit_Util_PHP_Default' => $vendorDir . '/phpunit/phpunit/src/Util/PHP/Default.php',
|
||||
'PHPUnit_Util_PHP_Windows' => $vendorDir . '/phpunit/phpunit/src/Util/PHP/Windows.php',
|
||||
'PHPUnit_Util_Printer' => $vendorDir . '/phpunit/phpunit/src/Util/Printer.php',
|
||||
'PHPUnit_Util_Regex' => $vendorDir . '/phpunit/phpunit/src/Util/Regex.php',
|
||||
'PHPUnit_Util_String' => $vendorDir . '/phpunit/phpunit/src/Util/String.php',
|
||||
'PHPUnit_Util_Test' => $vendorDir . '/phpunit/phpunit/src/Util/Test.php',
|
||||
'PHPUnit_Util_TestDox_NamePrettifier' => $vendorDir . '/phpunit/phpunit/src/Util/TestDox/NamePrettifier.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter' => $vendorDir . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter_HTML' => $vendorDir . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter/HTML.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter_Text' => $vendorDir . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter/Text.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter_XML' => $vendorDir . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter/XML.php',
|
||||
'PHPUnit_Util_TestSuiteIterator' => $vendorDir . '/phpunit/phpunit/src/Util/TestSuiteIterator.php',
|
||||
'PHPUnit_Util_Type' => $vendorDir . '/phpunit/phpunit/src/Util/Type.php',
|
||||
'PHPUnit_Util_XML' => $vendorDir . '/phpunit/phpunit/src/Util/XML.php',
|
||||
'PHP_Timer' => $vendorDir . '/phpunit/php-timer/src/Timer.php',
|
||||
'PHP_Token' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_TokenWithScope' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_TokenWithScopeAndVisibility' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ABSTRACT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AMPERSAND' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AND_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ARRAY' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ARRAY_CAST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ASYNC' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AWAIT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BACKTICK' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BAD_CHARACTER' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BOOLEAN_AND' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BOOLEAN_OR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BOOL_CAST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BREAK' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CALLABLE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CARET' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CASE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CATCH' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CHARACTER' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLASS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLASS_C' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLASS_NAME_CONSTANT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLONE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_BRACKET' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_CURLY' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_SQUARE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_TAG' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COALESCE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COLON' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COMMA' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COMMENT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COMPILER_HALT_OFFSET' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONCAT_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONSTANT_ENCAPSED_STRING' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONTINUE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CURLY_OPEN' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DEC' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DECLARE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DEFAULT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DIR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DIV' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DIV_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DNUMBER' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DO' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOC_COMMENT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOLLAR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOLLAR_OPEN_CURLY_BRACES' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_ARROW' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_CAST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_COLON' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_QUOTES' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ECHO' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ELLIPSIS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ELSE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ELSEIF' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EMPTY' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENCAPSED_AND_WHITESPACE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDDECLARE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDFOR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDFOREACH' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDIF' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDSWITCH' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDWHILE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_END_HEREDOC' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENUM' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EQUALS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EVAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EXCLAMATION_MARK' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EXIT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EXTENDS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FILE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FINAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FINALLY' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FOR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FOREACH' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FUNCTION' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FUNC_C' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_GLOBAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_GOTO' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_GT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_HALT_COMPILER' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IF' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IMPLEMENTS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IN' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INC' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INCLUDE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INCLUDE_ONCE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INLINE_HTML' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INSTANCEOF' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INSTEADOF' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INTERFACE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INT_CAST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ISSET' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_GREATER_OR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_IDENTICAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_NOT_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_NOT_IDENTICAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_SMALLER_OR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_Includes' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_JOIN' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LAMBDA_ARROW' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LAMBDA_CP' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LAMBDA_OP' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LINE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LIST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LNUMBER' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LOGICAL_AND' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LOGICAL_OR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LOGICAL_XOR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_METHOD_C' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MINUS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MINUS_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MOD_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MULT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MUL_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NAMESPACE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NEW' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NS_C' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NS_SEPARATOR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NULLSAFE_OBJECT_OPERATOR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NUM_STRING' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OBJECT_CAST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OBJECT_OPERATOR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ONUMBER' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_BRACKET' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_CURLY' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_SQUARE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_TAG' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_TAG_WITH_ECHO' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PAAMAYIM_NEKUDOTAYIM' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PERCENT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PIPE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PLUS' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PLUS_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_POW' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_POW_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PRINT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PRIVATE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PROTECTED' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PUBLIC' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_QUESTION_MARK' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_REQUIRE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_REQUIRE_ONCE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_RETURN' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SEMICOLON' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SHAPE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SL_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SPACESHIP' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_START_HEREDOC' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STATIC' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STRING' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STRING_CAST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STRING_VARNAME' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SUPER' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SWITCH' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_Stream' => $vendorDir . '/phpunit/php-token-stream/src/Token/Stream.php',
|
||||
'PHP_Token_Stream_CachingFactory' => $vendorDir . '/phpunit/php-token-stream/src/Token/Stream/CachingFactory.php',
|
||||
'PHP_Token_THROW' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TILDE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TRAIT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TRAIT_C' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TRY' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TYPE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TYPELIST_GT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TYPELIST_LT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_UNSET' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_UNSET_CAST' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_USE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_USE_FUNCTION' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_VAR' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_VARIABLE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_WHERE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_WHILE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_WHITESPACE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_ATTRIBUTE' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_CATEGORY' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_CATEGORY_LABEL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_CHILDREN' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_LABEL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_REQUIRED' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_TAG_GT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_TAG_LT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_TEXT' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XOR_EQUAL' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_YIELD' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_YIELD_FROM' => $vendorDir . '/phpunit/php-token-stream/src/Token.php',
|
||||
'SebastianBergmann\\CodeCoverage\\CodeCoverage' => $vendorDir . '/phpunit/php-code-coverage/src/CodeCoverage.php',
|
||||
'SebastianBergmann\\CodeCoverage\\CoveredCodeNotExecutedException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/CoveredCodeNotExecutedException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\Driver' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/Driver.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\HHVM' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/HHVM.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\PHPDBG' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/PHPDBG.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug' => $vendorDir . '/phpunit/php-code-coverage/src/Driver/Xdebug.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Exception' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/Exception.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Filter' => $vendorDir . '/phpunit/php-code-coverage/src/Filter.php',
|
||||
'SebastianBergmann\\CodeCoverage\\InvalidArgumentException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/InvalidArgumentException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\MissingCoversAnnotationException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/MissingCoversAnnotationException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\AbstractNode' => $vendorDir . '/phpunit/php-code-coverage/src/Node/AbstractNode.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\Builder' => $vendorDir . '/phpunit/php-code-coverage/src/Node/Builder.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\Directory' => $vendorDir . '/phpunit/php-code-coverage/src/Node/Directory.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\File' => $vendorDir . '/phpunit/php-code-coverage/src/Node/File.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\Iterator' => $vendorDir . '/phpunit/php-code-coverage/src/Node/Iterator.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Clover' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Clover.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Crap4j' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Crap4j.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Dashboard' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Dashboard.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Directory' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Directory.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Facade' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Html/Facade.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\File' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Html/Renderer/File.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Renderer' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Html/Renderer.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\PHP' => $vendorDir . '/phpunit/php-code-coverage/src/Report/PHP.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Text' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Text.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Coverage' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Coverage.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Directory' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Directory.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Facade' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Facade.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\File' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/File.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Method' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Method.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Node' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Node.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Project' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Project.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Report' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Report.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Tests' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Tests.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Totals' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Totals.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Unit' => $vendorDir . '/phpunit/php-code-coverage/src/Report/Xml/Unit.php',
|
||||
'SebastianBergmann\\CodeCoverage\\RuntimeException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/RuntimeException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\UnintentionallyCoveredCodeException' => $vendorDir . '/phpunit/php-code-coverage/src/Exception/UnintentionallyCoveredCodeException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Util' => $vendorDir . '/phpunit/php-code-coverage/src/Util.php',
|
||||
'SebastianBergmann\\CodeUnitReverseLookup\\Wizard' => $vendorDir . '/sebastian/code-unit-reverse-lookup/src/Wizard.php',
|
||||
'SebastianBergmann\\Comparator\\ArrayComparator' => $vendorDir . '/sebastian/comparator/src/ArrayComparator.php',
|
||||
'SebastianBergmann\\Comparator\\Comparator' => $vendorDir . '/sebastian/comparator/src/Comparator.php',
|
||||
'SebastianBergmann\\Comparator\\ComparisonFailure' => $vendorDir . '/sebastian/comparator/src/ComparisonFailure.php',
|
||||
'SebastianBergmann\\Comparator\\DOMNodeComparator' => $vendorDir . '/sebastian/comparator/src/DOMNodeComparator.php',
|
||||
'SebastianBergmann\\Comparator\\DateTimeComparator' => $vendorDir . '/sebastian/comparator/src/DateTimeComparator.php',
|
||||
'SebastianBergmann\\Comparator\\DoubleComparator' => $vendorDir . '/sebastian/comparator/src/DoubleComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ExceptionComparator' => $vendorDir . '/sebastian/comparator/src/ExceptionComparator.php',
|
||||
'SebastianBergmann\\Comparator\\Factory' => $vendorDir . '/sebastian/comparator/src/Factory.php',
|
||||
'SebastianBergmann\\Comparator\\MockObjectComparator' => $vendorDir . '/sebastian/comparator/src/MockObjectComparator.php',
|
||||
'SebastianBergmann\\Comparator\\NumericComparator' => $vendorDir . '/sebastian/comparator/src/NumericComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ObjectComparator' => $vendorDir . '/sebastian/comparator/src/ObjectComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ResourceComparator' => $vendorDir . '/sebastian/comparator/src/ResourceComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ScalarComparator' => $vendorDir . '/sebastian/comparator/src/ScalarComparator.php',
|
||||
'SebastianBergmann\\Comparator\\SplObjectStorageComparator' => $vendorDir . '/sebastian/comparator/src/SplObjectStorageComparator.php',
|
||||
'SebastianBergmann\\Comparator\\TypeComparator' => $vendorDir . '/sebastian/comparator/src/TypeComparator.php',
|
||||
'SebastianBergmann\\Diff\\Chunk' => $vendorDir . '/sebastian/diff/src/Chunk.php',
|
||||
'SebastianBergmann\\Diff\\Diff' => $vendorDir . '/sebastian/diff/src/Diff.php',
|
||||
'SebastianBergmann\\Diff\\Differ' => $vendorDir . '/sebastian/diff/src/Differ.php',
|
||||
'SebastianBergmann\\Diff\\LCS\\LongestCommonSubsequence' => $vendorDir . '/sebastian/diff/src/LCS/LongestCommonSubsequence.php',
|
||||
'SebastianBergmann\\Diff\\LCS\\MemoryEfficientImplementation' => $vendorDir . '/sebastian/diff/src/LCS/MemoryEfficientLongestCommonSubsequenceImplementation.php',
|
||||
'SebastianBergmann\\Diff\\LCS\\TimeEfficientImplementation' => $vendorDir . '/sebastian/diff/src/LCS/TimeEfficientLongestCommonSubsequenceImplementation.php',
|
||||
'SebastianBergmann\\Diff\\Line' => $vendorDir . '/sebastian/diff/src/Line.php',
|
||||
'SebastianBergmann\\Diff\\Parser' => $vendorDir . '/sebastian/diff/src/Parser.php',
|
||||
'SebastianBergmann\\Environment\\Console' => $vendorDir . '/sebastian/environment/src/Console.php',
|
||||
'SebastianBergmann\\Environment\\Runtime' => $vendorDir . '/sebastian/environment/src/Runtime.php',
|
||||
'SebastianBergmann\\Exporter\\Exporter' => $vendorDir . '/sebastian/exporter/src/Exporter.php',
|
||||
'SebastianBergmann\\GlobalState\\Blacklist' => $vendorDir . '/sebastian/global-state/src/Blacklist.php',
|
||||
'SebastianBergmann\\GlobalState\\CodeExporter' => $vendorDir . '/sebastian/global-state/src/CodeExporter.php',
|
||||
'SebastianBergmann\\GlobalState\\Exception' => $vendorDir . '/sebastian/global-state/src/Exception.php',
|
||||
'SebastianBergmann\\GlobalState\\Restorer' => $vendorDir . '/sebastian/global-state/src/Restorer.php',
|
||||
'SebastianBergmann\\GlobalState\\RuntimeException' => $vendorDir . '/sebastian/global-state/src/RuntimeException.php',
|
||||
'SebastianBergmann\\GlobalState\\Snapshot' => $vendorDir . '/sebastian/global-state/src/Snapshot.php',
|
||||
'SebastianBergmann\\ObjectEnumerator\\Enumerator' => $vendorDir . '/sebastian/object-enumerator/src/Enumerator.php',
|
||||
'SebastianBergmann\\ObjectEnumerator\\Exception' => $vendorDir . '/sebastian/object-enumerator/src/Exception.php',
|
||||
'SebastianBergmann\\ObjectEnumerator\\InvalidArgumentException' => $vendorDir . '/sebastian/object-enumerator/src/InvalidArgumentException.php',
|
||||
'SebastianBergmann\\RecursionContext\\Context' => $vendorDir . '/sebastian/recursion-context/src/Context.php',
|
||||
'SebastianBergmann\\RecursionContext\\Exception' => $vendorDir . '/sebastian/recursion-context/src/Exception.php',
|
||||
'SebastianBergmann\\RecursionContext\\InvalidArgumentException' => $vendorDir . '/sebastian/recursion-context/src/InvalidArgumentException.php',
|
||||
'SebastianBergmann\\ResourceOperations\\ResourceOperations' => $vendorDir . '/sebastian/resource-operations/src/ResourceOperations.php',
|
||||
'SebastianBergmann\\Version' => $vendorDir . '/sebastian/version/src/Version.php',
|
||||
'Text_Template' => $vendorDir . '/phpunit/php-text-template/src/Template.php',
|
||||
'Attribute' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/Attribute.php',
|
||||
'CURLStringFile' => $vendorDir . '/symfony/polyfill-php81/Resources/stubs/CURLStringFile.php',
|
||||
'Composer\\InstalledVersions' => $vendorDir . '/composer/InstalledVersions.php',
|
||||
'PhpToken' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/PhpToken.php',
|
||||
'ReturnTypeWillChange' => $vendorDir . '/symfony/polyfill-php81/Resources/stubs/ReturnTypeWillChange.php',
|
||||
'Stringable' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/Stringable.php',
|
||||
'UnhandledMatchError' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php',
|
||||
'ValueError' => $vendorDir . '/symfony/polyfill-php80/Resources/stubs/ValueError.php',
|
||||
);
|
||||
|
14
vendor/composer/autoload_files.php
vendored
14
vendor/composer/autoload_files.php
vendored
@ -2,12 +2,20 @@
|
||||
|
||||
// autoload_files.php @generated by Composer
|
||||
|
||||
$vendorDir = dirname(dirname(__FILE__));
|
||||
$vendorDir = dirname(__DIR__);
|
||||
$baseDir = dirname($vendorDir);
|
||||
|
||||
return array(
|
||||
'320cde22f66dd4f5d3fd621d3e88b98f' => $vendorDir . '/symfony/polyfill-ctype/bootstrap.php',
|
||||
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php',
|
||||
'a4a119a56e50fbb293281d9a48007e0e' => $vendorDir . '/symfony/polyfill-php80/bootstrap.php',
|
||||
'253c157292f75eb38082b5acb06f3f01' => $vendorDir . '/nikic/fast-route/src/functions.php',
|
||||
'6124b4c8570aa390c21fafd04a26c69f' => $vendorDir . '/myclabs/deep-copy/src/DeepCopy/deep_copy.php',
|
||||
'6e3fae29631ef280660b3cdad06f25a8' => $vendorDir . '/symfony/deprecation-contracts/function.php',
|
||||
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => $vendorDir . '/symfony/polyfill-mbstring/bootstrap.php',
|
||||
'7b11c4dc42b3b3023073cb14e519683c' => $vendorDir . '/ralouphie/getallheaders/src/getallheaders.php',
|
||||
'23c18046f52bef3eea034657bafda50f' => $vendorDir . '/symfony/polyfill-php81/bootstrap.php',
|
||||
'89efb1254ef2d1c5d80096acd12c4098' => $vendorDir . '/twig/twig/src/Resources/core.php',
|
||||
'ffecb95d45175fd40f75be8a23b34f90' => $vendorDir . '/twig/twig/src/Resources/debug.php',
|
||||
'c7baa00073ee9c61edf148c51917cfb4' => $vendorDir . '/twig/twig/src/Resources/escaper.php',
|
||||
'f844ccf1d25df8663951193c3fc307c8' => $vendorDir . '/twig/twig/src/Resources/string_loader.php',
|
||||
'b33e3d135e5d9e47d845c576147bda89' => $vendorDir . '/php-di/php-di/src/functions.php',
|
||||
);
|
||||
|
4
vendor/composer/autoload_namespaces.php
vendored
4
vendor/composer/autoload_namespaces.php
vendored
@ -2,10 +2,8 @@
|
||||
|
||||
// autoload_namespaces.php @generated by Composer
|
||||
|
||||
$vendorDir = dirname(dirname(__FILE__));
|
||||
$vendorDir = dirname(__DIR__);
|
||||
$baseDir = dirname($vendorDir);
|
||||
|
||||
return array(
|
||||
'Twig_' => array($vendorDir . '/twig/twig/lib'),
|
||||
'Pimple' => array($vendorDir . '/pimple/pimple/src'),
|
||||
);
|
||||
|
20
vendor/composer/autoload_psr4.php
vendored
20
vendor/composer/autoload_psr4.php
vendored
@ -2,20 +2,18 @@
|
||||
|
||||
// autoload_psr4.php @generated by Composer
|
||||
|
||||
$vendorDir = dirname(dirname(__FILE__));
|
||||
$vendorDir = dirname(__DIR__);
|
||||
$baseDir = dirname($vendorDir);
|
||||
|
||||
return array(
|
||||
'phpDocumentor\\Reflection\\' => array($vendorDir . '/phpdocumentor/reflection-common/src', $vendorDir . '/phpdocumentor/reflection-docblock/src', $vendorDir . '/phpdocumentor/type-resolver/src'),
|
||||
'Webmozart\\Assert\\' => array($vendorDir . '/webmozart/assert/src'),
|
||||
'Twig\\' => array($vendorDir . '/twig/twig/src'),
|
||||
'Tuupola\\Middleware\\' => array($vendorDir . '/tuupola/callable-handler/src', $vendorDir . '/tuupola/slim-basic-auth/src'),
|
||||
'Tuupola\\Http\\Factory\\' => array($vendorDir . '/tuupola/http-factory/src'),
|
||||
'Tests\\' => array($baseDir . '/tests'),
|
||||
'Symfony\\Polyfill\\Php81\\' => array($vendorDir . '/symfony/polyfill-php81'),
|
||||
'Symfony\\Polyfill\\Php80\\' => array($vendorDir . '/symfony/polyfill-php80'),
|
||||
'Symfony\\Polyfill\\Mbstring\\' => array($vendorDir . '/symfony/polyfill-mbstring'),
|
||||
'Symfony\\Polyfill\\Ctype\\' => array($vendorDir . '/symfony/polyfill-ctype'),
|
||||
'Symfony\\Component\\Yaml\\' => array($vendorDir . '/symfony/yaml'),
|
||||
'Slim\\Views\\' => array($vendorDir . '/slim/twig-view/src'),
|
||||
'Slim\\Psr7\\' => array($vendorDir . '/slim/psr7/src'),
|
||||
'Slim\\Flash\\' => array($vendorDir . '/slim/flash/src'),
|
||||
'Slim\\' => array($vendorDir . '/slim/slim/Slim'),
|
||||
'ReCaptcha\\' => array($vendorDir . '/google/recaptcha/src/ReCaptcha'),
|
||||
@ -23,12 +21,10 @@ return array(
|
||||
'Psr\\Http\\Server\\' => array($vendorDir . '/psr/http-server-handler/src', $vendorDir . '/psr/http-server-middleware/src'),
|
||||
'Psr\\Http\\Message\\' => array($vendorDir . '/psr/http-factory/src', $vendorDir . '/psr/http-message/src'),
|
||||
'Psr\\Container\\' => array($vendorDir . '/psr/container/src'),
|
||||
'Prophecy\\' => array($vendorDir . '/phpspec/prophecy/src/Prophecy'),
|
||||
'PHPMailer\\PHPMailer\\' => array($vendorDir . '/phpmailer/phpmailer/src'),
|
||||
'Monolog\\' => array($vendorDir . '/monolog/monolog/src/Monolog'),
|
||||
'Knlv\\Slim\\Views\\' => array($vendorDir . '/kanellov/slim-twig-flash/src'),
|
||||
'Interop\\Container\\' => array($vendorDir . '/container-interop/container-interop/src/Interop/Container'),
|
||||
'Laravel\\SerializableClosure\\' => array($vendorDir . '/laravel/serializable-closure/src'),
|
||||
'Invoker\\' => array($vendorDir . '/php-di/invoker/src'),
|
||||
'Fig\\Http\\Message\\' => array($vendorDir . '/fig/http-message-util/src'),
|
||||
'FastRoute\\' => array($vendorDir . '/nikic/fast-route/src'),
|
||||
'Doctrine\\Instantiator\\' => array($vendorDir . '/doctrine/instantiator/src/Doctrine/Instantiator'),
|
||||
'DeepCopy\\' => array($vendorDir . '/myclabs/deep-copy/src/DeepCopy'),
|
||||
'DI\\' => array($vendorDir . '/php-di/php-di/src'),
|
||||
);
|
||||
|
52
vendor/composer/autoload_real.php
vendored
52
vendor/composer/autoload_real.php
vendored
@ -13,58 +13,38 @@ class ComposerAutoloaderInit0dd15d1e9d08041097652a874300c62a
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @return \Composer\Autoload\ClassLoader
|
||||
*/
|
||||
public static function getLoader()
|
||||
{
|
||||
if (null !== self::$loader) {
|
||||
return self::$loader;
|
||||
}
|
||||
|
||||
require __DIR__ . '/platform_check.php';
|
||||
|
||||
spl_autoload_register(array('ComposerAutoloaderInit0dd15d1e9d08041097652a874300c62a', 'loadClassLoader'), true, true);
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader();
|
||||
self::$loader = $loader = new \Composer\Autoload\ClassLoader(\dirname(__DIR__));
|
||||
spl_autoload_unregister(array('ComposerAutoloaderInit0dd15d1e9d08041097652a874300c62a', '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';
|
||||
|
||||
require __DIR__ . '/autoload_static.php';
|
||||
call_user_func(\Composer\Autoload\ComposerStaticInit0dd15d1e9d08041097652a874300c62a::getInitializer($loader));
|
||||
} else {
|
||||
$map = require __DIR__ . '/autoload_namespaces.php';
|
||||
foreach ($map as $namespace => $path) {
|
||||
$loader->set($namespace, $path);
|
||||
}
|
||||
|
||||
$map = require __DIR__ . '/autoload_psr4.php';
|
||||
foreach ($map as $namespace => $path) {
|
||||
$loader->setPsr4($namespace, $path);
|
||||
}
|
||||
|
||||
$classMap = require __DIR__ . '/autoload_classmap.php';
|
||||
if ($classMap) {
|
||||
$loader->addClassMap($classMap);
|
||||
}
|
||||
}
|
||||
|
||||
$loader->register(true);
|
||||
|
||||
if ($useStaticLoader) {
|
||||
$includeFiles = Composer\Autoload\ComposerStaticInit0dd15d1e9d08041097652a874300c62a::$files;
|
||||
} else {
|
||||
$includeFiles = require __DIR__ . '/autoload_files.php';
|
||||
$filesToLoad = \Composer\Autoload\ComposerStaticInit0dd15d1e9d08041097652a874300c62a::$files;
|
||||
$requireFile = \Closure::bind(static function ($fileIdentifier, $file) {
|
||||
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
||||
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
|
||||
|
||||
require $file;
|
||||
}
|
||||
foreach ($includeFiles as $fileIdentifier => $file) {
|
||||
composerRequire0dd15d1e9d08041097652a874300c62a($fileIdentifier, $file);
|
||||
}, null, null);
|
||||
foreach ($filesToLoad as $fileIdentifier => $file) {
|
||||
$requireFile($fileIdentifier, $file);
|
||||
}
|
||||
|
||||
return $loader;
|
||||
}
|
||||
}
|
||||
|
||||
function composerRequire0dd15d1e9d08041097652a874300c62a($fileIdentifier, $file)
|
||||
{
|
||||
if (empty($GLOBALS['__composer_autoload_files'][$fileIdentifier])) {
|
||||
require $file;
|
||||
|
||||
$GLOBALS['__composer_autoload_files'][$fileIdentifier] = true;
|
||||
}
|
||||
}
|
||||
|
584
vendor/composer/autoload_static.php
vendored
584
vendor/composer/autoload_static.php
vendored
@ -8,33 +8,33 @@ class ComposerStaticInit0dd15d1e9d08041097652a874300c62a
|
||||
{
|
||||
public static $files = array (
|
||||
'320cde22f66dd4f5d3fd621d3e88b98f' => __DIR__ . '/..' . '/symfony/polyfill-ctype/bootstrap.php',
|
||||
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
|
||||
'a4a119a56e50fbb293281d9a48007e0e' => __DIR__ . '/..' . '/symfony/polyfill-php80/bootstrap.php',
|
||||
'253c157292f75eb38082b5acb06f3f01' => __DIR__ . '/..' . '/nikic/fast-route/src/functions.php',
|
||||
'6124b4c8570aa390c21fafd04a26c69f' => __DIR__ . '/..' . '/myclabs/deep-copy/src/DeepCopy/deep_copy.php',
|
||||
'6e3fae29631ef280660b3cdad06f25a8' => __DIR__ . '/..' . '/symfony/deprecation-contracts/function.php',
|
||||
'0e6d7bf4a5811bfa5cf40c5ccd6fae6a' => __DIR__ . '/..' . '/symfony/polyfill-mbstring/bootstrap.php',
|
||||
'7b11c4dc42b3b3023073cb14e519683c' => __DIR__ . '/..' . '/ralouphie/getallheaders/src/getallheaders.php',
|
||||
'23c18046f52bef3eea034657bafda50f' => __DIR__ . '/..' . '/symfony/polyfill-php81/bootstrap.php',
|
||||
'89efb1254ef2d1c5d80096acd12c4098' => __DIR__ . '/..' . '/twig/twig/src/Resources/core.php',
|
||||
'ffecb95d45175fd40f75be8a23b34f90' => __DIR__ . '/..' . '/twig/twig/src/Resources/debug.php',
|
||||
'c7baa00073ee9c61edf148c51917cfb4' => __DIR__ . '/..' . '/twig/twig/src/Resources/escaper.php',
|
||||
'f844ccf1d25df8663951193c3fc307c8' => __DIR__ . '/..' . '/twig/twig/src/Resources/string_loader.php',
|
||||
'b33e3d135e5d9e47d845c576147bda89' => __DIR__ . '/..' . '/php-di/php-di/src/functions.php',
|
||||
);
|
||||
|
||||
public static $prefixLengthsPsr4 = array (
|
||||
'p' =>
|
||||
array (
|
||||
'phpDocumentor\\Reflection\\' => 25,
|
||||
),
|
||||
'W' =>
|
||||
array (
|
||||
'Webmozart\\Assert\\' => 17,
|
||||
),
|
||||
'T' =>
|
||||
array (
|
||||
'Twig\\' => 5,
|
||||
'Tuupola\\Middleware\\' => 19,
|
||||
'Tuupola\\Http\\Factory\\' => 21,
|
||||
'Tests\\' => 6,
|
||||
),
|
||||
'S' =>
|
||||
array (
|
||||
'Symfony\\Polyfill\\Php81\\' => 23,
|
||||
'Symfony\\Polyfill\\Php80\\' => 23,
|
||||
'Symfony\\Polyfill\\Mbstring\\' => 26,
|
||||
'Symfony\\Polyfill\\Ctype\\' => 23,
|
||||
'Symfony\\Component\\Yaml\\' => 23,
|
||||
'Slim\\Views\\' => 11,
|
||||
'Slim\\Psr7\\' => 10,
|
||||
'Slim\\Flash\\' => 11,
|
||||
'Slim\\' => 5,
|
||||
),
|
||||
@ -48,59 +48,42 @@ class ComposerStaticInit0dd15d1e9d08041097652a874300c62a
|
||||
'Psr\\Http\\Server\\' => 16,
|
||||
'Psr\\Http\\Message\\' => 17,
|
||||
'Psr\\Container\\' => 14,
|
||||
'Prophecy\\' => 9,
|
||||
'PHPMailer\\PHPMailer\\' => 20,
|
||||
),
|
||||
'M' =>
|
||||
array (
|
||||
'Monolog\\' => 8,
|
||||
),
|
||||
'K' =>
|
||||
'L' =>
|
||||
array (
|
||||
'Knlv\\Slim\\Views\\' => 16,
|
||||
'Laravel\\SerializableClosure\\' => 28,
|
||||
),
|
||||
'I' =>
|
||||
array (
|
||||
'Interop\\Container\\' => 18,
|
||||
'Invoker\\' => 8,
|
||||
),
|
||||
'F' =>
|
||||
array (
|
||||
'Fig\\Http\\Message\\' => 17,
|
||||
'FastRoute\\' => 10,
|
||||
),
|
||||
'D' =>
|
||||
array (
|
||||
'Doctrine\\Instantiator\\' => 22,
|
||||
'DeepCopy\\' => 9,
|
||||
'DI\\' => 3,
|
||||
),
|
||||
);
|
||||
|
||||
public static $prefixDirsPsr4 = array (
|
||||
'phpDocumentor\\Reflection\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/phpdocumentor/reflection-common/src',
|
||||
1 => __DIR__ . '/..' . '/phpdocumentor/reflection-docblock/src',
|
||||
2 => __DIR__ . '/..' . '/phpdocumentor/type-resolver/src',
|
||||
),
|
||||
'Webmozart\\Assert\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/webmozart/assert/src',
|
||||
),
|
||||
'Twig\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/twig/twig/src',
|
||||
),
|
||||
'Tuupola\\Middleware\\' =>
|
||||
'Symfony\\Polyfill\\Php81\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/tuupola/callable-handler/src',
|
||||
1 => __DIR__ . '/..' . '/tuupola/slim-basic-auth/src',
|
||||
0 => __DIR__ . '/..' . '/symfony/polyfill-php81',
|
||||
),
|
||||
'Tuupola\\Http\\Factory\\' =>
|
||||
'Symfony\\Polyfill\\Php80\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/tuupola/http-factory/src',
|
||||
),
|
||||
'Tests\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/../..' . '/tests',
|
||||
0 => __DIR__ . '/..' . '/symfony/polyfill-php80',
|
||||
),
|
||||
'Symfony\\Polyfill\\Mbstring\\' =>
|
||||
array (
|
||||
@ -118,6 +101,10 @@ class ComposerStaticInit0dd15d1e9d08041097652a874300c62a
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/slim/twig-view/src',
|
||||
),
|
||||
'Slim\\Psr7\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/slim/psr7/src',
|
||||
),
|
||||
'Slim\\Flash\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/slim/flash/src',
|
||||
@ -148,523 +135,41 @@ class ComposerStaticInit0dd15d1e9d08041097652a874300c62a
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/psr/container/src',
|
||||
),
|
||||
'Prophecy\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/phpspec/prophecy/src/Prophecy',
|
||||
),
|
||||
'PHPMailer\\PHPMailer\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/phpmailer/phpmailer/src',
|
||||
),
|
||||
'Monolog\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/monolog/monolog/src/Monolog',
|
||||
),
|
||||
'Knlv\\Slim\\Views\\' =>
|
||||
'Laravel\\SerializableClosure\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/kanellov/slim-twig-flash/src',
|
||||
0 => __DIR__ . '/..' . '/laravel/serializable-closure/src',
|
||||
),
|
||||
'Interop\\Container\\' =>
|
||||
'Invoker\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/container-interop/container-interop/src/Interop/Container',
|
||||
0 => __DIR__ . '/..' . '/php-di/invoker/src',
|
||||
),
|
||||
'Fig\\Http\\Message\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/fig/http-message-util/src',
|
||||
),
|
||||
'FastRoute\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/nikic/fast-route/src',
|
||||
),
|
||||
'Doctrine\\Instantiator\\' =>
|
||||
'DI\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/doctrine/instantiator/src/Doctrine/Instantiator',
|
||||
),
|
||||
'DeepCopy\\' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/myclabs/deep-copy/src/DeepCopy',
|
||||
),
|
||||
);
|
||||
|
||||
public static $prefixesPsr0 = array (
|
||||
'T' =>
|
||||
array (
|
||||
'Twig_' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/twig/twig/lib',
|
||||
),
|
||||
),
|
||||
'P' =>
|
||||
array (
|
||||
'Pimple' =>
|
||||
array (
|
||||
0 => __DIR__ . '/..' . '/pimple/pimple/src',
|
||||
),
|
||||
0 => __DIR__ . '/..' . '/php-di/php-di/src',
|
||||
),
|
||||
);
|
||||
|
||||
public static $classMap = array (
|
||||
'File_Iterator' => __DIR__ . '/..' . '/phpunit/php-file-iterator/src/Iterator.php',
|
||||
'File_Iterator_Facade' => __DIR__ . '/..' . '/phpunit/php-file-iterator/src/Facade.php',
|
||||
'File_Iterator_Factory' => __DIR__ . '/..' . '/phpunit/php-file-iterator/src/Factory.php',
|
||||
'PHPUnit\\Framework\\Assert' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/Assert.php',
|
||||
'PHPUnit\\Framework\\AssertionFailedError' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/AssertionFailedError.php',
|
||||
'PHPUnit\\Framework\\BaseTestListener' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/BaseTestListener.php',
|
||||
'PHPUnit\\Framework\\Test' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/Test.php',
|
||||
'PHPUnit\\Framework\\TestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/TestCase.php',
|
||||
'PHPUnit\\Framework\\TestListener' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/TestListener.php',
|
||||
'PHPUnit\\Framework\\TestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/ForwardCompatibility/TestSuite.php',
|
||||
'PHPUnit_Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Exception.php',
|
||||
'PHPUnit_Extensions_GroupTestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Extensions/GroupTestSuite.php',
|
||||
'PHPUnit_Extensions_PhptTestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Extensions/PhptTestCase.php',
|
||||
'PHPUnit_Extensions_PhptTestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Extensions/PhptTestSuite.php',
|
||||
'PHPUnit_Extensions_RepeatedTest' => __DIR__ . '/..' . '/phpunit/phpunit/src/Extensions/RepeatedTest.php',
|
||||
'PHPUnit_Extensions_TestDecorator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Extensions/TestDecorator.php',
|
||||
'PHPUnit_Extensions_TicketListener' => __DIR__ . '/..' . '/phpunit/phpunit/src/Extensions/TicketListener.php',
|
||||
'PHPUnit_Framework_Assert' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Assert.php',
|
||||
'PHPUnit_Framework_AssertionFailedError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/AssertionFailedError.php',
|
||||
'PHPUnit_Framework_BaseTestListener' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/BaseTestListener.php',
|
||||
'PHPUnit_Framework_CodeCoverageException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/CodeCoverageException.php',
|
||||
'PHPUnit_Framework_Constraint' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint.php',
|
||||
'PHPUnit_Framework_Constraint_And' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/And.php',
|
||||
'PHPUnit_Framework_Constraint_ArrayHasKey' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ArrayHasKey.php',
|
||||
'PHPUnit_Framework_Constraint_ArraySubset' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ArraySubset.php',
|
||||
'PHPUnit_Framework_Constraint_Attribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Attribute.php',
|
||||
'PHPUnit_Framework_Constraint_Callback' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Callback.php',
|
||||
'PHPUnit_Framework_Constraint_ClassHasAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ClassHasAttribute.php',
|
||||
'PHPUnit_Framework_Constraint_ClassHasStaticAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ClassHasStaticAttribute.php',
|
||||
'PHPUnit_Framework_Constraint_Composite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Composite.php',
|
||||
'PHPUnit_Framework_Constraint_Count' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Count.php',
|
||||
'PHPUnit_Framework_Constraint_DirectoryExists' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/DirectoryExists.php',
|
||||
'PHPUnit_Framework_Constraint_Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Exception.php',
|
||||
'PHPUnit_Framework_Constraint_ExceptionCode' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ExceptionCode.php',
|
||||
'PHPUnit_Framework_Constraint_ExceptionMessage' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessage.php',
|
||||
'PHPUnit_Framework_Constraint_ExceptionMessageRegExp' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ExceptionMessageRegExp.php',
|
||||
'PHPUnit_Framework_Constraint_FileExists' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/FileExists.php',
|
||||
'PHPUnit_Framework_Constraint_GreaterThan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/GreaterThan.php',
|
||||
'PHPUnit_Framework_Constraint_IsAnything' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsAnything.php',
|
||||
'PHPUnit_Framework_Constraint_IsEmpty' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsEmpty.php',
|
||||
'PHPUnit_Framework_Constraint_IsEqual' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsEqual.php',
|
||||
'PHPUnit_Framework_Constraint_IsFalse' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsFalse.php',
|
||||
'PHPUnit_Framework_Constraint_IsFinite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsFinite.php',
|
||||
'PHPUnit_Framework_Constraint_IsIdentical' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsIdentical.php',
|
||||
'PHPUnit_Framework_Constraint_IsInfinite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsInfinite.php',
|
||||
'PHPUnit_Framework_Constraint_IsInstanceOf' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsInstanceOf.php',
|
||||
'PHPUnit_Framework_Constraint_IsJson' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsJson.php',
|
||||
'PHPUnit_Framework_Constraint_IsNan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsNan.php',
|
||||
'PHPUnit_Framework_Constraint_IsNull' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsNull.php',
|
||||
'PHPUnit_Framework_Constraint_IsReadable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsReadable.php',
|
||||
'PHPUnit_Framework_Constraint_IsTrue' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsTrue.php',
|
||||
'PHPUnit_Framework_Constraint_IsType' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsType.php',
|
||||
'PHPUnit_Framework_Constraint_IsWritable' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/IsWritable.php',
|
||||
'PHPUnit_Framework_Constraint_JsonMatches' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/JsonMatches.php',
|
||||
'PHPUnit_Framework_Constraint_JsonMatches_ErrorMessageProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/JsonMatches/ErrorMessageProvider.php',
|
||||
'PHPUnit_Framework_Constraint_LessThan' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/LessThan.php',
|
||||
'PHPUnit_Framework_Constraint_Not' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Not.php',
|
||||
'PHPUnit_Framework_Constraint_ObjectHasAttribute' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/ObjectHasAttribute.php',
|
||||
'PHPUnit_Framework_Constraint_Or' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Or.php',
|
||||
'PHPUnit_Framework_Constraint_PCREMatch' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/PCREMatch.php',
|
||||
'PHPUnit_Framework_Constraint_SameSize' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/SameSize.php',
|
||||
'PHPUnit_Framework_Constraint_StringContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringContains.php',
|
||||
'PHPUnit_Framework_Constraint_StringEndsWith' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringEndsWith.php',
|
||||
'PHPUnit_Framework_Constraint_StringMatches' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringMatches.php',
|
||||
'PHPUnit_Framework_Constraint_StringStartsWith' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/StringStartsWith.php',
|
||||
'PHPUnit_Framework_Constraint_TraversableContains' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/TraversableContains.php',
|
||||
'PHPUnit_Framework_Constraint_TraversableContainsOnly' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/TraversableContainsOnly.php',
|
||||
'PHPUnit_Framework_Constraint_Xor' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Constraint/Xor.php',
|
||||
'PHPUnit_Framework_CoveredCodeNotExecutedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/CoveredCodeNotExecutedException.php',
|
||||
'PHPUnit_Framework_Error' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error.php',
|
||||
'PHPUnit_Framework_Error_Deprecated' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error/Deprecated.php',
|
||||
'PHPUnit_Framework_Error_Notice' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error/Notice.php',
|
||||
'PHPUnit_Framework_Error_Warning' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Error/Warning.php',
|
||||
'PHPUnit_Framework_Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Exception.php',
|
||||
'PHPUnit_Framework_ExceptionWrapper' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/ExceptionWrapper.php',
|
||||
'PHPUnit_Framework_ExpectationFailedException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/ExpectationFailedException.php',
|
||||
'PHPUnit_Framework_IncompleteTest' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/IncompleteTest.php',
|
||||
'PHPUnit_Framework_IncompleteTestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/IncompleteTestCase.php',
|
||||
'PHPUnit_Framework_IncompleteTestError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/IncompleteTestError.php',
|
||||
'PHPUnit_Framework_InvalidCoversTargetException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/InvalidCoversTargetException.php',
|
||||
'PHPUnit_Framework_MissingCoversAnnotationException' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/MissingCoversAnnotationException.php',
|
||||
'PHPUnit_Framework_MockObject_BadMethodCallException' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Exception/BadMethodCallException.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Identity' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Identity.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_InvocationMocker' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/InvocationMocker.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Match' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Match.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_MethodNameMatch' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/MethodNameMatch.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Namespace' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Namespace.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_ParametersMatch' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/ParametersMatch.php',
|
||||
'PHPUnit_Framework_MockObject_Builder_Stub' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Builder/Stub.php',
|
||||
'PHPUnit_Framework_MockObject_Exception' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Exception/Exception.php',
|
||||
'PHPUnit_Framework_MockObject_Generator' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Generator.php',
|
||||
'PHPUnit_Framework_MockObject_Invocation' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invocation.php',
|
||||
'PHPUnit_Framework_MockObject_InvocationMocker' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/InvocationMocker.php',
|
||||
'PHPUnit_Framework_MockObject_Invocation_Object' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invocation/Object.php',
|
||||
'PHPUnit_Framework_MockObject_Invocation_Static' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invocation/Static.php',
|
||||
'PHPUnit_Framework_MockObject_Invokable' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Invokable.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_AnyInvokedCount' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/AnyInvokedCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_AnyParameters' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/AnyParameters.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_ConsecutiveParameters' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/ConsecutiveParameters.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_Invocation' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/Invocation.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtIndex' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtIndex.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtLeastCount' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtLeastCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtLeastOnce' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtLeastOnce.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedAtMostCount' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedAtMostCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedCount' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedCount.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_InvokedRecorder' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/InvokedRecorder.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_MethodName' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/MethodName.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_Parameters' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/Parameters.php',
|
||||
'PHPUnit_Framework_MockObject_Matcher_StatelessInvocation' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Matcher/StatelessInvocation.php',
|
||||
'PHPUnit_Framework_MockObject_MockBuilder' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/MockBuilder.php',
|
||||
'PHPUnit_Framework_MockObject_MockObject' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/MockObject.php',
|
||||
'PHPUnit_Framework_MockObject_RuntimeException' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Exception/RuntimeException.php',
|
||||
'PHPUnit_Framework_MockObject_Stub' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ConsecutiveCalls' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ConsecutiveCalls.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_Exception' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/Exception.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_MatcherCollection' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/MatcherCollection.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_Return' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/Return.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnArgument' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnArgument.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnCallback' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnCallback.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnReference' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnReference.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnSelf' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnSelf.php',
|
||||
'PHPUnit_Framework_MockObject_Stub_ReturnValueMap' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Stub/ReturnValueMap.php',
|
||||
'PHPUnit_Framework_MockObject_Verifiable' => __DIR__ . '/..' . '/phpunit/phpunit-mock-objects/src/Framework/MockObject/Verifiable.php',
|
||||
'PHPUnit_Framework_OutputError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/OutputError.php',
|
||||
'PHPUnit_Framework_RiskyTest' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/RiskyTest.php',
|
||||
'PHPUnit_Framework_RiskyTestError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/RiskyTestError.php',
|
||||
'PHPUnit_Framework_SelfDescribing' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SelfDescribing.php',
|
||||
'PHPUnit_Framework_SkippedTest' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SkippedTest.php',
|
||||
'PHPUnit_Framework_SkippedTestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SkippedTestCase.php',
|
||||
'PHPUnit_Framework_SkippedTestError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SkippedTestError.php',
|
||||
'PHPUnit_Framework_SkippedTestSuiteError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SkippedTestSuiteError.php',
|
||||
'PHPUnit_Framework_SyntheticError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/SyntheticError.php',
|
||||
'PHPUnit_Framework_Test' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Test.php',
|
||||
'PHPUnit_Framework_TestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestCase.php',
|
||||
'PHPUnit_Framework_TestFailure' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestFailure.php',
|
||||
'PHPUnit_Framework_TestListener' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestListener.php',
|
||||
'PHPUnit_Framework_TestResult' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestResult.php',
|
||||
'PHPUnit_Framework_TestSuite' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestSuite.php',
|
||||
'PHPUnit_Framework_TestSuite_DataProvider' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/TestSuite/DataProvider.php',
|
||||
'PHPUnit_Framework_UnintentionallyCoveredCodeError' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/UnintentionallyCoveredCodeError.php',
|
||||
'PHPUnit_Framework_Warning' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/Warning.php',
|
||||
'PHPUnit_Framework_WarningTestCase' => __DIR__ . '/..' . '/phpunit/phpunit/src/Framework/WarningTestCase.php',
|
||||
'PHPUnit_Runner_BaseTestRunner' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/BaseTestRunner.php',
|
||||
'PHPUnit_Runner_Exception' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Exception.php',
|
||||
'PHPUnit_Runner_Filter_Factory' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/Factory.php',
|
||||
'PHPUnit_Runner_Filter_GroupFilterIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/Group.php',
|
||||
'PHPUnit_Runner_Filter_Group_Exclude' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/Group/Exclude.php',
|
||||
'PHPUnit_Runner_Filter_Group_Include' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/Group/Include.php',
|
||||
'PHPUnit_Runner_Filter_Test' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Filter/Test.php',
|
||||
'PHPUnit_Runner_StandardTestSuiteLoader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/StandardTestSuiteLoader.php',
|
||||
'PHPUnit_Runner_TestSuiteLoader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/TestSuiteLoader.php',
|
||||
'PHPUnit_Runner_Version' => __DIR__ . '/..' . '/phpunit/phpunit/src/Runner/Version.php',
|
||||
'PHPUnit_TextUI_Command' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/Command.php',
|
||||
'PHPUnit_TextUI_ResultPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/ResultPrinter.php',
|
||||
'PHPUnit_TextUI_TestRunner' => __DIR__ . '/..' . '/phpunit/phpunit/src/TextUI/TestRunner.php',
|
||||
'PHPUnit_Util_Blacklist' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Blacklist.php',
|
||||
'PHPUnit_Util_Configuration' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Configuration.php',
|
||||
'PHPUnit_Util_ConfigurationGenerator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ConfigurationGenerator.php',
|
||||
'PHPUnit_Util_ErrorHandler' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/ErrorHandler.php',
|
||||
'PHPUnit_Util_Fileloader' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Fileloader.php',
|
||||
'PHPUnit_Util_Filesystem' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Filesystem.php',
|
||||
'PHPUnit_Util_Filter' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Filter.php',
|
||||
'PHPUnit_Util_Getopt' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Getopt.php',
|
||||
'PHPUnit_Util_GlobalState' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/GlobalState.php',
|
||||
'PHPUnit_Util_InvalidArgumentHelper' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/InvalidArgumentHelper.php',
|
||||
'PHPUnit_Util_Log_JSON' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Log/JSON.php',
|
||||
'PHPUnit_Util_Log_JUnit' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Log/JUnit.php',
|
||||
'PHPUnit_Util_Log_TAP' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Log/TAP.php',
|
||||
'PHPUnit_Util_Log_TeamCity' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Log/TeamCity.php',
|
||||
'PHPUnit_Util_PHP' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/PHP.php',
|
||||
'PHPUnit_Util_PHP_Default' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/PHP/Default.php',
|
||||
'PHPUnit_Util_PHP_Windows' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/PHP/Windows.php',
|
||||
'PHPUnit_Util_Printer' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Printer.php',
|
||||
'PHPUnit_Util_Regex' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Regex.php',
|
||||
'PHPUnit_Util_String' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/String.php',
|
||||
'PHPUnit_Util_Test' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Test.php',
|
||||
'PHPUnit_Util_TestDox_NamePrettifier' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/TestDox/NamePrettifier.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter_HTML' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter/HTML.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter_Text' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter/Text.php',
|
||||
'PHPUnit_Util_TestDox_ResultPrinter_XML' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/TestDox/ResultPrinter/XML.php',
|
||||
'PHPUnit_Util_TestSuiteIterator' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/TestSuiteIterator.php',
|
||||
'PHPUnit_Util_Type' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/Type.php',
|
||||
'PHPUnit_Util_XML' => __DIR__ . '/..' . '/phpunit/phpunit/src/Util/XML.php',
|
||||
'PHP_Timer' => __DIR__ . '/..' . '/phpunit/php-timer/src/Timer.php',
|
||||
'PHP_Token' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_TokenWithScope' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_TokenWithScopeAndVisibility' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ABSTRACT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AMPERSAND' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AND_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ARRAY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ARRAY_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ASYNC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_AWAIT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BACKTICK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BAD_CHARACTER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BOOLEAN_AND' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BOOLEAN_OR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BOOL_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_BREAK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CALLABLE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CARET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CASE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CATCH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CHARACTER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLASS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLASS_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLASS_NAME_CONSTANT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLONE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_BRACKET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_CURLY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_SQUARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CLOSE_TAG' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COALESCE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COLON' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COMMA' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COMMENT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_COMPILER_HALT_OFFSET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONCAT_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONSTANT_ENCAPSED_STRING' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CONTINUE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_CURLY_OPEN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DEC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DECLARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DEFAULT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DIR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DIV' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DIV_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DNUMBER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOC_COMMENT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOLLAR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOLLAR_OPEN_CURLY_BRACES' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_ARROW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_COLON' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_DOUBLE_QUOTES' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ECHO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ELLIPSIS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ELSE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ELSEIF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EMPTY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENCAPSED_AND_WHITESPACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDDECLARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDFOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDFOREACH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDIF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDSWITCH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENDWHILE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_END_HEREDOC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ENUM' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EQUALS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EVAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EXCLAMATION_MARK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EXIT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_EXTENDS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FILE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FINAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FINALLY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FOREACH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FUNCTION' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_FUNC_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_GLOBAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_GOTO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_GT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_HALT_COMPILER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IMPLEMENTS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INCLUDE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INCLUDE_ONCE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INLINE_HTML' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INSTANCEOF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INSTEADOF' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INTERFACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_INT_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ISSET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_GREATER_OR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_IDENTICAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_NOT_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_NOT_IDENTICAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_IS_SMALLER_OR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_Includes' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_JOIN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LAMBDA_ARROW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LAMBDA_CP' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LAMBDA_OP' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LINE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LIST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LNUMBER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LOGICAL_AND' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LOGICAL_OR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LOGICAL_XOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_LT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_METHOD_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MINUS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MINUS_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MOD_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MULT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_MUL_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NAMESPACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NEW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NS_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NS_SEPARATOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NULLSAFE_OBJECT_OPERATOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_NUM_STRING' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OBJECT_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OBJECT_OPERATOR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_ONUMBER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_BRACKET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_CURLY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_SQUARE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_TAG' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OPEN_TAG_WITH_ECHO' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_OR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PAAMAYIM_NEKUDOTAYIM' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PERCENT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PIPE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PLUS' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PLUS_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_POW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_POW_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PRINT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PRIVATE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PROTECTED' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_PUBLIC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_QUESTION_MARK' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_REQUIRE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_REQUIRE_ONCE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_RETURN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SEMICOLON' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SHAPE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SL_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SPACESHIP' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_START_HEREDOC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STATIC' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STRING' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STRING_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_STRING_VARNAME' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SUPER' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_SWITCH' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_Stream' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token/Stream.php',
|
||||
'PHP_Token_Stream_CachingFactory' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token/Stream/CachingFactory.php',
|
||||
'PHP_Token_THROW' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TILDE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TRAIT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TRAIT_C' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TRY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TYPE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TYPELIST_GT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_TYPELIST_LT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_UNSET' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_UNSET_CAST' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_USE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_USE_FUNCTION' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_VAR' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_VARIABLE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_WHERE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_WHILE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_WHITESPACE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_ATTRIBUTE' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_CATEGORY' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_CATEGORY_LABEL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_CHILDREN' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_LABEL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_REQUIRED' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_TAG_GT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_TAG_LT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XHP_TEXT' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_XOR_EQUAL' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_YIELD' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'PHP_Token_YIELD_FROM' => __DIR__ . '/..' . '/phpunit/php-token-stream/src/Token.php',
|
||||
'SebastianBergmann\\CodeCoverage\\CodeCoverage' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/CodeCoverage.php',
|
||||
'SebastianBergmann\\CodeCoverage\\CoveredCodeNotExecutedException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/CoveredCodeNotExecutedException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\Driver' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/Driver.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\HHVM' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/HHVM.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\PHPDBG' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/PHPDBG.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Driver\\Xdebug' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Driver/Xdebug.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Exception' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/Exception.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Filter' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Filter.php',
|
||||
'SebastianBergmann\\CodeCoverage\\InvalidArgumentException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/InvalidArgumentException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\MissingCoversAnnotationException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/MissingCoversAnnotationException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\AbstractNode' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/AbstractNode.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\Builder' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/Builder.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\Directory' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/Directory.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\File' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/File.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Node\\Iterator' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Node/Iterator.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Clover' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Clover.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Crap4j' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Crap4j.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Dashboard' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Dashboard.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Directory' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Html/Renderer/Directory.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Facade' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Html/Facade.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\File' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Html/Renderer/File.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Html\\Renderer' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Html/Renderer.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\PHP' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/PHP.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Text' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Text.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Coverage' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Coverage.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Directory' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Directory.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Facade' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Facade.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\File' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/File.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Method' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Method.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Node' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Node.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Project' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Project.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Report' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Report.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Tests' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Tests.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Totals' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Totals.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Report\\Xml\\Unit' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Report/Xml/Unit.php',
|
||||
'SebastianBergmann\\CodeCoverage\\RuntimeException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/RuntimeException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\UnintentionallyCoveredCodeException' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Exception/UnintentionallyCoveredCodeException.php',
|
||||
'SebastianBergmann\\CodeCoverage\\Util' => __DIR__ . '/..' . '/phpunit/php-code-coverage/src/Util.php',
|
||||
'SebastianBergmann\\CodeUnitReverseLookup\\Wizard' => __DIR__ . '/..' . '/sebastian/code-unit-reverse-lookup/src/Wizard.php',
|
||||
'SebastianBergmann\\Comparator\\ArrayComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ArrayComparator.php',
|
||||
'SebastianBergmann\\Comparator\\Comparator' => __DIR__ . '/..' . '/sebastian/comparator/src/Comparator.php',
|
||||
'SebastianBergmann\\Comparator\\ComparisonFailure' => __DIR__ . '/..' . '/sebastian/comparator/src/ComparisonFailure.php',
|
||||
'SebastianBergmann\\Comparator\\DOMNodeComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/DOMNodeComparator.php',
|
||||
'SebastianBergmann\\Comparator\\DateTimeComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/DateTimeComparator.php',
|
||||
'SebastianBergmann\\Comparator\\DoubleComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/DoubleComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ExceptionComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ExceptionComparator.php',
|
||||
'SebastianBergmann\\Comparator\\Factory' => __DIR__ . '/..' . '/sebastian/comparator/src/Factory.php',
|
||||
'SebastianBergmann\\Comparator\\MockObjectComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/MockObjectComparator.php',
|
||||
'SebastianBergmann\\Comparator\\NumericComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/NumericComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ObjectComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ObjectComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ResourceComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ResourceComparator.php',
|
||||
'SebastianBergmann\\Comparator\\ScalarComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/ScalarComparator.php',
|
||||
'SebastianBergmann\\Comparator\\SplObjectStorageComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/SplObjectStorageComparator.php',
|
||||
'SebastianBergmann\\Comparator\\TypeComparator' => __DIR__ . '/..' . '/sebastian/comparator/src/TypeComparator.php',
|
||||
'SebastianBergmann\\Diff\\Chunk' => __DIR__ . '/..' . '/sebastian/diff/src/Chunk.php',
|
||||
'SebastianBergmann\\Diff\\Diff' => __DIR__ . '/..' . '/sebastian/diff/src/Diff.php',
|
||||
'SebastianBergmann\\Diff\\Differ' => __DIR__ . '/..' . '/sebastian/diff/src/Differ.php',
|
||||
'SebastianBergmann\\Diff\\LCS\\LongestCommonSubsequence' => __DIR__ . '/..' . '/sebastian/diff/src/LCS/LongestCommonSubsequence.php',
|
||||
'SebastianBergmann\\Diff\\LCS\\MemoryEfficientImplementation' => __DIR__ . '/..' . '/sebastian/diff/src/LCS/MemoryEfficientLongestCommonSubsequenceImplementation.php',
|
||||
'SebastianBergmann\\Diff\\LCS\\TimeEfficientImplementation' => __DIR__ . '/..' . '/sebastian/diff/src/LCS/TimeEfficientLongestCommonSubsequenceImplementation.php',
|
||||
'SebastianBergmann\\Diff\\Line' => __DIR__ . '/..' . '/sebastian/diff/src/Line.php',
|
||||
'SebastianBergmann\\Diff\\Parser' => __DIR__ . '/..' . '/sebastian/diff/src/Parser.php',
|
||||
'SebastianBergmann\\Environment\\Console' => __DIR__ . '/..' . '/sebastian/environment/src/Console.php',
|
||||
'SebastianBergmann\\Environment\\Runtime' => __DIR__ . '/..' . '/sebastian/environment/src/Runtime.php',
|
||||
'SebastianBergmann\\Exporter\\Exporter' => __DIR__ . '/..' . '/sebastian/exporter/src/Exporter.php',
|
||||
'SebastianBergmann\\GlobalState\\Blacklist' => __DIR__ . '/..' . '/sebastian/global-state/src/Blacklist.php',
|
||||
'SebastianBergmann\\GlobalState\\CodeExporter' => __DIR__ . '/..' . '/sebastian/global-state/src/CodeExporter.php',
|
||||
'SebastianBergmann\\GlobalState\\Exception' => __DIR__ . '/..' . '/sebastian/global-state/src/Exception.php',
|
||||
'SebastianBergmann\\GlobalState\\Restorer' => __DIR__ . '/..' . '/sebastian/global-state/src/Restorer.php',
|
||||
'SebastianBergmann\\GlobalState\\RuntimeException' => __DIR__ . '/..' . '/sebastian/global-state/src/RuntimeException.php',
|
||||
'SebastianBergmann\\GlobalState\\Snapshot' => __DIR__ . '/..' . '/sebastian/global-state/src/Snapshot.php',
|
||||
'SebastianBergmann\\ObjectEnumerator\\Enumerator' => __DIR__ . '/..' . '/sebastian/object-enumerator/src/Enumerator.php',
|
||||
'SebastianBergmann\\ObjectEnumerator\\Exception' => __DIR__ . '/..' . '/sebastian/object-enumerator/src/Exception.php',
|
||||
'SebastianBergmann\\ObjectEnumerator\\InvalidArgumentException' => __DIR__ . '/..' . '/sebastian/object-enumerator/src/InvalidArgumentException.php',
|
||||
'SebastianBergmann\\RecursionContext\\Context' => __DIR__ . '/..' . '/sebastian/recursion-context/src/Context.php',
|
||||
'SebastianBergmann\\RecursionContext\\Exception' => __DIR__ . '/..' . '/sebastian/recursion-context/src/Exception.php',
|
||||
'SebastianBergmann\\RecursionContext\\InvalidArgumentException' => __DIR__ . '/..' . '/sebastian/recursion-context/src/InvalidArgumentException.php',
|
||||
'SebastianBergmann\\ResourceOperations\\ResourceOperations' => __DIR__ . '/..' . '/sebastian/resource-operations/src/ResourceOperations.php',
|
||||
'SebastianBergmann\\Version' => __DIR__ . '/..' . '/sebastian/version/src/Version.php',
|
||||
'Text_Template' => __DIR__ . '/..' . '/phpunit/php-text-template/src/Template.php',
|
||||
'Attribute' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/Attribute.php',
|
||||
'CURLStringFile' => __DIR__ . '/..' . '/symfony/polyfill-php81/Resources/stubs/CURLStringFile.php',
|
||||
'Composer\\InstalledVersions' => __DIR__ . '/..' . '/composer/InstalledVersions.php',
|
||||
'PhpToken' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/PhpToken.php',
|
||||
'ReturnTypeWillChange' => __DIR__ . '/..' . '/symfony/polyfill-php81/Resources/stubs/ReturnTypeWillChange.php',
|
||||
'Stringable' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/Stringable.php',
|
||||
'UnhandledMatchError' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/UnhandledMatchError.php',
|
||||
'ValueError' => __DIR__ . '/..' . '/symfony/polyfill-php80/Resources/stubs/ValueError.php',
|
||||
);
|
||||
|
||||
public static function getInitializer(ClassLoader $loader)
|
||||
@ -672,7 +177,6 @@ class ComposerStaticInit0dd15d1e9d08041097652a874300c62a
|
||||
return \Closure::bind(function () use ($loader) {
|
||||
$loader->prefixLengthsPsr4 = ComposerStaticInit0dd15d1e9d08041097652a874300c62a::$prefixLengthsPsr4;
|
||||
$loader->prefixDirsPsr4 = ComposerStaticInit0dd15d1e9d08041097652a874300c62a::$prefixDirsPsr4;
|
||||
$loader->prefixesPsr0 = ComposerStaticInit0dd15d1e9d08041097652a874300c62a::$prefixesPsr0;
|
||||
$loader->classMap = ComposerStaticInit0dd15d1e9d08041097652a874300c62a::$classMap;
|
||||
|
||||
}, null, ClassLoader::class);
|
||||
|
2586
vendor/composer/installed.json
vendored
2586
vendor/composer/installed.json
vendored
File diff suppressed because it is too large
Load Diff
@ -1,3 +0,0 @@
|
||||
composer.lock
|
||||
composer.phar
|
||||
/vendor/
|
@ -1,20 +0,0 @@
|
||||
The MIT License (MIT)
|
||||
|
||||
Copyright (c) 2013 container-interop
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of
|
||||
the Software, and to permit persons to whom the Software is furnished to do so,
|
||||
subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS
|
||||
FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR
|
||||
COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER
|
||||
IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN
|
||||
CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
|
148
vendor/container-interop/container-interop/README.md
vendored
148
vendor/container-interop/container-interop/README.md
vendored
@ -1,148 +0,0 @@
|
||||
# Container Interoperability
|
||||
|
||||
[](https://packagist.org/packages/container-interop/container-interop)
|
||||
[](https://packagist.org/packages/container-interop/container-interop)
|
||||
|
||||
## Deprecation warning!
|
||||
|
||||
Starting Feb. 13th 2017, container-interop is officially deprecated in favor of [PSR-11](https://github.com/php-fig/fig-standards/blob/master/accepted/PSR-11-container.md).
|
||||
Container-interop has been the test-bed of PSR-11. From v1.2, container-interop directly extends PSR-11 interfaces.
|
||||
Therefore, all containers implementing container-interop are now *de-facto* compatible with PSR-11.
|
||||
|
||||
- Projects implementing container-interop interfaces are encouraged to directly implement PSR-11 interfaces instead.
|
||||
- Projects consuming container-interop interfaces are very strongly encouraged to directly type-hint on PSR-11 interfaces, in order to be compatible with PSR-11 containers that are not compatible with container-interop.
|
||||
|
||||
Regarding the delegate lookup feature, that is present in container-interop and not in PSR-11, the feature is actually a design pattern. It is therefore not deprecated. Documentation regarding this design pattern will be migrated from this repository into a separate website in the future.
|
||||
|
||||
## About
|
||||
|
||||
*container-interop* tries to identify and standardize features in *container* objects (service locators,
|
||||
dependency injection containers, etc.) to achieve interoperability.
|
||||
|
||||
Through discussions and trials, we try to create a standard, made of common interfaces but also recommendations.
|
||||
|
||||
If PHP projects that provide container implementations begin to adopt these common standards, then PHP
|
||||
applications and projects that use containers can depend on the common interfaces instead of specific
|
||||
implementations. This facilitates a high-level of interoperability and flexibility that allows users to consume
|
||||
*any* container implementation that can be adapted to these interfaces.
|
||||
|
||||
The work done in this project is not officially endorsed by the [PHP-FIG](http://www.php-fig.org/), but it is being
|
||||
worked on by members of PHP-FIG and other good developers. We adhere to the spirit and ideals of PHP-FIG, and hope
|
||||
this project will pave the way for one or more future PSRs.
|
||||
|
||||
|
||||
## Installation
|
||||
|
||||
You can install this package through Composer:
|
||||
|
||||
```json
|
||||
composer require container-interop/container-interop
|
||||
```
|
||||
|
||||
The packages adheres to the [SemVer](http://semver.org/) specification, and there will be full backward compatibility
|
||||
between minor versions.
|
||||
|
||||
## Standards
|
||||
|
||||
### Available
|
||||
|
||||
- [`ContainerInterface`](src/Interop/Container/ContainerInterface.php).
|
||||
[Description](docs/ContainerInterface.md) [Meta Document](docs/ContainerInterface-meta.md).
|
||||
Describes the interface of a container that exposes methods to read its entries.
|
||||
- [*Delegate lookup feature*](docs/Delegate-lookup.md).
|
||||
[Meta Document](docs/Delegate-lookup-meta.md).
|
||||
Describes the ability for a container to delegate the lookup of its dependencies to a third-party container. This
|
||||
feature lets several containers work together in a single application.
|
||||
|
||||
### Proposed
|
||||
|
||||
View open [request for comments](https://github.com/container-interop/container-interop/labels/RFC)
|
||||
|
||||
## Compatible projects
|
||||
|
||||
### Projects implementing `ContainerInterface`
|
||||
|
||||
- [Acclimate](https://github.com/jeremeamia/acclimate-container): Adapters for
|
||||
Aura.Di, Laravel, Nette DI, Pimple, Symfony DI, ZF2 Service manager, ZF2
|
||||
Dependency injection and any container using `ArrayAccess`
|
||||
- [Aura.Di](https://github.com/auraphp/Aura.Di)
|
||||
- [auryn-container-interop](https://github.com/elazar/auryn-container-interop)
|
||||
- [Burlap](https://github.com/codeeverything/burlap)
|
||||
- [Chernozem](https://github.com/pyrsmk/Chernozem)
|
||||
- [Data Manager](https://github.com/chrismichaels84/data-manager)
|
||||
- [Disco](https://github.com/bitexpert/disco)
|
||||
- [InDI](https://github.com/idealogica/indi)
|
||||
- [League/Container](http://container.thephpleague.com/)
|
||||
- [Mouf](http://mouf-php.com)
|
||||
- [Njasm Container](https://github.com/njasm/container)
|
||||
- [PHP-DI](http://php-di.org)
|
||||
- [Picotainer](https://github.com/thecodingmachine/picotainer)
|
||||
- [PimpleInterop](https://github.com/moufmouf/pimple-interop)
|
||||
- [Pimple3-ContainerInterop](https://github.com/Sam-Burns/pimple3-containerinterop) (using Pimple v3)
|
||||
- [SitePoint Container](https://github.com/sitepoint/Container)
|
||||
- [Thruster Container](https://github.com/ThrusterIO/container) (PHP7 only)
|
||||
- [Ultra-Lite Container](https://github.com/ultra-lite/container)
|
||||
- [Unbox](https://github.com/mindplay-dk/unbox)
|
||||
- [XStatic](https://github.com/jeremeamia/xstatic)
|
||||
- [Zend\ServiceManager](https://github.com/zendframework/zend-servicemanager)
|
||||
- [Zit](https://github.com/inxilpro/Zit)
|
||||
|
||||
### Projects implementing the *delegate lookup* feature
|
||||
|
||||
- [Aura.Di](https://github.com/auraphp/Aura.Di)
|
||||
- [Burlap](https://github.com/codeeverything/burlap)
|
||||
- [Chernozem](https://github.com/pyrsmk/Chernozem)
|
||||
- [InDI](https://github.com/idealogica/indi)
|
||||
- [League/Container](http://container.thephpleague.com/)
|
||||
- [Mouf](http://mouf-php.com)
|
||||
- [Picotainer](https://github.com/thecodingmachine/picotainer)
|
||||
- [PHP-DI](http://php-di.org)
|
||||
- [PimpleInterop](https://github.com/moufmouf/pimple-interop)
|
||||
- [Ultra-Lite Container](https://github.com/ultra-lite/container)
|
||||
|
||||
### Middlewares implementing `ContainerInterface`
|
||||
|
||||
- [Alias-Container](https://github.com/thecodingmachine/alias-container): add
|
||||
aliases support to any container
|
||||
- [Prefixer-Container](https://github.com/thecodingmachine/prefixer-container):
|
||||
dynamically prefix identifiers
|
||||
- [Lazy-Container](https://github.com/snapshotpl/lazy-container): lazy services
|
||||
|
||||
### Projects using `ContainerInterface`
|
||||
|
||||
The list below contains only a sample of all the projects consuming `ContainerInterface`. For a more complete list have a look [here](http://packanalyst.com/class?q=Interop%5CContainer%5CContainerInterface).
|
||||
|
||||
| | Downloads |
|
||||
| --- | --- |
|
||||
| [Adroit](https://github.com/bitexpert/adroit) |  |
|
||||
| [Behat](https://github.com/Behat/Behat/pull/974) |  |
|
||||
| [blast-facades](https://github.com/phpthinktank/blast-facades): Minimize complexity and represent dependencies as facades. |  |
|
||||
| [interop.silex.di](https://github.com/thecodingmachine/interop.silex.di): an extension to [Silex](http://silex.sensiolabs.org/) that adds support for any *container-interop* compatible container |  |
|
||||
| [mindplay/walkway](https://github.com/mindplay-dk/walkway): a modular request router |  |
|
||||
| [mindplay/middleman](https://github.com/mindplay-dk/middleman): minimalist PSR-7 middleware dispatcher |  |
|
||||
| [PHP-DI/Invoker](https://github.com/PHP-DI/Invoker): extensible and configurable invoker/dispatcher |  |
|
||||
| [Prophiler](https://github.com/fabfuel/prophiler) |  |
|
||||
| [Silly](https://github.com/mnapoli/silly): CLI micro-framework |  |
|
||||
| [Slim v3](https://github.com/slimphp/Slim) |  |
|
||||
| [Splash](http://mouf-php.com/packages/mouf/mvc.splash-common/version/8.0-dev/README.md) |  |
|
||||
| [Woohoo Labs. Harmony](https://github.com/woohoolabs/harmony): a flexible micro-framework |  |
|
||||
| [zend-expressive](https://github.com/zendframework/zend-expressive) |  |
|
||||
|
||||
|
||||
## Workflow
|
||||
|
||||
Everyone is welcome to join and contribute.
|
||||
|
||||
The general workflow looks like this:
|
||||
|
||||
1. Someone opens a discussion (GitHub issue) to suggest an interface
|
||||
1. Feedback is gathered
|
||||
1. The interface is added to a development branch
|
||||
1. We release alpha versions so that the interface can be experimented with
|
||||
1. Discussions and edits ensue until the interface is deemed stable by a general consensus
|
||||
1. A new minor version of the package is released
|
||||
|
||||
We try to not break BC by creating new interfaces instead of editing existing ones.
|
||||
|
||||
While we currently work on interfaces, we are open to anything that might help towards interoperability, may that
|
||||
be code, best practices, etc.
|
@ -1,15 +0,0 @@
|
||||
{
|
||||
"name": "container-interop/container-interop",
|
||||
"type": "library",
|
||||
"description": "Promoting the interoperability of container objects (DIC, SL, etc.)",
|
||||
"homepage": "https://github.com/container-interop/container-interop",
|
||||
"license": "MIT",
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Interop\\Container\\": "src/Interop/Container/"
|
||||
}
|
||||
},
|
||||
"require": {
|
||||
"psr/container": "^1.0"
|
||||
}
|
||||
}
|
@ -1,114 +0,0 @@
|
||||
# ContainerInterface Meta Document
|
||||
|
||||
## Introduction
|
||||
|
||||
This document describes the process and discussions that lead to the `ContainerInterface`.
|
||||
Its goal is to explain the reasons behind each decision.
|
||||
|
||||
## Goal
|
||||
|
||||
The goal set by `ContainerInterface` is to standardize how frameworks and libraries make use of a
|
||||
container to obtain objects and parameters.
|
||||
|
||||
By standardizing such a behavior, frameworks and libraries using the `ContainerInterface`
|
||||
could work with any compatible container.
|
||||
That would allow end users to choose their own container based on their own preferences.
|
||||
|
||||
It is important to distinguish the two usages of a container:
|
||||
|
||||
- configuring entries
|
||||
- fetching entries
|
||||
|
||||
Most of the time, those two sides are not used by the same party.
|
||||
While it is often end users who tend to configure entries, it is generally the framework that fetch
|
||||
entries to build the application.
|
||||
|
||||
This is why this interface focuses only on how entries can be fetched from a container.
|
||||
|
||||
## Interface name
|
||||
|
||||
The interface name has been thoroughly discussed and was decided by a vote.
|
||||
|
||||
The list of options considered with their respective votes are:
|
||||
|
||||
- `ContainerInterface`: +8
|
||||
- `ProviderInterface`: +2
|
||||
- `LocatorInterface`: 0
|
||||
- `ReadableContainerInterface`: -5
|
||||
- `ServiceLocatorInterface`: -6
|
||||
- `ObjectFactory`: -6
|
||||
- `ObjectStore`: -8
|
||||
- `ConsumerInterface`: -9
|
||||
|
||||
[Full results of the vote](https://github.com/container-interop/container-interop/wiki/%231-interface-name:-Vote)
|
||||
|
||||
The complete discussion can be read in [the issue #1](https://github.com/container-interop/container-interop/issues/1).
|
||||
|
||||
## Interface methods
|
||||
|
||||
The choice of which methods the interface would contain was made after a statistical analysis of existing containers.
|
||||
The results of this analysis are available [in this document](https://gist.github.com/mnapoli/6159681).
|
||||
|
||||
The summary of the analysis showed that:
|
||||
|
||||
- all containers offer a method to get an entry by its id
|
||||
- a large majority name such method `get()`
|
||||
- for all containers, the `get()` method has 1 mandatory parameter of type string
|
||||
- some containers have an optional additional argument for `get()`, but it doesn't have the same purpose between containers
|
||||
- a large majority of the containers offer a method to test if it can return an entry by its id
|
||||
- a majority name such method `has()`
|
||||
- for all containers offering `has()`, the method has exactly 1 parameter of type string
|
||||
- a large majority of the containers throw an exception rather than returning null when an entry is not found in `get()`
|
||||
- a large majority of the containers don't implement `ArrayAccess`
|
||||
|
||||
The question of whether to include methods to define entries has been discussed in
|
||||
[issue #1](https://github.com/container-interop/container-interop/issues/1).
|
||||
It has been judged that such methods do not belong in the interface described here because it is out of its scope
|
||||
(see the "Goal" section).
|
||||
|
||||
As a result, the `ContainerInterface` contains two methods:
|
||||
|
||||
- `get()`, returning anything, with one mandatory string parameter. Should throw an exception if the entry is not found.
|
||||
- `has()`, returning a boolean, with one mandatory string parameter.
|
||||
|
||||
### Number of parameters in `get()` method
|
||||
|
||||
While `ContainerInterface` only defines one mandatory parameter in `get()`, it is not incompatible with
|
||||
existing containers that have additional optional parameters. PHP allows an implementation to offer more parameters
|
||||
as long as they are optional, because the implementation *does* satisfy the interface.
|
||||
|
||||
This issue has been discussed in [issue #6](https://github.com/container-interop/container-interop/issues/6).
|
||||
|
||||
### Type of the `$id` parameter
|
||||
|
||||
The type of the `$id` parameter in `get()` and `has()` has been discussed in
|
||||
[issue #6](https://github.com/container-interop/container-interop/issues/6).
|
||||
While `string` is used in all the containers that were analyzed, it was suggested that allowing
|
||||
anything (such as objects) could allow containers to offer a more advanced query API.
|
||||
|
||||
An example given was to use the container as an object builder. The `$id` parameter would then be an
|
||||
object that would describe how to create an instance.
|
||||
|
||||
The conclusion of the discussion was that this was beyond the scope of getting entries from a container without
|
||||
knowing how the container provided them, and it was more fit for a factory.
|
||||
|
||||
## Contributors
|
||||
|
||||
Are listed here all people that contributed in the discussions or votes, by alphabetical order:
|
||||
|
||||
- [Amy Stephen](https://github.com/AmyStephen)
|
||||
- [David Négrier](https://github.com/moufmouf)
|
||||
- [Don Gilbert](https://github.com/dongilbert)
|
||||
- [Jason Judge](https://github.com/judgej)
|
||||
- [Jeremy Lindblom](https://github.com/jeremeamia)
|
||||
- [Marco Pivetta](https://github.com/Ocramius)
|
||||
- [Matthieu Napoli](https://github.com/mnapoli)
|
||||
- [Paul M. Jones](https://github.com/pmjones)
|
||||
- [Stephan Hochdörfer](https://github.com/shochdoerfer)
|
||||
- [Taylor Otwell](https://github.com/taylorotwell)
|
||||
|
||||
## Relevant links
|
||||
|
||||
- [`ContainerInterface.php`](https://github.com/container-interop/container-interop/blob/master/src/Interop/Container/ContainerInterface.php)
|
||||
- [List of all issues](https://github.com/container-interop/container-interop/issues?labels=ContainerInterface&milestone=&page=1&state=closed)
|
||||
- [Vote for the interface name](https://github.com/container-interop/container-interop/wiki/%231-interface-name:-Vote)
|
@ -1,158 +0,0 @@
|
||||
Container interface
|
||||
===================
|
||||
|
||||
This document describes a common interface for dependency injection containers.
|
||||
|
||||
The goal set by `ContainerInterface` is to standardize how frameworks and libraries make use of a
|
||||
container to obtain objects and parameters (called *entries* in the rest of this document).
|
||||
|
||||
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD",
|
||||
"SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be
|
||||
interpreted as described in [RFC 2119][].
|
||||
|
||||
The word `implementor` in this document is to be interpreted as someone
|
||||
implementing the `ContainerInterface` in a dependency injection-related library or framework.
|
||||
Users of dependency injections containers (DIC) are referred to as `user`.
|
||||
|
||||
[RFC 2119]: http://tools.ietf.org/html/rfc2119
|
||||
|
||||
1. Specification
|
||||
-----------------
|
||||
|
||||
### 1.1 Basics
|
||||
|
||||
- The `Interop\Container\ContainerInterface` exposes two methods : `get` and `has`.
|
||||
|
||||
- `get` takes one mandatory parameter: an entry identifier. It MUST be a string.
|
||||
A call to `get` can return anything (a *mixed* value), or throws an exception if the identifier
|
||||
is not known to the container. Two successive calls to `get` with the same
|
||||
identifier SHOULD return the same value. However, depending on the `implementor`
|
||||
design and/or `user` configuration, different values might be returned, so
|
||||
`user` SHOULD NOT rely on getting the same value on 2 successive calls.
|
||||
While `ContainerInterface` only defines one mandatory parameter in `get()`, implementations
|
||||
MAY accept additional optional parameters.
|
||||
|
||||
- `has` takes one unique parameter: an entry identifier. It MUST return `true`
|
||||
if an entry identifier is known to the container and `false` if it is not.
|
||||
`has($id)` returning true does not mean that `get($id)` will not throw an exception.
|
||||
It does however mean that `get($id)` will not throw a `NotFoundException`.
|
||||
|
||||
### 1.2 Exceptions
|
||||
|
||||
Exceptions directly thrown by the container MUST implement the
|
||||
[`Interop\Container\Exception\ContainerException`](../src/Interop/Container/Exception/ContainerException.php).
|
||||
|
||||
A call to the `get` method with a non-existing id SHOULD throw a
|
||||
[`Interop\Container\Exception\NotFoundException`](../src/Interop/Container/Exception/NotFoundException.php).
|
||||
|
||||
### 1.3 Additional features
|
||||
|
||||
This section describes additional features that MAY be added to a container. Containers are not
|
||||
required to implement these features to respect the ContainerInterface.
|
||||
|
||||
#### 1.3.1 Delegate lookup feature
|
||||
|
||||
The goal of the *delegate lookup* feature is to allow several containers to share entries.
|
||||
Containers implementing this feature can perform dependency lookups in other containers.
|
||||
|
||||
Containers implementing this feature will offer a greater lever of interoperability
|
||||
with other containers. Implementation of this feature is therefore RECOMMENDED.
|
||||
|
||||
A container implementing this feature:
|
||||
|
||||
- MUST implement the `ContainerInterface`
|
||||
- MUST provide a way to register a delegate container (using a constructor parameter, or a setter,
|
||||
or any possible way). The delegate container MUST implement the `ContainerInterface`.
|
||||
|
||||
When a container is configured to use a delegate container for dependencies:
|
||||
|
||||
- Calls to the `get` method should only return an entry if the entry is part of the container.
|
||||
If the entry is not part of the container, an exception should be thrown
|
||||
(as requested by the `ContainerInterface`).
|
||||
- Calls to the `has` method should only return `true` if the entry is part of the container.
|
||||
If the entry is not part of the container, `false` should be returned.
|
||||
- If the fetched entry has dependencies, **instead** of performing
|
||||
the dependency lookup in the container, the lookup is performed on the *delegate container*.
|
||||
|
||||
Important! By default, the lookup SHOULD be performed on the delegate container **only**, not on the container itself.
|
||||
|
||||
It is however allowed for containers to provide exception cases for special entries, and a way to lookup
|
||||
into the same container (or another container) instead of the delegate container.
|
||||
|
||||
2. Package
|
||||
----------
|
||||
|
||||
The interfaces and classes described as well as relevant exception are provided as part of the
|
||||
[container-interop/container-interop](https://packagist.org/packages/container-interop/container-interop) package.
|
||||
|
||||
3. `Interop\Container\ContainerInterface`
|
||||
-----------------------------------------
|
||||
|
||||
```php
|
||||
<?php
|
||||
namespace Interop\Container;
|
||||
|
||||
use Interop\Container\Exception\ContainerException;
|
||||
use Interop\Container\Exception\NotFoundException;
|
||||
|
||||
/**
|
||||
* Describes the interface of a container that exposes methods to read its entries.
|
||||
*/
|
||||
interface ContainerInterface
|
||||
{
|
||||
/**
|
||||
* Finds an entry of the container by its identifier and returns it.
|
||||
*
|
||||
* @param string $id Identifier of the entry to look for.
|
||||
*
|
||||
* @throws NotFoundException No entry was found for this identifier.
|
||||
* @throws ContainerException Error while retrieving the entry.
|
||||
*
|
||||
* @return mixed Entry.
|
||||
*/
|
||||
public function get($id);
|
||||
|
||||
/**
|
||||
* Returns true if the container can return an entry for the given identifier.
|
||||
* Returns false otherwise.
|
||||
*
|
||||
* `has($id)` returning true does not mean that `get($id)` will not throw an exception.
|
||||
* It does however mean that `get($id)` will not throw a `NotFoundException`.
|
||||
*
|
||||
* @param string $id Identifier of the entry to look for.
|
||||
*
|
||||
* @return boolean
|
||||
*/
|
||||
public function has($id);
|
||||
}
|
||||
```
|
||||
|
||||
4. `Interop\Container\Exception\ContainerException`
|
||||
---------------------------------------------------
|
||||
|
||||
```php
|
||||
<?php
|
||||
namespace Interop\Container\Exception;
|
||||
|
||||
/**
|
||||
* Base interface representing a generic exception in a container.
|
||||
*/
|
||||
interface ContainerException
|
||||
{
|
||||
}
|
||||
```
|
||||
|
||||
5. `Interop\Container\Exception\NotFoundException`
|
||||
---------------------------------------------------
|
||||
|
||||
```php
|
||||
<?php
|
||||
namespace Interop\Container\Exception;
|
||||
|
||||
/**
|
||||
* No entry was found in the container.
|
||||
*/
|
||||
interface NotFoundException extends ContainerException
|
||||
{
|
||||
}
|
||||
```
|
@ -1,259 +0,0 @@
|
||||
Delegate lookup feature Meta Document
|
||||
=====================================
|
||||
|
||||
1. Summary
|
||||
----------
|
||||
|
||||
This document describes the *delegate lookup feature*.
|
||||
Containers are not required to implement this feature to respect the `ContainerInterface`.
|
||||
However, containers implementing this feature will offer a greater lever of interoperability
|
||||
with other containers, allowing multiple containers to share entries in the same application.
|
||||
Implementation of this feature is therefore recommanded.
|
||||
|
||||
2. Why Bother?
|
||||
--------------
|
||||
|
||||
The [`ContainerInterface`](../src/Interop/Container/ContainerInterface.php) ([meta doc](ContainerInterface.md))
|
||||
standardizes how frameworks and libraries make use of a container to obtain objects and parameters.
|
||||
|
||||
By standardizing such a behavior, frameworks and libraries relying on the `ContainerInterface`
|
||||
could work with any compatible container.
|
||||
That would allow end users to choose their own container based on their own preferences.
|
||||
|
||||
The `ContainerInterface` is also enough if we want to have several containers side-by-side in the same
|
||||
application. For instance, this is what the [CompositeContainer](https://github.com/jeremeamia/acclimate-container/blob/master/src/CompositeContainer.php)
|
||||
class of [Acclimate](https://github.com/jeremeamia/acclimate-container) is designed for:
|
||||
|
||||

|
||||
|
||||
However, an instance in container 1 cannot reference an instance in container 2.
|
||||
|
||||
It would be better if an instance of container 1 could reference an instance in container 2,
|
||||
and the opposite should be true.
|
||||
|
||||

|
||||
|
||||
In the sample above, entry 1 in container 1 is referencing entry 3 in container 2.
|
||||
|
||||
3. Scope
|
||||
--------
|
||||
|
||||
### 3.1 Goals
|
||||
|
||||
The goal of the *delegate lookup* feature is to allow several containers to share entries.
|
||||
|
||||
4. Approaches
|
||||
-------------
|
||||
|
||||
### 4.1 Chosen Approach
|
||||
|
||||
Containers implementing this feature can perform dependency lookups in other containers.
|
||||
|
||||
A container implementing this feature:
|
||||
|
||||
- must implement the `ContainerInterface`
|
||||
- must provide a way to register a *delegate container* (using a constructor parameter, or a setter, or any
|
||||
possible way). The *delegate container* must implement the `ContainerInterface`.
|
||||
|
||||
When a *delegate container* is configured on a container:
|
||||
|
||||
- Calls to the `get` method should only return an entry if the entry is part of the container.
|
||||
If the entry is not part of the container, an exception should be thrown (as required in the `ContainerInterface`).
|
||||
- Calls to the `has` method should only return *true* if the entry is part of the container.
|
||||
If the entry is not part of the container, *false* should be returned.
|
||||
- Finally, the important part: if the entry we are fetching has dependencies,
|
||||
**instead** of perfoming the dependency lookup in the container, the lookup is performed on the *delegate container*.
|
||||
|
||||
Important! By default, the lookup should be performed on the delegate container **only**, not on the container itself.
|
||||
|
||||
It is however allowed for containers to provide exception cases for special entries, and a way to lookup into
|
||||
the same container (or another container) instead of the delegate container.
|
||||
|
||||
### 4.2 Typical usage
|
||||
|
||||
The *delegate container* will usually be a composite container. A composite container is a container that
|
||||
contains several other containers. When performing a lookup on a composite container, the inner containers are
|
||||
queried until one container returns an entry.
|
||||
An inner container implementing the *delegate lookup feature* will return entries it contains, but if these
|
||||
entries have dependencies, the dependencies lookup calls will be performed on the composite container, giving
|
||||
a chance to all containers to answer.
|
||||
|
||||
Interestingly enough, the order in which containers are added in the composite container matters. Indeed,
|
||||
the first containers to be added in the composite container can "override" the entries of containers with
|
||||
lower priority.
|
||||
|
||||

|
||||
|
||||
In the example above, "container 2" contains a controller "myController" and the controller is referencing an
|
||||
"entityManager" entry. "Container 1" contains also an entry named "entityManager".
|
||||
Without the *delegate lookup* feature, when requesting the "myController" instance to container 2, it would take
|
||||
in charge the instanciation of both entries.
|
||||
|
||||
However, using the *delegate lookup* feature, here is what happens when we ask the composite container for the
|
||||
"myController" instance:
|
||||
|
||||
- The composite container asks container 1 if if contains the "myController" instance. The answer is no.
|
||||
- The composite container asks container 2 if if contains the "myController" instance. The answer is yes.
|
||||
- The composite container performs a `get` call on container 2 for the "myController" instance.
|
||||
- Container 2 sees that "myController" has a dependency on "entityManager".
|
||||
- Container 2 delegates the lookup of "entityManager" to the composite container.
|
||||
- The composite container asks container 1 if if contains the "entityManager" instance. The answer is yes.
|
||||
- The composite container performs a `get` call on container 1 for the "entityManager" instance.
|
||||
|
||||
In the end, we get a controller instanciated by container 2 that references an entityManager instanciated
|
||||
by container 1.
|
||||
|
||||
### 4.3 Alternative: the fallback strategy
|
||||
|
||||
The first proposed approach we tried was to perform all the lookups in the "local" container,
|
||||
and if a lookup fails in the container, to use the delegate container. In this scenario, the
|
||||
delegate container is used in "fallback" mode.
|
||||
|
||||
This strategy has been described in @moufmouf blog post: http://mouf-php.com/container-interop-whats-next (solution 1).
|
||||
It was also discussed [here](https://github.com/container-interop/container-interop/pull/8#issuecomment-33570697) and
|
||||
[here](https://github.com/container-interop/container-interop/pull/20#issuecomment-56599631).
|
||||
|
||||
Problems with this strategy:
|
||||
|
||||
- Heavy problem regarding infinite loops
|
||||
- Unable to overload a container entry with the delegate container entry
|
||||
|
||||
### 4.4 Alternative: force implementing an interface
|
||||
|
||||
The first proposed approach was to develop a `ParentAwareContainerInterface` interface.
|
||||
It was proposed here: https://github.com/container-interop/container-interop/pull/8
|
||||
|
||||
The interface would have had the behaviour of the delegate lookup feature but would have forced the addition of
|
||||
a `setParentContainter` method:
|
||||
|
||||
```php
|
||||
interface ParentAwareContainerInterface extends ReadableContainerInterface {
|
||||
/**
|
||||
* Sets the parent container associated to that container. This container will call
|
||||
* the parent container to fetch dependencies.
|
||||
*
|
||||
* @param ContainerInterface $container
|
||||
*/
|
||||
public function setParentContainer(ContainerInterface $container);
|
||||
}
|
||||
```
|
||||
|
||||
The interface idea was first questioned by @Ocramius [here](https://github.com/container-interop/container-interop/pull/8#issuecomment-51721777).
|
||||
@Ocramius expressed the idea that an interface should not contain setters, otherwise, it is forcing implementation
|
||||
details on the class implementing the interface.
|
||||
Then @mnapoli made a proposal for a "convention" [here](https://github.com/container-interop/container-interop/pull/8#issuecomment-51841079),
|
||||
this idea was further discussed until all participants in the discussion agreed to remove the interface idea
|
||||
and replace it with a "standard" feature.
|
||||
|
||||
**Pros:**
|
||||
|
||||
If we had had an interface, we could have delegated the registration of the delegate/composite container to the
|
||||
the delegate/composite container itself.
|
||||
For instance:
|
||||
|
||||
```php
|
||||
$containerA = new ContainerA();
|
||||
$containerB = new ContainerB();
|
||||
|
||||
$compositeContainer = new CompositeContainer([$containerA, $containerB]);
|
||||
|
||||
// The call to 'setParentContainer' is delegated to the CompositeContainer
|
||||
// It is not the responsibility of the user anymore.
|
||||
class CompositeContainer {
|
||||
...
|
||||
|
||||
public function __construct($containers) {
|
||||
foreach ($containers as $container) {
|
||||
if ($container instanceof ParentAwareContainerInterface) {
|
||||
$container->setParentContainer($this);
|
||||
}
|
||||
}
|
||||
...
|
||||
}
|
||||
}
|
||||
|
||||
```
|
||||
|
||||
**Cons:**
|
||||
|
||||
Cons have been extensively discussed [here](https://github.com/container-interop/container-interop/pull/8#issuecomment-51721777).
|
||||
Basically, forcing a setter into an interface is a bad idea. Setters are similar to constructor arguments,
|
||||
and it's a bad idea to standardize a constructor: how the delegate container is configured into a container is an implementation detail. This outweights the benefits of the interface.
|
||||
|
||||
### 4.4 Alternative: no exception case for delegate lookups
|
||||
|
||||
Originally, the proposed wording for delegate lookup calls was:
|
||||
|
||||
> Important! The lookup MUST be performed on the delegate container **only**, not on the container itself.
|
||||
|
||||
This was later replaced by:
|
||||
|
||||
> Important! By default, the lookup SHOULD be performed on the delegate container **only**, not on the container itself.
|
||||
>
|
||||
> It is however allowed for containers to provide exception cases for special entries, and a way to lookup
|
||||
> into the same container (or another container) instead of the delegate container.
|
||||
|
||||
Exception cases have been allowed to avoid breaking dependencies with some services that must be provided
|
||||
by the container (on @njasm proposal). This was proposed here: https://github.com/container-interop/container-interop/pull/20#issuecomment-56597235
|
||||
|
||||
### 4.5 Alternative: having one of the containers act as the composite container
|
||||
|
||||
In real-life scenarios, we usually have a big framework (Symfony 2, Zend Framework 2, etc...) and we want to
|
||||
add another DI container to this container. Most of the time, the "big" framework will be responsible for
|
||||
creating the controller's instances, using it's own DI container. Until *container-interop* is fully adopted,
|
||||
the "big" framework will not be aware of the existence of a composite container that it should use instead
|
||||
of its own container.
|
||||
|
||||
For this real-life use cases, @mnapoli and @moufmouf proposed to extend the "big" framework's DI container
|
||||
to make it act as a composite container.
|
||||
|
||||
This has been discussed [here](https://github.com/container-interop/container-interop/pull/8#issuecomment-40367194)
|
||||
and [here](http://mouf-php.com/container-interop-whats-next#solution4).
|
||||
|
||||
This was implemented in Symfony 2 using:
|
||||
|
||||
- [interop.symfony.di](https://github.com/thecodingmachine/interop.symfony.di/tree/v0.1.0)
|
||||
- [framework interop](https://github.com/mnapoli/framework-interop/)
|
||||
|
||||
This was implemented in Silex using:
|
||||
|
||||
- [interop.silex.di](https://github.com/thecodingmachine/interop.silex.di)
|
||||
|
||||
Having a container act as the composite container is not part of the delegate lookup standard because it is
|
||||
simply a temporary design pattern used to make existing frameworks that do not support yet ContainerInterop
|
||||
play nice with other DI containers.
|
||||
|
||||
|
||||
5. Implementations
|
||||
------------------
|
||||
|
||||
The following projects already implement the delegate lookup feature:
|
||||
|
||||
- [Mouf](http://mouf-php.com), through the [`setDelegateLookupContainer` method](https://github.com/thecodingmachine/mouf/blob/2.0/src/Mouf/MoufManager.php#L2120)
|
||||
- [PHP-DI](http://php-di.org/), through the [`$wrapperContainer` parameter of the constructor](https://github.com/mnapoli/PHP-DI/blob/master/src/DI/Container.php#L72)
|
||||
- [pimple-interop](https://github.com/moufmouf/pimple-interop), through the [`$container` parameter of the constructor](https://github.com/moufmouf/pimple-interop/blob/master/src/Interop/Container/Pimple/PimpleInterop.php#L62)
|
||||
|
||||
6. People
|
||||
---------
|
||||
|
||||
Are listed here all people that contributed in the discussions, by alphabetical order:
|
||||
|
||||
- [Alexandru Pătrănescu](https://github.com/drealecs)
|
||||
- [Ben Peachey](https://github.com/potherca)
|
||||
- [David Négrier](https://github.com/moufmouf)
|
||||
- [Jeremy Lindblom](https://github.com/jeremeamia)
|
||||
- [Marco Pivetta](https://github.com/Ocramius)
|
||||
- [Matthieu Napoli](https://github.com/mnapoli)
|
||||
- [Nelson J Morais](https://github.com/njasm)
|
||||
- [Phil Sturgeon](https://github.com/philsturgeon)
|
||||
- [Stephan Hochdörfer](https://github.com/shochdoerfer)
|
||||
|
||||
7. Relevant Links
|
||||
-----------------
|
||||
|
||||
_**Note:** Order descending chronologically._
|
||||
|
||||
- [Pull request on the delegate lookup feature](https://github.com/container-interop/container-interop/pull/20)
|
||||
- [Pull request on the interface idea](https://github.com/container-interop/container-interop/pull/8)
|
||||
- [Original article exposing the delegate lookup idea along many others](http://mouf-php.com/container-interop-whats-next)
|
||||
|
@ -1,60 +0,0 @@
|
||||
Delegate lookup feature
|
||||
=======================
|
||||
|
||||
This document describes a standard for dependency injection containers.
|
||||
|
||||
The goal set by the *delegate lookup* feature is to allow several containers to share entries.
|
||||
Containers implementing this feature can perform dependency lookups in other containers.
|
||||
|
||||
Containers implementing this feature will offer a greater lever of interoperability
|
||||
with other containers. Implementation of this feature is therefore RECOMMENDED.
|
||||
|
||||
The key words "MUST", "MUST NOT", "REQUIRED", "SHALL", "SHALL NOT", "SHOULD",
|
||||
"SHOULD NOT", "RECOMMENDED", "MAY", and "OPTIONAL" in this document are to be
|
||||
interpreted as described in [RFC 2119][].
|
||||
|
||||
The word `implementor` in this document is to be interpreted as someone
|
||||
implementing the delegate lookup feature in a dependency injection-related library or framework.
|
||||
Users of dependency injections containers (DIC) are referred to as `user`.
|
||||
|
||||
[RFC 2119]: http://tools.ietf.org/html/rfc2119
|
||||
|
||||
1. Vocabulary
|
||||
-------------
|
||||
|
||||
In a dependency injection container, the container is used to fetch entries.
|
||||
Entries can have dependencies on other entries. Usually, these other entries are fetched by the container.
|
||||
|
||||
The *delegate lookup* feature is the ability for a container to fetch dependencies in
|
||||
another container. In the rest of the document, the word "container" will reference the container
|
||||
implemented by the implementor. The word "delegate container" will reference the container we are
|
||||
fetching the dependencies from.
|
||||
|
||||
2. Specification
|
||||
----------------
|
||||
|
||||
A container implementing the *delegate lookup* feature:
|
||||
|
||||
- MUST implement the [`ContainerInterface`](ContainerInterface.md)
|
||||
- MUST provide a way to register a delegate container (using a constructor parameter, or a setter,
|
||||
or any possible way). The delegate container MUST implement the [`ContainerInterface`](ContainerInterface.md).
|
||||
|
||||
When a container is configured to use a delegate container for dependencies:
|
||||
|
||||
- Calls to the `get` method should only return an entry if the entry is part of the container.
|
||||
If the entry is not part of the container, an exception should be thrown
|
||||
(as requested by the [`ContainerInterface`](ContainerInterface.md)).
|
||||
- Calls to the `has` method should only return `true` if the entry is part of the container.
|
||||
If the entry is not part of the container, `false` should be returned.
|
||||
- If the fetched entry has dependencies, **instead** of performing
|
||||
the dependency lookup in the container, the lookup is performed on the *delegate container*.
|
||||
|
||||
Important: By default, the dependency lookups SHOULD be performed on the delegate container **only**, not on the container itself.
|
||||
|
||||
It is however allowed for containers to provide exception cases for special entries, and a way to lookup
|
||||
into the same container (or another container) instead of the delegate container.
|
||||
|
||||
3. Package / Interface
|
||||
----------------------
|
||||
|
||||
This feature is not tied to any code, interface or package.
|
Binary file not shown.
Before Width: | Height: | Size: 25 KiB |
Binary file not shown.
Before Width: | Height: | Size: 16 KiB |
Binary file not shown.
Before Width: | Height: | Size: 16 KiB |
@ -1,15 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* @license http://www.opensource.org/licenses/mit-license.php MIT (see the LICENSE file)
|
||||
*/
|
||||
|
||||
namespace Interop\Container;
|
||||
|
||||
use Psr\Container\ContainerInterface as PsrContainerInterface;
|
||||
|
||||
/**
|
||||
* Describes the interface of a container that exposes methods to read its entries.
|
||||
*/
|
||||
interface ContainerInterface extends PsrContainerInterface
|
||||
{
|
||||
}
|
@ -1,15 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* @license http://www.opensource.org/licenses/mit-license.php MIT (see the LICENSE file)
|
||||
*/
|
||||
|
||||
namespace Interop\Container\Exception;
|
||||
|
||||
use Psr\Container\ContainerExceptionInterface as PsrContainerException;
|
||||
|
||||
/**
|
||||
* Base interface representing a generic exception in a container.
|
||||
*/
|
||||
interface ContainerException extends PsrContainerException
|
||||
{
|
||||
}
|
@ -1,15 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* @license http://www.opensource.org/licenses/mit-license.php MIT (see the LICENSE file)
|
||||
*/
|
||||
|
||||
namespace Interop\Container\Exception;
|
||||
|
||||
use Psr\Container\NotFoundExceptionInterface as PsrNotFoundException;
|
||||
|
||||
/**
|
||||
* No entry was found in the container.
|
||||
*/
|
||||
interface NotFoundException extends ContainerException, PsrNotFoundException
|
||||
{
|
||||
}
|
@ -1,26 +0,0 @@
|
||||
{
|
||||
"active": true,
|
||||
"name": "Instantiator",
|
||||
"slug": "instantiator",
|
||||
"docsSlug": "doctrine-instantiator",
|
||||
"codePath": "/src",
|
||||
"versions": [
|
||||
{
|
||||
"name": "1.1",
|
||||
"branchName": "master",
|
||||
"slug": "latest",
|
||||
"aliases": [
|
||||
"current",
|
||||
"stable"
|
||||
],
|
||||
"maintained": true,
|
||||
"current": true
|
||||
},
|
||||
{
|
||||
"name": "1.0",
|
||||
"branchName": "1.0.x",
|
||||
"slug": "1.0"
|
||||
}
|
||||
]
|
||||
}
|
||||
|
35
vendor/doctrine/instantiator/CONTRIBUTING.md
vendored
35
vendor/doctrine/instantiator/CONTRIBUTING.md
vendored
@ -1,35 +0,0 @@
|
||||
# Contributing
|
||||
|
||||
* Follow the [Doctrine Coding Standard](https://github.com/doctrine/coding-standard)
|
||||
* The project will follow strict [object calisthenics](http://www.slideshare.net/guilhermeblanco/object-calisthenics-applied-to-php)
|
||||
* Any contribution must provide tests for additional introduced conditions
|
||||
* Any un-confirmed issue needs a failing test case before being accepted
|
||||
* Pull requests must be sent from a new hotfix/feature branch, not from `master`.
|
||||
|
||||
## Installation
|
||||
|
||||
To install the project and run the tests, you need to clone it first:
|
||||
|
||||
```sh
|
||||
$ git clone git://github.com/doctrine/instantiator.git
|
||||
```
|
||||
|
||||
You will then need to run a composer installation:
|
||||
|
||||
```sh
|
||||
$ cd Instantiator
|
||||
$ curl -s https://getcomposer.org/installer | php
|
||||
$ php composer.phar update
|
||||
```
|
||||
|
||||
## Testing
|
||||
|
||||
The PHPUnit version to be used is the one installed as a dev- dependency via composer:
|
||||
|
||||
```sh
|
||||
$ ./vendor/bin/phpunit
|
||||
```
|
||||
|
||||
Accepted coverage for new contributions is 80%. Any contribution not satisfying this requirement
|
||||
won't be merged.
|
||||
|
19
vendor/doctrine/instantiator/LICENSE
vendored
19
vendor/doctrine/instantiator/LICENSE
vendored
@ -1,19 +0,0 @@
|
||||
Copyright (c) 2014 Doctrine Project
|
||||
|
||||
Permission is hereby granted, free of charge, to any person obtaining a copy of
|
||||
this software and associated documentation files (the "Software"), to deal in
|
||||
the Software without restriction, including without limitation the rights to
|
||||
use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies
|
||||
of the Software, and to permit persons to whom the Software is furnished to do
|
||||
so, subject to the following conditions:
|
||||
|
||||
The above copyright notice and this permission notice shall be included in all
|
||||
copies or substantial portions of the Software.
|
||||
|
||||
THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
||||
IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
||||
FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
||||
AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
||||
LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
||||
OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
|
||||
SOFTWARE.
|
39
vendor/doctrine/instantiator/README.md
vendored
39
vendor/doctrine/instantiator/README.md
vendored
@ -1,39 +0,0 @@
|
||||
# Instantiator
|
||||
|
||||
This library provides a way of avoiding usage of constructors when instantiating PHP classes.
|
||||
|
||||
[](https://travis-ci.org/doctrine/instantiator)
|
||||
[](https://scrutinizer-ci.com/g/doctrine/instantiator/?branch=master)
|
||||
[](https://scrutinizer-ci.com/g/doctrine/instantiator/?branch=master)
|
||||
[](https://www.versioneye.com/package/php--doctrine--instantiator)
|
||||
|
||||
[](https://packagist.org/packages/doctrine/instantiator)
|
||||
[](https://packagist.org/packages/doctrine/instantiator)
|
||||
|
||||
## Installation
|
||||
|
||||
The suggested installation method is via [composer](https://getcomposer.org/):
|
||||
|
||||
```sh
|
||||
php composer.phar require "doctrine/instantiator:~1.0.3"
|
||||
```
|
||||
|
||||
## Usage
|
||||
|
||||
The instantiator is able to create new instances of any class without using the constructor or any API of the class
|
||||
itself:
|
||||
|
||||
```php
|
||||
$instantiator = new \Doctrine\Instantiator\Instantiator();
|
||||
|
||||
$instance = $instantiator->instantiate(\My\ClassName\Here::class);
|
||||
```
|
||||
|
||||
## Contributing
|
||||
|
||||
Please read the [CONTRIBUTING.md](CONTRIBUTING.md) contents if you wish to help out!
|
||||
|
||||
## Credits
|
||||
|
||||
This library was migrated from [ocramius/instantiator](https://github.com/Ocramius/Instantiator), which
|
||||
has been donated to the doctrine organization, and which is now deprecated in favour of this package.
|
47
vendor/doctrine/instantiator/composer.json
vendored
47
vendor/doctrine/instantiator/composer.json
vendored
@ -1,47 +0,0 @@
|
||||
{
|
||||
"name": "doctrine/instantiator",
|
||||
"description": "A small, lightweight utility to instantiate objects in PHP without invoking their constructors",
|
||||
"type": "library",
|
||||
"license": "MIT",
|
||||
"homepage": "https://www.doctrine-project.org/projects/instantiator.html",
|
||||
"keywords": [
|
||||
"instantiate",
|
||||
"constructor"
|
||||
],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Marco Pivetta",
|
||||
"email": "ocramius@gmail.com",
|
||||
"homepage": "http://ocramius.github.com/"
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"php": "^7.1"
|
||||
},
|
||||
"require-dev": {
|
||||
"ext-phar": "*",
|
||||
"ext-pdo": "*",
|
||||
"doctrine/coding-standard": "^6.0",
|
||||
"phpbench/phpbench": "^0.13",
|
||||
"phpstan/phpstan-phpunit": "^0.11",
|
||||
"phpstan/phpstan-shim": "^0.11",
|
||||
"phpunit/phpunit": "^7.0"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Doctrine\\Instantiator\\": "src/Doctrine/Instantiator/"
|
||||
}
|
||||
},
|
||||
"autoload-dev": {
|
||||
"psr-0": {
|
||||
"DoctrineTest\\InstantiatorPerformance\\": "tests",
|
||||
"DoctrineTest\\InstantiatorTest\\": "tests",
|
||||
"DoctrineTest\\InstantiatorTestAsset\\": "tests"
|
||||
}
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.2.x-dev"
|
||||
}
|
||||
}
|
||||
}
|
68
vendor/doctrine/instantiator/docs/en/index.rst
vendored
68
vendor/doctrine/instantiator/docs/en/index.rst
vendored
@ -1,68 +0,0 @@
|
||||
Introduction
|
||||
============
|
||||
|
||||
This library provides a way of avoiding usage of constructors when instantiating PHP classes.
|
||||
|
||||
Installation
|
||||
============
|
||||
|
||||
The suggested installation method is via `composer`_:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ composer require doctrine/instantiator
|
||||
|
||||
Usage
|
||||
=====
|
||||
|
||||
The instantiator is able to create new instances of any class without
|
||||
using the constructor or any API of the class itself:
|
||||
|
||||
.. code-block:: php
|
||||
|
||||
<?php
|
||||
|
||||
use Doctrine\Instantiator\Instantiator;
|
||||
use App\Entities\User;
|
||||
|
||||
$instantiator = new Instantiator();
|
||||
|
||||
$user = $instantiator->instantiate(User::class);
|
||||
|
||||
Contributing
|
||||
============
|
||||
|
||||
- Follow the `Doctrine Coding Standard`_
|
||||
- The project will follow strict `object calisthenics`_
|
||||
- Any contribution must provide tests for additional introduced
|
||||
conditions
|
||||
- Any un-confirmed issue needs a failing test case before being
|
||||
accepted
|
||||
- Pull requests must be sent from a new hotfix/feature branch, not from
|
||||
``master``.
|
||||
|
||||
Testing
|
||||
=======
|
||||
|
||||
The PHPUnit version to be used is the one installed as a dev- dependency
|
||||
via composer:
|
||||
|
||||
.. code-block:: console
|
||||
|
||||
$ ./vendor/bin/phpunit
|
||||
|
||||
Accepted coverage for new contributions is 80%. Any contribution not
|
||||
satisfying this requirement won’t be merged.
|
||||
|
||||
Credits
|
||||
=======
|
||||
|
||||
This library was migrated from `ocramius/instantiator`_, which has been
|
||||
donated to the doctrine organization, and which is now deprecated in
|
||||
favour of this package.
|
||||
|
||||
.. _composer: https://getcomposer.org/
|
||||
.. _CONTRIBUTING.md: CONTRIBUTING.md
|
||||
.. _ocramius/instantiator: https://github.com/Ocramius/Instantiator
|
||||
.. _Doctrine Coding Standard: https://github.com/doctrine/coding-standard
|
||||
.. _object calisthenics: http://www.slideshare.net/guilhermeblanco/object-calisthenics-applied-to-php
|
@ -1,4 +0,0 @@
|
||||
.. toctree::
|
||||
:depth: 3
|
||||
|
||||
index
|
4
vendor/doctrine/instantiator/phpbench.json
vendored
4
vendor/doctrine/instantiator/phpbench.json
vendored
@ -1,4 +0,0 @@
|
||||
{
|
||||
"bootstrap": "vendor/autoload.php",
|
||||
"path": "tests/DoctrineTest/InstantiatorPerformance"
|
||||
}
|
35
vendor/doctrine/instantiator/phpcs.xml.dist
vendored
35
vendor/doctrine/instantiator/phpcs.xml.dist
vendored
@ -1,35 +0,0 @@
|
||||
<?xml version="1.0"?>
|
||||
<ruleset>
|
||||
<arg name="basepath" value="."/>
|
||||
<arg name="extensions" value="php"/>
|
||||
<arg name="parallel" value="80"/>
|
||||
<arg name="cache" value=".phpcs-cache"/>
|
||||
<arg name="colors"/>
|
||||
|
||||
<!-- Ignore warnings, show progress of the run and show sniff names -->
|
||||
<arg value="nps"/>
|
||||
|
||||
<file>src</file>
|
||||
<file>tests</file>
|
||||
|
||||
<rule ref="Doctrine">
|
||||
<exclude name="SlevomatCodingStandard.TypeHints.DeclareStrictTypes"/>
|
||||
<exclude name="SlevomatCodingStandard.TypeHints.TypeHintDeclaration.MissingParameterTypeHint"/>
|
||||
<exclude name="SlevomatCodingStandard.TypeHints.TypeHintDeclaration.MissingReturnTypeHint"/>
|
||||
<exclude name="SlevomatCodingStandard.Exceptions.ReferenceThrowableOnly.ReferencedGeneralException"/>
|
||||
</rule>
|
||||
|
||||
<rule ref="SlevomatCodingStandard.Classes.SuperfluousAbstractClassNaming">
|
||||
<exclude-pattern>tests/DoctrineTest/InstantiatorTestAsset/AbstractClassAsset.php</exclude-pattern>
|
||||
</rule>
|
||||
|
||||
<rule ref="SlevomatCodingStandard.Classes.SuperfluousExceptionNaming">
|
||||
<exclude-pattern>src/Doctrine/Instantiator/Exception/UnexpectedValueException.php</exclude-pattern>
|
||||
<exclude-pattern>src/Doctrine/Instantiator/Exception/InvalidArgumentException.php</exclude-pattern>
|
||||
</rule>
|
||||
|
||||
<rule ref="SlevomatCodingStandard.Classes.SuperfluousInterfaceNaming">
|
||||
<exclude-pattern>src/Doctrine/Instantiator/Exception/ExceptionInterface.php</exclude-pattern>
|
||||
<exclude-pattern>src/Doctrine/Instantiator/InstantiatorInterface.php</exclude-pattern>
|
||||
</rule>
|
||||
</ruleset>
|
19
vendor/doctrine/instantiator/phpstan.neon.dist
vendored
19
vendor/doctrine/instantiator/phpstan.neon.dist
vendored
@ -1,19 +0,0 @@
|
||||
includes:
|
||||
- vendor/phpstan/phpstan-phpunit/extension.neon
|
||||
- vendor/phpstan/phpstan-phpunit/rules.neon
|
||||
|
||||
parameters:
|
||||
level: max
|
||||
paths:
|
||||
- src
|
||||
- tests
|
||||
|
||||
ignoreErrors:
|
||||
-
|
||||
message: '#::__construct\(\) does not call parent constructor from#'
|
||||
path: '*/tests/DoctrineTest/InstantiatorTestAsset/*.php'
|
||||
|
||||
# dynamic properties confuse static analysis
|
||||
-
|
||||
message: '#Access to an undefined property object::\$foo\.#'
|
||||
path: '*/tests/DoctrineTest/InstantiatorTest/InstantiatorTest.php'
|
@ -1,12 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Doctrine\Instantiator\Exception;
|
||||
|
||||
use Throwable;
|
||||
|
||||
/**
|
||||
* Base exception marker interface for the instantiator component
|
||||
*/
|
||||
interface ExceptionInterface extends Throwable
|
||||
{
|
||||
}
|
@ -1,37 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Doctrine\Instantiator\Exception;
|
||||
|
||||
use InvalidArgumentException as BaseInvalidArgumentException;
|
||||
use ReflectionClass;
|
||||
use const PHP_VERSION_ID;
|
||||
use function interface_exists;
|
||||
use function sprintf;
|
||||
use function trait_exists;
|
||||
|
||||
/**
|
||||
* Exception for invalid arguments provided to the instantiator
|
||||
*/
|
||||
class InvalidArgumentException extends BaseInvalidArgumentException implements ExceptionInterface
|
||||
{
|
||||
public static function fromNonExistingClass(string $className) : self
|
||||
{
|
||||
if (interface_exists($className)) {
|
||||
return new self(sprintf('The provided type "%s" is an interface, and can not be instantiated', $className));
|
||||
}
|
||||
|
||||
if (PHP_VERSION_ID >= 50400 && trait_exists($className)) {
|
||||
return new self(sprintf('The provided type "%s" is a trait, and can not be instantiated', $className));
|
||||
}
|
||||
|
||||
return new self(sprintf('The provided class "%s" does not exist', $className));
|
||||
}
|
||||
|
||||
public static function fromAbstractClass(ReflectionClass $reflectionClass) : self
|
||||
{
|
||||
return new self(sprintf(
|
||||
'The provided class "%s" is abstract, and can not be instantiated',
|
||||
$reflectionClass->getName()
|
||||
));
|
||||
}
|
||||
}
|
@ -1,48 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Doctrine\Instantiator\Exception;
|
||||
|
||||
use Exception;
|
||||
use ReflectionClass;
|
||||
use UnexpectedValueException as BaseUnexpectedValueException;
|
||||
use function sprintf;
|
||||
|
||||
/**
|
||||
* Exception for given parameters causing invalid/unexpected state on instantiation
|
||||
*/
|
||||
class UnexpectedValueException extends BaseUnexpectedValueException implements ExceptionInterface
|
||||
{
|
||||
public static function fromSerializationTriggeredException(
|
||||
ReflectionClass $reflectionClass,
|
||||
Exception $exception
|
||||
) : self {
|
||||
return new self(
|
||||
sprintf(
|
||||
'An exception was raised while trying to instantiate an instance of "%s" via un-serialization',
|
||||
$reflectionClass->getName()
|
||||
),
|
||||
0,
|
||||
$exception
|
||||
);
|
||||
}
|
||||
|
||||
public static function fromUncleanUnSerialization(
|
||||
ReflectionClass $reflectionClass,
|
||||
string $errorString,
|
||||
int $errorCode,
|
||||
string $errorFile,
|
||||
int $errorLine
|
||||
) : self {
|
||||
return new self(
|
||||
sprintf(
|
||||
'Could not produce an instance of "%s" via un-serialization, since an error was triggered '
|
||||
. 'in file "%s" at line "%d"',
|
||||
$reflectionClass->getName(),
|
||||
$errorFile,
|
||||
$errorLine
|
||||
),
|
||||
0,
|
||||
new Exception($errorString, $errorCode)
|
||||
);
|
||||
}
|
||||
}
|
@ -1,203 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Doctrine\Instantiator;
|
||||
|
||||
use ArrayIterator;
|
||||
use Doctrine\Instantiator\Exception\InvalidArgumentException;
|
||||
use Doctrine\Instantiator\Exception\UnexpectedValueException;
|
||||
use Exception;
|
||||
use ReflectionClass;
|
||||
use ReflectionException;
|
||||
use Serializable;
|
||||
use function class_exists;
|
||||
use function is_subclass_of;
|
||||
use function restore_error_handler;
|
||||
use function set_error_handler;
|
||||
use function sprintf;
|
||||
use function strlen;
|
||||
use function unserialize;
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
final class Instantiator implements InstantiatorInterface
|
||||
{
|
||||
/**
|
||||
* Markers used internally by PHP to define whether {@see \unserialize} should invoke
|
||||
* the method {@see \Serializable::unserialize()} when dealing with classes implementing
|
||||
* the {@see \Serializable} interface.
|
||||
*/
|
||||
public const SERIALIZATION_FORMAT_USE_UNSERIALIZER = 'C';
|
||||
public const SERIALIZATION_FORMAT_AVOID_UNSERIALIZER = 'O';
|
||||
|
||||
/**
|
||||
* Used to instantiate specific classes, indexed by class name.
|
||||
*
|
||||
* @var callable[]
|
||||
*/
|
||||
private static $cachedInstantiators = [];
|
||||
|
||||
/**
|
||||
* Array of objects that can directly be cloned, indexed by class name.
|
||||
*
|
||||
* @var object[]
|
||||
*/
|
||||
private static $cachedCloneables = [];
|
||||
|
||||
/**
|
||||
* {@inheritDoc}
|
||||
*/
|
||||
public function instantiate($className)
|
||||
{
|
||||
if (isset(self::$cachedCloneables[$className])) {
|
||||
return clone self::$cachedCloneables[$className];
|
||||
}
|
||||
|
||||
if (isset(self::$cachedInstantiators[$className])) {
|
||||
$factory = self::$cachedInstantiators[$className];
|
||||
|
||||
return $factory();
|
||||
}
|
||||
|
||||
return $this->buildAndCacheFromFactory($className);
|
||||
}
|
||||
|
||||
/**
|
||||
* Builds the requested object and caches it in static properties for performance
|
||||
*
|
||||
* @return object
|
||||
*/
|
||||
private function buildAndCacheFromFactory(string $className)
|
||||
{
|
||||
$factory = self::$cachedInstantiators[$className] = $this->buildFactory($className);
|
||||
$instance = $factory();
|
||||
|
||||
if ($this->isSafeToClone(new ReflectionClass($instance))) {
|
||||
self::$cachedCloneables[$className] = clone $instance;
|
||||
}
|
||||
|
||||
return $instance;
|
||||
}
|
||||
|
||||
/**
|
||||
* Builds a callable capable of instantiating the given $className without
|
||||
* invoking its constructor.
|
||||
*
|
||||
* @throws InvalidArgumentException
|
||||
* @throws UnexpectedValueException
|
||||
* @throws ReflectionException
|
||||
*/
|
||||
private function buildFactory(string $className) : callable
|
||||
{
|
||||
$reflectionClass = $this->getReflectionClass($className);
|
||||
|
||||
if ($this->isInstantiableViaReflection($reflectionClass)) {
|
||||
return [$reflectionClass, 'newInstanceWithoutConstructor'];
|
||||
}
|
||||
|
||||
$serializedString = sprintf(
|
||||
'%s:%d:"%s":0:{}',
|
||||
is_subclass_of($className, Serializable::class) ? self::SERIALIZATION_FORMAT_USE_UNSERIALIZER : self::SERIALIZATION_FORMAT_AVOID_UNSERIALIZER,
|
||||
strlen($className),
|
||||
$className
|
||||
);
|
||||
|
||||
$this->checkIfUnSerializationIsSupported($reflectionClass, $serializedString);
|
||||
|
||||
return static function () use ($serializedString) {
|
||||
return unserialize($serializedString);
|
||||
};
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws InvalidArgumentException
|
||||
* @throws ReflectionException
|
||||
*/
|
||||
private function getReflectionClass(string $className) : ReflectionClass
|
||||
{
|
||||
if (! class_exists($className)) {
|
||||
throw InvalidArgumentException::fromNonExistingClass($className);
|
||||
}
|
||||
|
||||
$reflection = new ReflectionClass($className);
|
||||
|
||||
if ($reflection->isAbstract()) {
|
||||
throw InvalidArgumentException::fromAbstractClass($reflection);
|
||||
}
|
||||
|
||||
return $reflection;
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws UnexpectedValueException
|
||||
*/
|
||||
private function checkIfUnSerializationIsSupported(ReflectionClass $reflectionClass, string $serializedString) : void
|
||||
{
|
||||
set_error_handler(static function (int $code, string $message, string $file, int $line) use ($reflectionClass, &$error) : bool {
|
||||
$error = UnexpectedValueException::fromUncleanUnSerialization(
|
||||
$reflectionClass,
|
||||
$message,
|
||||
$code,
|
||||
$file,
|
||||
$line
|
||||
);
|
||||
|
||||
return true;
|
||||
});
|
||||
|
||||
try {
|
||||
$this->attemptInstantiationViaUnSerialization($reflectionClass, $serializedString);
|
||||
} finally {
|
||||
restore_error_handler();
|
||||
}
|
||||
|
||||
if ($error) {
|
||||
throw $error;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @throws UnexpectedValueException
|
||||
*/
|
||||
private function attemptInstantiationViaUnSerialization(ReflectionClass $reflectionClass, string $serializedString) : void
|
||||
{
|
||||
try {
|
||||
unserialize($serializedString);
|
||||
} catch (Exception $exception) {
|
||||
throw UnexpectedValueException::fromSerializationTriggeredException($reflectionClass, $exception);
|
||||
}
|
||||
}
|
||||
|
||||
private function isInstantiableViaReflection(ReflectionClass $reflectionClass) : bool
|
||||
{
|
||||
return ! ($this->hasInternalAncestors($reflectionClass) && $reflectionClass->isFinal());
|
||||
}
|
||||
|
||||
/**
|
||||
* Verifies whether the given class is to be considered internal
|
||||
*/
|
||||
private function hasInternalAncestors(ReflectionClass $reflectionClass) : bool
|
||||
{
|
||||
do {
|
||||
if ($reflectionClass->isInternal()) {
|
||||
return true;
|
||||
}
|
||||
|
||||
$reflectionClass = $reflectionClass->getParentClass();
|
||||
} while ($reflectionClass);
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
/**
|
||||
* Checks if a class is cloneable
|
||||
*
|
||||
* Classes implementing `__clone` cannot be safely cloned, as that may cause side-effects.
|
||||
*/
|
||||
private function isSafeToClone(ReflectionClass $reflection) : bool
|
||||
{
|
||||
return $reflection->isCloneable()
|
||||
&& ! $reflection->hasMethod('__clone')
|
||||
&& ! $reflection->isSubclassOf(ArrayIterator::class);
|
||||
}
|
||||
}
|
@ -1,20 +0,0 @@
|
||||
<?php
|
||||
|
||||
namespace Doctrine\Instantiator;
|
||||
|
||||
use Doctrine\Instantiator\Exception\ExceptionInterface;
|
||||
|
||||
/**
|
||||
* Instantiator provides utility methods to build objects without invoking their constructors
|
||||
*/
|
||||
interface InstantiatorInterface
|
||||
{
|
||||
/**
|
||||
* @param string $className
|
||||
*
|
||||
* @return object
|
||||
*
|
||||
* @throws ExceptionInterface
|
||||
*/
|
||||
public function instantiate($className);
|
||||
}
|
@ -1,28 +0,0 @@
|
||||
---
|
||||
name: PHP client issue
|
||||
about: Report an issue with the PHP client library
|
||||
|
||||
---
|
||||
|
||||
**Issue description**
|
||||
<!-- One or two sentences describing the problem -->
|
||||
|
||||
**Environment**
|
||||
<!-- The server or development environment where you're seeing the problem -->
|
||||
|
||||
* OS name and version:
|
||||
* PHP version:
|
||||
* Web server name and version:
|
||||
* `google/recaptcha` version:
|
||||
* Browser name and version:
|
||||
|
||||
**Reproducing the issue**
|
||||
<!-- Where possible link to a URL where the problem can be seen or show code that causes it -->
|
||||
|
||||
* URL (optional): <!-- if your integration is already deployed and the issue is visible -->
|
||||
* Code (optional): <!-- share a link to the code you're using or an example in a Gist -->
|
||||
|
||||
***User steps***
|
||||
<!-- Detail the necessary steps to reproduce the issue. Include the output of any error messages. -->
|
||||
|
||||
1. Visit page...
|
7
vendor/google/recaptcha/.gitignore
vendored
7
vendor/google/recaptcha/.gitignore
vendored
@ -1,7 +0,0 @@
|
||||
/.php_cs.cache
|
||||
/.phpunit.result.cache
|
||||
/build
|
||||
/composer.lock
|
||||
/examples/config.php
|
||||
/nbproject/private/
|
||||
/vendor/
|
33
vendor/google/recaptcha/.travis.yml
vendored
33
vendor/google/recaptcha/.travis.yml
vendored
@ -1,33 +0,0 @@
|
||||
dist: trusty
|
||||
|
||||
language: php
|
||||
|
||||
sudo: false
|
||||
|
||||
php:
|
||||
- '5.5'
|
||||
- '5.6'
|
||||
- '7.0'
|
||||
- '7.1'
|
||||
- '7.2'
|
||||
- '7.3'
|
||||
|
||||
before_script:
|
||||
- composer install
|
||||
- phpenv version-name | grep ^5.[34] && echo "extension=apc.so" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini ; true
|
||||
- phpenv version-name | grep ^5.[34] && echo "apc.enable_cli=1" >> ~/.phpenv/versions/$(phpenv version-name)/etc/php.ini ; true
|
||||
|
||||
script:
|
||||
- mkdir -p build/logs
|
||||
- composer run-script lint
|
||||
- composer run-script test
|
||||
|
||||
after_success:
|
||||
- travis_retry php vendor/bin/php-coveralls
|
||||
|
||||
cache:
|
||||
directories:
|
||||
- "$HOME/.composer/cache/files"
|
||||
|
||||
git:
|
||||
depth: 5
|
64
vendor/google/recaptcha/ARCHITECTURE.md
vendored
64
vendor/google/recaptcha/ARCHITECTURE.md
vendored
@ -1,64 +0,0 @@
|
||||
# Architecture
|
||||
|
||||
The general pattern of usage is to instantiate the `ReCaptcha` class with your
|
||||
secret key, specify any additional validation rules, and then call `verify()`
|
||||
with the reCAPTCHA response and user's IP address. For example:
|
||||
|
||||
```php
|
||||
<?php
|
||||
$recaptcha = new \ReCaptcha\ReCaptcha($secret);
|
||||
$resp = $recaptcha->setExpectedHostname('recaptcha-demo.appspot.com')
|
||||
->verify($gRecaptchaResponse, $remoteIp);
|
||||
if ($resp->isSuccess()) {
|
||||
// Verified!
|
||||
} else {
|
||||
$errors = $resp->getErrorCodes();
|
||||
}
|
||||
```
|
||||
|
||||
By default, this will use the
|
||||
[`stream_context_create()`](https://secure.php.net/stream_context_create) and
|
||||
[`file_get_contents()`](https://secure.php.net/file_get_contents) to make a POST
|
||||
request to the reCAPTCHA service. This is handled by the
|
||||
[`RequestMethod\Post`](./src/ReCaptcha/RequestMethod/Post.php) class.
|
||||
|
||||
## Alternate request methods
|
||||
|
||||
You may need to use other methods for making requests in your environment. The
|
||||
[`ReCaptcha`](./src/ReCaptcha/ReCaptcha.php) class allows an optional
|
||||
[`RequestMethod`](./src/ReCaptcha/RequestMethod.php) instance to configure this.
|
||||
For example, if you want to use [cURL](https://secure.php.net/curl) instead you
|
||||
can do this:
|
||||
|
||||
```php
|
||||
<?php
|
||||
$recaptcha = new \ReCaptcha\ReCaptcha($secret, new \ReCaptcha\RequestMethod\CurlPost());
|
||||
```
|
||||
|
||||
Alternatively, you can also use a [socket](https://secure.php.net/fsockopen):
|
||||
|
||||
```php
|
||||
<?php
|
||||
$recaptcha = new \ReCaptcha\ReCaptcha($secret, new \ReCaptcha\RequestMethod\SocketPost());
|
||||
```
|
||||
|
||||
## Adding new request methods
|
||||
|
||||
Create a class that implements the
|
||||
[`RequestMethod`](./src/ReCaptcha/RequestMethod.php) interface. The convention
|
||||
is to name this class `RequestMethod\`_MethodType_`Post` and create a separate
|
||||
`RequestMethod\`_MethodType_ class that wraps just the calls to the network
|
||||
calls themselves. This means that the `RequestMethod\`_MethodType_`Post` can be
|
||||
unit tested by passing in a mock. Take a look at
|
||||
[`RequestMethod\CurlPost`](./src/ReCaptcha/RequestMethod/CurlPost.php) and
|
||||
[`RequestMethod\Curl`](./src/ReCaptcha/RequestMethod/Curl.php) with the matching
|
||||
[`RequestMethod/CurlPostTest`](./tests/ReCaptcha/RequestMethod/CurlPostTest.php)
|
||||
to see this pattern in action.
|
||||
|
||||
### Error conventions
|
||||
|
||||
The client returns the response as provided by the reCAPTCHA services augmented
|
||||
with additional error codes based on the client's checks. When adding a new
|
||||
[`RequestMethod`](./src/ReCaptcha/RequestMethod.php) ensure that it returns the
|
||||
`ReCaptcha::E_CONNECTION_FAILED` and `ReCaptcha::E_BAD_RESPONSE` where
|
||||
appropriate.
|
49
vendor/google/recaptcha/CONTRIBUTING.md
vendored
49
vendor/google/recaptcha/CONTRIBUTING.md
vendored
@ -1,49 +0,0 @@
|
||||
# Contributing
|
||||
|
||||
Want to contribute? Great! First, read this page (including the small print at
|
||||
the end).
|
||||
|
||||
## Contributor License Agreement
|
||||
|
||||
Before we can use your code, you must sign the [Google Individual Contributor
|
||||
License
|
||||
Agreement](https://developers.google.com/open-source/cla/individual?csw=1)
|
||||
(CLA), which you can do online. The CLA is necessary mainly because you own the
|
||||
copyright to your changes, even after your contribution becomes part of our
|
||||
codebase, so we need your permission to use and distribute your code. We also
|
||||
need to be sure of various other things—for instance that you'll tell us if you
|
||||
know that your code infringes on other people's patents. You don't have to sign
|
||||
the CLA until after you've submitted your code for review (a link will be
|
||||
automatically added to your Pull Request) and a member has approved it, but you
|
||||
must do it before we can put your code into our codebase. Before you start
|
||||
working on a larger contribution, you should get in touch with us first through
|
||||
the issue tracker with your idea so that we can help out and possibly guide you.
|
||||
Coordinating up front makes it much easier to avoid frustration later on.
|
||||
|
||||
## Linting and testing
|
||||
|
||||
We use PHP Coding Standards Fixer to maintain coding standards and PHPUnit to
|
||||
run our tests. For convenience, there are Composer scripts to run each of these:
|
||||
|
||||
```sh
|
||||
composer run-script lint
|
||||
composer run-script test
|
||||
```
|
||||
|
||||
These are run automatically by [Travis
|
||||
CI](https://travis-ci.org/google/recaptcha) against your Pull Request, but it's
|
||||
a good idea to run them locally before submission to avoid getting things
|
||||
bounced back. That said, tests can be a little daunting so feel free to submit
|
||||
your PR and ask for help.
|
||||
|
||||
## Code reviews
|
||||
|
||||
All submissions, including submissions by project members, require review.
|
||||
Reviews are conducted on the Pull Requests. The reviews are there to ensure and
|
||||
improve code quality, so treat them like a discussion and opportunity to learn.
|
||||
Don't get disheartened if your Pull Request isn't just automatically approved.
|
||||
|
||||
### The small print
|
||||
|
||||
Contributions made by corporations are covered by a different agreement than the
|
||||
one above, the Software Grant and Corporate Contributor License Agreement.
|
17
vendor/google/recaptcha/README.md
vendored
17
vendor/google/recaptcha/README.md
vendored
@ -13,7 +13,7 @@ and v3.
|
||||
- reCAPTCHA: https://www.google.com/recaptcha
|
||||
- This repo: https://github.com/google/recaptcha
|
||||
- Hosted demo: https://recaptcha-demo.appspot.com/
|
||||
- Version: 1.2.3
|
||||
- Version: 1.3.0
|
||||
- License: BSD, see [LICENSE](LICENSE)
|
||||
|
||||
## Installation
|
||||
@ -26,17 +26,22 @@ Use [Composer](https://getcomposer.org) to install this library from Packagist:
|
||||
Run the following command from your project directory to add the dependency:
|
||||
|
||||
```sh
|
||||
composer require google/recaptcha "^1.2"
|
||||
composer require google/recaptcha "^1.3"
|
||||
```
|
||||
|
||||
Alternatively, add the dependency directly to your `composer.json` file:
|
||||
|
||||
```json
|
||||
"require": {
|
||||
"google/recaptcha": "^1.2"
|
||||
"google/recaptcha": "^1.3"
|
||||
}
|
||||
```
|
||||
|
||||
### Support for earlier versions of PHP
|
||||
|
||||
The 1.3 release moves to PHP 8 and up. For earlier versions, you will need to
|
||||
stay with the 1.2 releases.
|
||||
|
||||
### Direct download
|
||||
|
||||
Download the [ZIP file](https://github.com/google/recaptcha/archive/master.zip)
|
||||
@ -66,7 +71,9 @@ This library comes in when you need to verify the user's response. On the PHP
|
||||
side you need the response from the reCAPTCHA service and secret key from your
|
||||
credentials. Instantiate the `ReCaptcha` class with your secret key, specify any
|
||||
additional validation rules, and then call `verify()` with the reCAPTCHA
|
||||
response and user's IP address. For example:
|
||||
response (usually in `$_POST['g-recaptcha-response']` or the response from
|
||||
`grecaptcha.execute()` in JS which is in `$gRecaptchaResponse` in the example)
|
||||
and user's IP address. For example:
|
||||
|
||||
```php
|
||||
<?php
|
||||
@ -89,7 +96,7 @@ The following methods are available:
|
||||
from an Android app. Again, you must do this if you have disabled
|
||||
"Domain/Package Name Validation" for your credentials.
|
||||
- `setExpectedAction($action)`: ensures the action matches for the v3 API.
|
||||
- `setScoreThreshold($threshold)`: set a score theshold for responses from the
|
||||
- `setScoreThreshold($threshold)`: set a score threshold for responses from the
|
||||
v3 API
|
||||
- `setChallengeTimeout($timeoutSeconds)`: set a timeout between the user passing
|
||||
the reCAPTCHA and your server processing it.
|
||||
|
16
vendor/google/recaptcha/composer.json
vendored
16
vendor/google/recaptcha/composer.json
vendored
@ -10,12 +10,12 @@
|
||||
"source": "https://github.com/google/recaptcha"
|
||||
},
|
||||
"require": {
|
||||
"php": ">=5.5"
|
||||
"php": ">=8"
|
||||
},
|
||||
"require-dev": {
|
||||
"phpunit/phpunit": "^4.8.36|^5.7.27|^6.59|^7.5.11",
|
||||
"friendsofphp/php-cs-fixer": "^2.2.20|^2.15",
|
||||
"php-coveralls/php-coveralls": "^2.1"
|
||||
"phpunit/phpunit": "^10",
|
||||
"friendsofphp/php-cs-fixer": "^3.14",
|
||||
"php-coveralls/php-coveralls": "^2.5"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
@ -24,13 +24,13 @@
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "1.2.x-dev"
|
||||
"dev-master": "1.3.x-dev"
|
||||
}
|
||||
},
|
||||
"scripts": {
|
||||
"lint": "vendor/bin/php-cs-fixer -vvv fix --using-cache=no --dry-run .",
|
||||
"lint-fix": "vendor/bin/php-cs-fixer -vvv fix --using-cache=no .",
|
||||
"test": "vendor/bin/phpunit --colors=always",
|
||||
"lint": "PHP_CS_FIXER_IGNORE_ENV=1 vendor/bin/php-cs-fixer -vvv fix --using-cache=no --dry-run .",
|
||||
"lint-fix": "PHP_CS_FIXER_IGNORE_ENV=1 vendor/bin/php-cs-fixer -vvv fix --using-cache=no .",
|
||||
"test": "XDEBUG_MODE=coverage vendor/bin/phpunit",
|
||||
"serve-examples": "@php -S localhost:8080 -t examples"
|
||||
},
|
||||
"config": {
|
||||
|
@ -1,42 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
// Redirect to HTTPS by default (for AppEngine)
|
||||
if (isset($_SERVER['HTTP_X_FORWARDED_PROTO'])) {
|
||||
if ($_SERVER['HTTP_X_FORWARDED_PROTO'] === 'http') {
|
||||
header('HTTP/1.1 301 Moved Permanently');
|
||||
header('Location: https://'.$_SERVER['SERVER_NAME'].$_SERVER['REQUEST_URI']);
|
||||
exit(0);
|
||||
} else {
|
||||
header('Strict-Transport-Security: max-age=63072000; includeSubDomains; preload');
|
||||
}
|
||||
}
|
46
vendor/google/recaptcha/examples/config.php.dist
vendored
46
vendor/google/recaptcha/examples/config.php.dist
vendored
@ -1,46 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
return [
|
||||
'v2-standard' => [
|
||||
'site' => '',
|
||||
'secret' => '',
|
||||
],
|
||||
'v2-invisible' => [
|
||||
'site' => '',
|
||||
'secret' => '',
|
||||
],
|
||||
'v3' => [
|
||||
'site' => '',
|
||||
'secret' => '',
|
||||
],
|
||||
];
|
37
vendor/google/recaptcha/examples/examples.css
vendored
37
vendor/google/recaptcha/examples/examples.css
vendored
@ -1,37 +0,0 @@
|
||||
body {
|
||||
font-family: sans-serif;
|
||||
margin: 0;
|
||||
padding: 0;
|
||||
}
|
||||
|
||||
h1,
|
||||
h2,
|
||||
p {
|
||||
margin: 0;
|
||||
padding: 0.5rem 0 0 0;
|
||||
font-weight: normal;
|
||||
}
|
||||
|
||||
h1,
|
||||
h2 {
|
||||
color: #222244;
|
||||
}
|
||||
|
||||
header {
|
||||
padding: 0.5rem 2rem 0.5rem 2rem;
|
||||
background: #f0f0f4;
|
||||
border-bottom: 1px solid #aaaabb;
|
||||
}
|
||||
|
||||
main {
|
||||
padding: 0.5rem 2rem 0.5rem 2rem;
|
||||
}
|
||||
|
||||
.form-field {
|
||||
display: block;
|
||||
margin: 1rem;
|
||||
}
|
||||
|
||||
.hidden {
|
||||
display: none;
|
||||
}
|
@ -1 +0,0 @@
|
||||
google-site-verification: google0afd8760fd68f119.html
|
79
vendor/google/recaptcha/examples/index.php
vendored
79
vendor/google/recaptcha/examples/index.php
vendored
@ -1,79 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
require __DIR__ . '/appengine-https.php';
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width,height=device-height,minimum-scale=1">
|
||||
<link rel="shortcut icon" href="https://www.gstatic.com/recaptcha/admin/favicon.ico" type="image/x-icon"/>
|
||||
<link rel="canonical" href="https://recaptcha-demo.appspot.com/">
|
||||
<script type="application/ld+json">{ "@context": "http://schema.org", "@type": "WebSite", "name": "reCAPTCHA demo", "url": "http://recaptcha-demo.appspot.com/" }</script>
|
||||
<meta name="description" content="reCAPTCHA demo" />
|
||||
<meta property="og:url" content="https://recaptcha-demo.appspot.com/" />
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="reCAPTCHA demo" />
|
||||
<meta property="og:description" content="Examples of the reCAPTCHA client." />
|
||||
<link rel="stylesheet" type="text/css" href="/examples.css">
|
||||
<title>reCAPTCHA demo</title>
|
||||
|
||||
<header>
|
||||
<h1>reCAPTCHA demo</h1>
|
||||
</header>
|
||||
<main>
|
||||
<p>Try out the various forms of <a href="https://www.google.com/recaptcha/">reCAPTCHA</a>.</p>
|
||||
<p>You can find the source code for these examples on GitHub in <kbd><a href="https://github.com/google/recaptcha">google/recaptcha</a></kbd>.</p>
|
||||
<ul>
|
||||
<li><h2>reCAPTCHA v2</h2>
|
||||
<ul>
|
||||
<li><a href="/recaptcha-v2-checkbox.php">"I'm not a robot" checkbox</a></li>
|
||||
<li><a href="/recaptcha-v2-checkbox-explicit.php">"I'm not a robot" checkbox - Explicit render</a></li>
|
||||
<li><a href="/recaptcha-v2-invisible.php">Invisible</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><h2>reCAPTCHA v3</h2>
|
||||
<ul>
|
||||
<li><a href="/recaptcha-v3-request-scores.php">Request scores</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
<li><h2>General</h2>
|
||||
<ul>
|
||||
<li><a href="/recaptcha-content-security-policy.php">Content Security Policy</a></li>
|
||||
</ul>
|
||||
</li>
|
||||
</ul>
|
||||
</main>
|
||||
|
||||
<!-- Google Analytics - just ignore this -->
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-123057962-1"></script>
|
||||
<script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-123057962-1');</script>
|
@ -1,152 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
require __DIR__ . '/appengine-https.php';
|
||||
|
||||
// Initiate the autoloader. The file should be generated by Composer.
|
||||
// You will provide your own autoloader or require the files directly if you did
|
||||
// not install via Composer.
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// This example shows the use of a Content Security Policy
|
||||
// https://developers.google.com/web/fundamentals/security/csp/
|
||||
|
||||
// First we generate a pseudorandom nonce for each included or inline script
|
||||
$nonce = base64_encode(openssl_random_pseudo_bytes(16));
|
||||
|
||||
// Send the CSP header
|
||||
// Try commenting out the various lines to see what effect it has
|
||||
|
||||
// NOTE: Always test your policy Content-Security-Policy-Report-Only first to
|
||||
// ensure you're not blocking any critical functionality. CSP is an important
|
||||
// security feature but you can break entire sections of your site if you
|
||||
// implement it incorrectly.
|
||||
header(
|
||||
"Content-Security-Policy: "
|
||||
."default-src 'none'; " // By default we will deny everything
|
||||
|
||||
."script-src 'nonce-".$nonce."' 'strict-dynamic'; " // nonce allowing the reCAPTCHA library and other third-party scripts to be included
|
||||
|
||||
."img-src https://www.gstatic.com/recaptcha/ https://www.google-analytics.com; " // allow images from these URLS
|
||||
."frame-src https://www.google.com/; " // allow frames from this URL
|
||||
|
||||
."style-src 'self'; " // allow style from our own origin
|
||||
."connect-src 'self'; " // allow the fetch calls to our own origin
|
||||
);
|
||||
|
||||
// Register API keys at https://www.google.com/recaptcha/admin
|
||||
$siteKey = '';
|
||||
$secret = '';
|
||||
|
||||
// Copy the config.php.dist file to config.php and update it with your keys to run the examples
|
||||
if ($siteKey == '' && is_readable(__DIR__ . '/config.php')) {
|
||||
$config = include __DIR__ . '/config.php';
|
||||
$siteKey = $config['v3']['site'];
|
||||
$secret = $config['v3']['secret'];
|
||||
}
|
||||
|
||||
// reCAPTCHA supports 40+ languages listed here: https://developers.google.com/recaptcha/docs/language
|
||||
$lang = 'en';
|
||||
|
||||
// The v3 API lets you provide some context for the check by specifying an action.
|
||||
// See: https://developers.google.com/recaptcha/docs/v3
|
||||
$pageAction = 'examples/csp';
|
||||
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width,height=device-height,minimum-scale=1">
|
||||
<link rel="shortcut icon" href="https://www.gstatic.com/recaptcha/admin/favicon.ico" type="image/x-icon"/>
|
||||
<link rel="canonical" href="https://recaptcha-demo.appspot.com/recaptcha-content-security-policy.php">
|
||||
<script type="application/ld+json">{ "@context": "http://schema.org", "@type": "WebSite", "name": "reCAPTCHA demo - Content Security Policy", "url": "https://recaptcha-demo.appspot.com/recaptcha-content-security-policy.php" }</script>
|
||||
<meta name="description" content="reCAPTCHA demo - Content Security Policy" />
|
||||
<meta property="og:url" content="https://recaptcha-demo.appspot.com/recaptcha-content-security-policy.php" />
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="reCAPTCHA demo - Content Security Policy" />
|
||||
<meta property="og:description" content="reCAPTCHA demo - Content Security Policy" />
|
||||
<link rel="stylesheet" type="text/css" href="/examples.css">
|
||||
<title>reCAPTCHA demo - Content Security Policy</title>
|
||||
<header>
|
||||
<h1>reCAPTCHA demo</h1><h2>Content Security Policy</h2>
|
||||
<p><a href="/">↩️ Home</a></p>
|
||||
</header>
|
||||
<main>
|
||||
<?php
|
||||
if ($siteKey === '' || $secret === ''):
|
||||
?>
|
||||
<h2>Add your keys</h2>
|
||||
<p>If you do not have keys already then visit <kbd> <a href = "https://www.google.com/recaptcha/admin">https://www.google.com/recaptcha/admin</a></kbd> to generate them. Edit this file and set the respective keys in <kbd>$siteKey</kbd> and <kbd>$secret</kbd>. Reload the page after this.</p>
|
||||
<?php
|
||||
else:
|
||||
?>
|
||||
<p>This example is sending the <kbd>Content-Security-Policy</kbd> header. Look at the source and inspect the network tab for this request to see what's happening. The reCAPTCHA v3 API is being called here, however you can use the same approach for the v2 API calls as well.</p>
|
||||
<p><strong>NOTE:</strong>This is a sample implementation, the score returned here is not a reflection on your Google account or type of traffic. In production, refer to the distribution of scores shown in <a href="https://www.google.com/recaptcha/admin" target="_blank">your admin interface</a> and adjust your own threshold accordingly. <strong>Do not raise issues regarding the score you see here.</strong></p>
|
||||
<ol id="recaptcha-steps">
|
||||
<li class="step0">reCAPTCHA script loading</li>
|
||||
<li class="step1 hidden"><kbd>grecaptcha.ready()</kbd> fired, calling <pre>grecaptcha.execute('<?php echo $siteKey; ?>', {action: '<?php echo $pageAction; ?>'})'</pre></li>
|
||||
<li class="step2 hidden">Received token from reCAPTCHA service, sending to our backend with:
|
||||
<pre class="token">fetch('/recaptcha-v3-verify.php?token=abc123</pre></li>
|
||||
<li class="step3 hidden">Received response from our backend: <pre class="response">{"json": "from-backend"}</pre></li>
|
||||
</ol>
|
||||
<p><a href="/recaptcha-content-security-policy.php">⤴️ Try again</a></p>
|
||||
|
||||
<!-- Add the nonce for our inline script to this tag -->
|
||||
<script nonce="<?php echo $nonce; ?>">
|
||||
var onloadCallback = function() {
|
||||
const steps = document.getElementById('recaptcha-steps');
|
||||
grecaptcha.ready(function() {
|
||||
document.querySelector('.step1').classList.remove('hidden');
|
||||
grecaptcha.execute('<?php echo $siteKey; ?>', {action: '<?php echo $pageAction; ?>'}).then(function(token) {
|
||||
document.querySelector('.token').innerHTML = 'fetch(\'/recaptcha-v3-verify.php?action=<?php echo $pageAction; ?>&token=\'' + token;
|
||||
document.querySelector('.step2').classList.remove('hidden');
|
||||
|
||||
fetch('/recaptcha-v3-verify.php?action=<?php echo $pageAction; ?>&token='+token).then(function(response) {
|
||||
response.json().then(function(data) {
|
||||
document.querySelector('.response').innerHTML = JSON.stringify(data, null, 2);
|
||||
document.querySelector('.step3').classList.remove('hidden');
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
};
|
||||
</script>
|
||||
<!-- Add the nonce value for the reCAPTCHA library to its script tag -->
|
||||
<script async defer src="https://www.google.com/recaptcha/api.js?render=<?php echo $siteKey; ?>&onload=onloadCallback" nonce="<?php echo $nonce; ?>"></script>
|
||||
|
||||
<?php
|
||||
endif;?>
|
||||
</main>
|
||||
|
||||
<!-- Google Analytics - adding nonces here for the library and the inline code -->
|
||||
<script async defer src="https://www.googletagmanager.com/gtag/js?id=UA-123057962-1" nonce="<?php echo $nonce; ?>"></script>
|
||||
<script async nonce="<?php echo $nonce; ?>">window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-123057962-1');</script>
|
@ -1,148 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
require __DIR__ . '/appengine-https.php';
|
||||
|
||||
// Initiate the autoloader. The file should be generated by Composer.
|
||||
// You will provide your own autoloader or require the files directly if you did
|
||||
// not install via Composer.
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// Register API keys at https://www.google.com/recaptcha/admin
|
||||
$siteKey = '';
|
||||
$secret = '';
|
||||
|
||||
// Copy the config.php.dist file to config.php and update it with your keys to run the examples
|
||||
if ($siteKey == '' && is_readable(__DIR__ . '/config.php')) {
|
||||
$config = include __DIR__ . '/config.php';
|
||||
$siteKey = $config['v2-standard']['site'];
|
||||
$secret = $config['v2-standard']['secret'];
|
||||
}
|
||||
|
||||
// reCAPTCHA supports 40+ languages listed here: https://developers.google.com/recaptcha/docs/language
|
||||
$lang = 'en';
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width,height=device-height,minimum-scale=1">
|
||||
<link rel="shortcut icon" href="https://www.gstatic.com/recaptcha/admin/favicon.ico" type="image/x-icon"/>
|
||||
<link rel="canonical" href="https://recaptcha-demo.appspot.com/recaptcha-v2-checkbox-explicit.php">
|
||||
<script type="application/ld+json">{ "@context": "http://schema.org", "@type": "WebSite", "name": "reCAPTCHA demo - \"I'm not a robot\" checkbox - Explicit render", "url": "https://recaptcha-demo.appspot.com/recaptcha-v2-checkbox-explicit.php" }</script>
|
||||
<meta name="description" content="reCAPTCHA demo - "I'm not a robot" checkbox - Explicit render" />
|
||||
<meta property="og:url" content="https://recaptcha-demo.appspot.com/recaptcha-v2-checkbox-explicit.php" />
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="reCAPTCHA demo - "I'm not a robot" checkbox - Explicit render" />
|
||||
<meta property="og:description" content="reCAPTCHA demo - "I'm not a robot" checkbox - Explicit render" />
|
||||
<link rel="stylesheet" type="text/css" href="/examples.css">
|
||||
<title>reCAPTCHA demo - "I'm not a robot" checkbox - Explicit render</title>
|
||||
|
||||
<header>
|
||||
<h1>reCAPTCHA demo</h1><h2>"I'm not a robot" checkbox - Explicit render</h2>
|
||||
<p><a href="/">↩️ Home</a></p>
|
||||
</header>
|
||||
<main>
|
||||
<?php
|
||||
if ($siteKey === '' || $secret === ''):
|
||||
?>
|
||||
<h2>Add your keys</h2>
|
||||
<p>If you do not have keys already then visit <kbd> <a href = "https://www.google.com/recaptcha/admin">https://www.google.com/recaptcha/admin</a></kbd> to generate them. Edit this file and set the respective keys in the <kbd>config.php</kbd> file or directly to <kbd>$siteKey</kbd> and <kbd>$secret</kbd>. Reload the page after this.</p>
|
||||
<?php
|
||||
elseif (isset($_POST['g-recaptcha-response'])):
|
||||
// The POST data here is unfiltered because this is an example.
|
||||
// In production, *always* sanitise and validate your input'
|
||||
?>
|
||||
<h2><kbd>POST</kbd> data</h2>
|
||||
<kbd><pre><?php var_export($_POST);?></pre></kbd>
|
||||
<?php
|
||||
// If the form submission includes the "g-captcha-response" field
|
||||
// Create an instance of the service using your secret
|
||||
$recaptcha = new \ReCaptcha\ReCaptcha($secret);
|
||||
|
||||
// If file_get_contents() is locked down on your PHP installation to disallow
|
||||
// its use with URLs, then you can use the alternative request method instead.
|
||||
// This makes use of fsockopen() instead.
|
||||
// $recaptcha = new \ReCaptcha\ReCaptcha($secret, new \ReCaptcha\RequestMethod\SocketPost());
|
||||
// Make the call to verify the response and also pass the user's IP address
|
||||
$resp = $recaptcha->setExpectedHostname($_SERVER['SERVER_NAME'])
|
||||
->verify($_POST['g-recaptcha-response'], $_SERVER['REMOTE_ADDR']);
|
||||
|
||||
if ($resp->isSuccess()):
|
||||
// If the response is a success, that's it!
|
||||
?>
|
||||
<h2>Success!</h2>
|
||||
<kbd><pre><?php var_export($resp);?></pre></kbd>
|
||||
<p>That's it. Everything is working. Go integrate this into your real project.</p>
|
||||
<p><a href="/recaptcha-v2-checkbox-explicit.php">⤴️ Try again</a></p>
|
||||
<?php
|
||||
else:
|
||||
// If it's not successful, then one or more error codes will be returned.
|
||||
?>
|
||||
<h2>Something went wrong</h2>
|
||||
<kbd><pre><?php var_export($resp);?></pre></kbd>
|
||||
<p>Check the error code reference at <kbd><a href="https://developers.google.com/recaptcha/docs/verify#error-code-reference">https://developers.google.com/recaptcha/docs/verify#error-code-reference</a></kbd>.
|
||||
<p><strong>Note:</strong> Error code <kbd>missing-input-response</kbd> may mean the user just didn't complete the reCAPTCHA.</p>
|
||||
<p><a href="/recaptcha-v2-checkbox-explicit.php">⤴️ Try again</a></p>
|
||||
<?php
|
||||
endif;
|
||||
else:
|
||||
// Add the g-recaptcha tag to the form you want to include the reCAPTCHA element
|
||||
?>
|
||||
<p>Complete the reCAPTCHA then submit the form.</p>
|
||||
<form action="/recaptcha-v2-checkbox-explicit.php" method="post">
|
||||
<fieldset>
|
||||
<legend>An example form</legend>
|
||||
<label class="form-field">Example input A: <input type="text" name="ex-a" value="foo"></label>
|
||||
<label class="form-field">Example input B: <input type="text" name="ex-b" value="bar"></label>
|
||||
<!-- Set up a container to render the widget -->
|
||||
<div class="g-recaptcha form-field"></div>
|
||||
<!-- Disable the button by default, will enable when the widget loads -->
|
||||
<button class="form-field" type="submit" disabled>Submit ↦</button>
|
||||
</fieldset>
|
||||
</form>
|
||||
<script type="text/javascript">
|
||||
var onloadCallback = function() {
|
||||
var captchaContainer = document.querySelector('.g-recaptcha');
|
||||
grecaptcha.render(captchaContainer, {
|
||||
'sitekey' : '<?php echo $siteKey; ?>'
|
||||
});
|
||||
document.querySelector('button[type="submit"]').disabled = false;
|
||||
};
|
||||
</script>
|
||||
<script type="text/javascript" src="https://www.google.com/recaptcha/api.js?hl=<?php echo $lang; ?>&onload=onloadCallback&render=explicit" async defer></script>
|
||||
<?php
|
||||
endif;?>
|
||||
</main>
|
||||
|
||||
<!-- Google Analytics - just ignore this -->
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-123057962-1"></script>
|
||||
<script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-123057962-1');</script>
|
@ -1,139 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
require __DIR__ . '/appengine-https.php';
|
||||
|
||||
// Initiate the autoloader. The file should be generated by Composer.
|
||||
// You will provide your own autoloader or require the files directly if you did
|
||||
// not install via Composer.
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// Register API keys at https://www.google.com/recaptcha/admin
|
||||
$siteKey = '';
|
||||
$secret = '';
|
||||
|
||||
// Copy the config.php.dist file to config.php and update it with your keys to run the examples
|
||||
if ($siteKey == '' && is_readable(__DIR__ . '/config.php')) {
|
||||
$config = include __DIR__ . '/config.php';
|
||||
$siteKey = $config['v2-standard']['site'];
|
||||
$secret = $config['v2-standard']['secret'];
|
||||
}
|
||||
|
||||
// reCAPTCHA supports 40+ languages listed here: https://developers.google.com/recaptcha/docs/language
|
||||
$lang = 'en';
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width,height=device-height,minimum-scale=1">
|
||||
<link rel="shortcut icon" href="https://www.gstatic.com/recaptcha/admin/favicon.ico" type="image/x-icon"/>
|
||||
<link rel="canonical" href="https://recaptcha-demo.appspot.com/recaptcha-v2-checkbox.php">
|
||||
<script type="application/ld+json">{ "@context": "http://schema.org", "@type": "WebSite", "name": "reCAPTCHA demo - \"I'm not a robot\" checkbox", "url": "https://recaptcha-demo.appspot.com/recaptcha-v2-checkbox.php" }</script>
|
||||
<meta name="description" content="reCAPTCHA demo - "I'm not a robot" checkbox" />
|
||||
<meta property="og:url" content="https://recaptcha-demo.appspot.com/recaptcha-v2-checkbox.php" />
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="reCAPTCHA demo - "I'm not a robot" checkbox" />
|
||||
<meta property="og:description" content="reCAPTCHA demo - "I'm not a robot" checkbox" />
|
||||
<link rel="stylesheet" type="text/css" href="/examples.css">
|
||||
<title>reCAPTCHA demo - "I'm not a robot" checkbox</title>
|
||||
|
||||
<header>
|
||||
<h1>reCAPTCHA demo</h1><h2>"I'm not a robot" checkbox</h2>
|
||||
<p><a href="/">↩️ Home</a></p>
|
||||
</header>
|
||||
<main>
|
||||
<?php
|
||||
if ($siteKey === '' || $secret === ''):
|
||||
?>
|
||||
<h2>Add your keys</h2>
|
||||
<p>If you do not have keys already then visit <kbd> <a href = "https://www.google.com/recaptcha/admin">https://www.google.com/recaptcha/admin</a></kbd> to generate them. Edit this file and set the respective keys in the <kbd>config.php</kbd> file or directly to <kbd>$siteKey</kbd> and <kbd>$secret</kbd>. Reload the page after this.</p>
|
||||
<?php
|
||||
elseif (isset($_POST['g-recaptcha-response'])):
|
||||
// The POST data here is unfiltered because this is an example.
|
||||
// In production, *always* sanitise and validate your input'
|
||||
?>
|
||||
<h2><kbd>POST</kbd> data</h2>
|
||||
<kbd><pre><?php var_export($_POST);?></pre></kbd>
|
||||
<?php
|
||||
// If the form submission includes the "g-captcha-response" field
|
||||
// Create an instance of the service using your secret
|
||||
$recaptcha = new \ReCaptcha\ReCaptcha($secret);
|
||||
|
||||
// If file_get_contents() is locked down on your PHP installation to disallow
|
||||
// its use with URLs, then you can use the alternative request method instead.
|
||||
// This makes use of fsockopen() instead.
|
||||
// $recaptcha = new \ReCaptcha\ReCaptcha($secret, new \ReCaptcha\RequestMethod\SocketPost());
|
||||
|
||||
// Make the call to verify the response and also pass the user's IP address
|
||||
$resp = $recaptcha->setExpectedHostname($_SERVER['SERVER_NAME'])
|
||||
->verify($_POST['g-recaptcha-response'], $_SERVER['REMOTE_ADDR']);
|
||||
if ($resp->isSuccess()):
|
||||
// If the response is a success, that's it!
|
||||
?>
|
||||
<h2>Success!</h2>
|
||||
<kbd><pre><?php var_export($resp);?></pre></kbd>
|
||||
<p>That's it. Everything is working. Go integrate this into your real project.</p>
|
||||
<p><a href="/recaptcha-v2-checkbox.php">⤴️ Try again</a></p>
|
||||
<?php
|
||||
else:
|
||||
// If it's not successful, then one or more error codes will be returned.
|
||||
?>
|
||||
<h2>Something went wrong</h2>
|
||||
<kbd><pre><?php var_export($resp);?></pre></kbd>
|
||||
<p>Check the error code reference at <kbd><a href="https://developers.google.com/recaptcha/docs/verify#error-code-reference">https://developers.google.com/recaptcha/docs/verify#error-code-reference</a></kbd>.
|
||||
<p><strong>Note:</strong> Error code <kbd>missing-input-response</kbd> may mean the user just didn't complete the reCAPTCHA.</p>
|
||||
<p><a href="/recaptcha-v2-checkbox.php">⤴️ Try again</a></p>
|
||||
<?php
|
||||
endif;
|
||||
else:
|
||||
// Add the g-recaptcha tag to the form you want to include the reCAPTCHA element
|
||||
?>
|
||||
<p>Complete the reCAPTCHA then submit the form.</p>
|
||||
<form action="/recaptcha-v2-checkbox.php" method="post">
|
||||
<fieldset>
|
||||
<legend>An example form</legend>
|
||||
<label class="form-field">Example input A: <input type="text" name="ex-a" value="foo"></label>
|
||||
<label class="form-field">Example input B: <input type="text" name="ex-b" value="bar"></label>
|
||||
<!-- Default behaviour looks for the g-recaptcha class with a data-sitekey attribute -->
|
||||
<div class="g-recaptcha form-field" data-sitekey="<?php echo $siteKey; ?>"></div>
|
||||
<!-- Submitting before the widget loads will result in a missing-input-response error so you need to verify server side -->
|
||||
<button class="form-field" type="submit">Submit ↦</button>
|
||||
</fieldset>
|
||||
</form>
|
||||
<script type="text/javascript" src="https://www.google.com/recaptcha/api.js?hl=<?php echo $lang; ?>"></script>
|
||||
<?php
|
||||
endif;?>
|
||||
</main>
|
||||
|
||||
<!-- Google Analytics - just ignore this -->
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-123057962-1"></script>
|
||||
<script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-123057962-1');</script>
|
@ -1,141 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
require __DIR__ . '/appengine-https.php';
|
||||
|
||||
// Initiate the autoloader. The file should be generated by Composer.
|
||||
// You will provide your own autoloader or require the files directly if you did
|
||||
// not install via Composer.
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// Register API keys at https://www.google.com/recaptcha/admin
|
||||
$siteKey = '';
|
||||
$secret = '';
|
||||
|
||||
// Copy the config.php.dist file to config.php and update it with your keys to run the examples
|
||||
if ($siteKey == '' && is_readable(__DIR__ . '/config.php')) {
|
||||
$config = include __DIR__ . '/config.php';
|
||||
$siteKey = $config['v2-invisible']['site'];
|
||||
$secret = $config['v2-invisible']['secret'];
|
||||
}
|
||||
|
||||
// reCAPTCHA supports 40+ languages listed here: https://developers.google.com/recaptcha/docs/language
|
||||
$lang = 'en';
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width,height=device-height,minimum-scale=1">
|
||||
<link rel="shortcut icon" href="https://www.gstatic.com/recaptcha/admin/favicon.ico" type="image/x-icon"/>
|
||||
<link rel="canonical" href="https://recaptcha-demo.appspot.com/recaptcha-v2-invisible.php">
|
||||
<script type="application/ld+json">{ "@context": "http://schema.org", "@type": "WebSite", "name": "reCAPTCHA demo - Invisible", "url": "https://recaptcha-demo.appspot.com/recaptcha-v2-invisible.php" }</script>
|
||||
<meta name="description" content="reCAPTCHA demo - Invisible" />
|
||||
<meta property="og:url" content="https://recaptcha-demo.appspot.com/recaptcha-v2-invisible.php" />
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="reCAPTCHA demo - Invisible" />
|
||||
<meta property="og:description" content="reCAPTCHA demo - Invisible" />
|
||||
<link rel="stylesheet" type="text/css" href="/examples.css">
|
||||
<title>reCAPTCHA demo - Invisible</title>
|
||||
|
||||
<header>
|
||||
<h1>reCAPTCHA demo</h1><h2>Invisible</h2>
|
||||
<p><a href="/">↩️ Home</a></p>
|
||||
</header>
|
||||
<main>
|
||||
<?php
|
||||
if ($siteKey === '' || $secret === ''):
|
||||
?>
|
||||
<h2>Add your keys</h2>
|
||||
<p>If you do not have keys already then visit <kbd> <a href = "https://www.google.com/recaptcha/admin">https://www.google.com/recaptcha/admin</a></kbd> to generate them. Edit this file and set the respective keys in <kbd>$siteKey</kbd> and <kbd>$secret</kbd>. Reload the page after this.</p>
|
||||
<?php
|
||||
elseif (isset($_POST['g-recaptcha-response'])):
|
||||
// The POST data here is unfiltered because this is an example.
|
||||
// In production, *always* sanitise and validate your input'
|
||||
?>
|
||||
<h2><kbd>POST</kbd> data</h2>
|
||||
<kbd><pre><?php var_export($_POST);?></pre></kbd>
|
||||
<?php
|
||||
// If the form submission includes the "g-captcha-response" field
|
||||
// Create an instance of the service using your secret
|
||||
$recaptcha = new \ReCaptcha\ReCaptcha($secret);
|
||||
|
||||
// If file_get_contents() is locked down on your PHP installation to disallow
|
||||
// its use with URLs, then you can use the alternative request method instead.
|
||||
// This makes use of fsockopen() instead.
|
||||
// $recaptcha = new \ReCaptcha\ReCaptcha($secret, new \ReCaptcha\RequestMethod\SocketPost());
|
||||
|
||||
// Make the call to verify the response and also pass the user's IP address
|
||||
$resp = $recaptcha->setExpectedHostname($_SERVER['SERVER_NAME'])
|
||||
->verify($_POST['g-recaptcha-response'], $_SERVER['REMOTE_ADDR']);
|
||||
if ($resp->isSuccess()):
|
||||
// If the response is a success, that's it!
|
||||
?>
|
||||
<h2>Success!</h2>
|
||||
<kbd><pre><?php var_export($resp);?></pre></kbd>
|
||||
<p>That's it. Everything is working. Go integrate this into your real project.</p>
|
||||
<p><a href="/recaptcha-v2-invisible.php">⤴️ Try again</a></p>
|
||||
<?php
|
||||
else:
|
||||
// If it's not successful, then one or more error codes will be returned.
|
||||
?>
|
||||
<h2>Something went wrong</h2>
|
||||
<kbd><pre><?php var_export($resp);?></pre></kbd>
|
||||
<p>Check the error code reference at <kbd><a href="https://developers.google.com/recaptcha/docs/verify#error-code-reference">https://developers.google.com/recaptcha/docs/verify#error-code-reference</a></kbd>.
|
||||
<p><strong>Note:</strong> Error code <kbd>missing-input-response</kbd> may mean the user just didn't complete the reCAPTCHA.</p>
|
||||
<p><a href="/recaptcha-v2-invisible.php">⤴️ Try again</a></p>
|
||||
<?php
|
||||
endif;
|
||||
else:
|
||||
// Add the g-recaptcha tag to the form you want to include the reCAPTCHA element
|
||||
?>
|
||||
<p>Submit the form and reCAPTCHA will run automatically.</p>
|
||||
<form action="/recaptcha-v2-invisible.php" method="post" id="demo-form">
|
||||
<fieldset>
|
||||
<legend>An example form</legend>
|
||||
<label class="form-field">Example input A: <input type="text" name="ex-a" value="foo"></label>
|
||||
<label class="form-field">Example input B: <input type="text" name="ex-b" value="bar"></label>
|
||||
<button class="g-recaptcha form-field" data-sitekey="<?php echo $siteKey; ?>" data-callback='onSubmit'>Submit ↦</button>
|
||||
</fieldset>
|
||||
</form>
|
||||
<script type="text/javascript" src="https://www.google.com/recaptcha/api.js?hl=<?php echo $lang; ?>" async defer></script>
|
||||
<script type="text/javascript">
|
||||
function onSubmit(token) {
|
||||
document.getElementById("demo-form").submit();
|
||||
}
|
||||
</script>
|
||||
<?php
|
||||
endif;?>
|
||||
</main>
|
||||
|
||||
<!-- Google Analytics - just ignore this -->
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-123057962-1"></script>
|
||||
<script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-123057962-1');</script>
|
@ -1,120 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
require __DIR__ . '/appengine-https.php';
|
||||
|
||||
// Initiate the autoloader. The file should be generated by Composer.
|
||||
// You will provide your own autoloader or require the files directly if you did
|
||||
// not install via Composer.
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// Register API keys at https://www.google.com/recaptcha/admin
|
||||
$siteKey = '';
|
||||
$secret = '';
|
||||
|
||||
// Copy the config.php.dist file to config.php and update it with your keys to run the examples
|
||||
if ($siteKey == '' && is_readable(__DIR__ . '/config.php')) {
|
||||
$config = include __DIR__ . '/config.php';
|
||||
$siteKey = $config['v3']['site'];
|
||||
$secret = $config['v3']['secret'];
|
||||
}
|
||||
|
||||
// reCAPTCHA supports 40+ languages listed here: https://developers.google.com/recaptcha/docs/language
|
||||
$lang = 'en';
|
||||
|
||||
// The v3 API lets you provide some context for the check by specifying an action.
|
||||
// See: https://developers.google.com/recaptcha/docs/v3
|
||||
$pageAction = 'examples/v3scores';
|
||||
|
||||
?>
|
||||
<!DOCTYPE html>
|
||||
<html lang="en">
|
||||
<meta charset="UTF-8">
|
||||
<meta name="viewport" content="width=device-width,height=device-height,minimum-scale=1">
|
||||
<link rel="shortcut icon" href="https://www.gstatic.com/recaptcha/admin/favicon.ico" type="image/x-icon"/>
|
||||
<link rel="canonical" href="https://recaptcha-demo.appspot.com/recaptcha-v3-request-scores.php">
|
||||
<script type="application/ld+json">{ "@context": "http://schema.org", "@type": "WebSite", "name": "reCAPTCHA demo - Request scores", "url": "https://recaptcha-demo.appspot.com/recaptcha-v3-request-scores.php" }</script>
|
||||
<meta name="description" content="reCAPTCHA demo - Request scores" />
|
||||
<meta property="og:url" content="https://recaptcha-demo.appspot.com/recaptcha-v3-request-scores.php" />
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:title" content="reCAPTCHA demo - Request scores" />
|
||||
<meta property="og:description" content="reCAPTCHA demo - Request scores" />
|
||||
<link rel="stylesheet" type="text/css" href="/examples.css">
|
||||
<title>reCAPTCHA demo - Request scores</title>
|
||||
<header>
|
||||
<h1>reCAPTCHA demo</h1><h2>Request scores</h2>
|
||||
<p><a href="/">↩️ Home</a></p>
|
||||
</header>
|
||||
<main>
|
||||
<?php
|
||||
if ($siteKey === '' || $secret === ''):
|
||||
?>
|
||||
<h2>Add your keys</h2>
|
||||
<p>If you do not have keys already then visit <kbd> <a href = "https://www.google.com/recaptcha/admin">https://www.google.com/recaptcha/admin</a></kbd> to generate them. Edit this file and set the respective keys in <kbd>$siteKey</kbd> and <kbd>$secret</kbd>. Reload the page after this.</p>
|
||||
<?php
|
||||
else:
|
||||
// Add the g-recaptcha tag to the form you want to include the reCAPTCHA element
|
||||
?>
|
||||
<p>The reCAPTCHA v3 API provides a confidence score for each request.</p>
|
||||
<p><strong>NOTE:</strong>This is a sample implementation, the score returned here is not a reflection on your Google account or type of traffic. In production, refer to the distribution of scores shown in <a href="https://www.google.com/recaptcha/admin" target="_blank">your admin interface</a> and adjust your own threshold accordingly. <strong>Do not raise issues regarding the score you see here.</strong></p>
|
||||
<ol id="recaptcha-steps">
|
||||
<li class="step0">reCAPTCHA script loading</li>
|
||||
<li class="step1 hidden"><kbd>grecaptcha.ready()</kbd> fired, calling <pre>grecaptcha.execute('<?php echo $siteKey; ?>', {action: '<?php echo $pageAction; ?>'})'</pre></li>
|
||||
<li class="step2 hidden">Received token from reCAPTCHA service, sending to our backend with:
|
||||
<pre class="token">fetch('/recaptcha-v3-verify.php?token=abc123</pre></li>
|
||||
<li class="step3 hidden">Received response from our backend: <pre class="response">{"json": "from-backend"}</pre></li>
|
||||
</ol>
|
||||
<p><a href="/recaptcha-v3-request-scores.php">⤴️ Try again</a></p>
|
||||
<script src="https://www.google.com/recaptcha/api.js?render=<?php echo $siteKey; ?>"></script>
|
||||
<script>
|
||||
const steps = document.getElementById('recaptcha-steps');
|
||||
grecaptcha.ready(function() {
|
||||
document.querySelector('.step1').classList.remove('hidden');
|
||||
grecaptcha.execute('<?php echo $siteKey; ?>', {action: '<?php echo $pageAction; ?>'}).then(function(token) {
|
||||
document.querySelector('.token').innerHTML = 'fetch(\'/recaptcha-v3-verify.php?action=<?php echo $pageAction; ?>&token=\'' + token;
|
||||
document.querySelector('.step2').classList.remove('hidden');
|
||||
|
||||
fetch('/recaptcha-v3-verify.php?action=<?php echo $pageAction; ?>&token='+token).then(function(response) {
|
||||
response.json().then(function(data) {
|
||||
document.querySelector('.response').innerHTML = JSON.stringify(data, null, 2);
|
||||
document.querySelector('.step3').classList.remove('hidden');
|
||||
});
|
||||
});
|
||||
});
|
||||
});
|
||||
</script>
|
||||
<?php
|
||||
endif;?>
|
||||
</main>
|
||||
<!-- Google Analytics - just ignore this -->
|
||||
<script async src="https://www.googletagmanager.com/gtag/js?id=UA-123057962-1"></script>
|
||||
<script>window.dataLayer = window.dataLayer || []; function gtag(){dataLayer.push(arguments);} gtag('js', new Date()); gtag('config', 'UA-123057962-1');</script>
|
@ -1,59 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
require __DIR__ . '/appengine-https.php';
|
||||
|
||||
// Initiate the autoloader. The file should be generated by Composer.
|
||||
// You will provide your own autoloader or require the files directly if you did
|
||||
// not install via Composer.
|
||||
require_once __DIR__ . '/../vendor/autoload.php';
|
||||
|
||||
// Register API keys at https://www.google.com/recaptcha/admin
|
||||
$siteKey = '';
|
||||
$secret = '';
|
||||
|
||||
// Copy the config.php.dist file to config.php and update it with your keys to run the examples
|
||||
if ($siteKey == '' && is_readable(__DIR__ . '/config.php')) {
|
||||
$config = include __DIR__ . '/config.php';
|
||||
$siteKey = $config['v3']['site'];
|
||||
$secret = $config['v3']['secret'];
|
||||
}
|
||||
|
||||
// Effectively we're providing an API endpoint here that will accept the token, verify it, and return the action / score to the page
|
||||
// In production, always sanitize and validate the input you retrieve from the request.
|
||||
$recaptcha = new \ReCaptcha\ReCaptcha($secret);
|
||||
$resp = $recaptcha->setExpectedHostname($_SERVER['SERVER_NAME'])
|
||||
->setExpectedAction($_GET['action'])
|
||||
->setScoreThreshold(0.5)
|
||||
->verify($_GET['token'], $_SERVER['REMOTE_ADDR']);
|
||||
header('Content-type:application/json');
|
||||
echo json_encode($resp->toArray());
|
2
vendor/google/recaptcha/examples/robots.txt
vendored
2
vendor/google/recaptcha/examples/robots.txt
vendored
@ -1,2 +0,0 @@
|
||||
User-agent: *
|
||||
Disallow:
|
20
vendor/google/recaptcha/phpunit.xml.dist
vendored
20
vendor/google/recaptcha/phpunit.xml.dist
vendored
@ -1,20 +0,0 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<phpunit xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
|
||||
xsi:noNamespaceSchemaLocation="http://schema.phpunit.de/4.4/phpunit.xsd"
|
||||
colors="true"
|
||||
verbose="true"
|
||||
bootstrap="src/autoload.php">
|
||||
<testsuites>
|
||||
<testsuite name="reCAPTCHA Test Suite">
|
||||
<directory>tests/ReCaptcha/</directory>
|
||||
</testsuite>
|
||||
</testsuites>
|
||||
<filter>
|
||||
<whitelist>
|
||||
<directory suffix=".php">src/ReCaptcha/</directory>
|
||||
</whitelist>
|
||||
</filter>
|
||||
<logging>
|
||||
<log type="coverage-clover" target="build/logs/clover.xml"/>
|
||||
</logging>
|
||||
</phpunit>
|
@ -43,73 +43,73 @@ class ReCaptcha
|
||||
* Version of this client library.
|
||||
* @const string
|
||||
*/
|
||||
const VERSION = 'php_1.2.3';
|
||||
public const VERSION = 'php_1.3.0';
|
||||
|
||||
/**
|
||||
* URL for reCAPTCHA siteverify API
|
||||
* @const string
|
||||
*/
|
||||
const SITE_VERIFY_URL = 'https://www.google.com/recaptcha/api/siteverify';
|
||||
public const SITE_VERIFY_URL = 'https://www.google.com/recaptcha/api/siteverify';
|
||||
|
||||
/**
|
||||
* Invalid JSON received
|
||||
* @const string
|
||||
*/
|
||||
const E_INVALID_JSON = 'invalid-json';
|
||||
public const E_INVALID_JSON = 'invalid-json';
|
||||
|
||||
/**
|
||||
* Could not connect to service
|
||||
* @const string
|
||||
*/
|
||||
const E_CONNECTION_FAILED = 'connection-failed';
|
||||
public const E_CONNECTION_FAILED = 'connection-failed';
|
||||
|
||||
/**
|
||||
* Did not receive a 200 from the service
|
||||
* @const string
|
||||
*/
|
||||
const E_BAD_RESPONSE = 'bad-response';
|
||||
public const E_BAD_RESPONSE = 'bad-response';
|
||||
|
||||
/**
|
||||
* Not a success, but no error codes received!
|
||||
* @const string
|
||||
*/
|
||||
const E_UNKNOWN_ERROR = 'unknown-error';
|
||||
public const E_UNKNOWN_ERROR = 'unknown-error';
|
||||
|
||||
/**
|
||||
* ReCAPTCHA response not provided
|
||||
* @const string
|
||||
*/
|
||||
const E_MISSING_INPUT_RESPONSE = 'missing-input-response';
|
||||
public const E_MISSING_INPUT_RESPONSE = 'missing-input-response';
|
||||
|
||||
/**
|
||||
* Expected hostname did not match
|
||||
* @const string
|
||||
*/
|
||||
const E_HOSTNAME_MISMATCH = 'hostname-mismatch';
|
||||
public const E_HOSTNAME_MISMATCH = 'hostname-mismatch';
|
||||
|
||||
/**
|
||||
* Expected APK package name did not match
|
||||
* @const string
|
||||
*/
|
||||
const E_APK_PACKAGE_NAME_MISMATCH = 'apk_package_name-mismatch';
|
||||
public const E_APK_PACKAGE_NAME_MISMATCH = 'apk_package_name-mismatch';
|
||||
|
||||
/**
|
||||
* Expected action did not match
|
||||
* @const string
|
||||
*/
|
||||
const E_ACTION_MISMATCH = 'action-mismatch';
|
||||
public const E_ACTION_MISMATCH = 'action-mismatch';
|
||||
|
||||
/**
|
||||
* Score threshold not met
|
||||
* @const string
|
||||
*/
|
||||
const E_SCORE_THRESHOLD_NOT_MET = 'score-threshold-not-met';
|
||||
public const E_SCORE_THRESHOLD_NOT_MET = 'score-threshold-not-met';
|
||||
|
||||
/**
|
||||
* Challenge timeout
|
||||
* @const string
|
||||
*/
|
||||
const E_CHALLENGE_TIMEOUT = 'challenge-timeout';
|
||||
public const E_CHALLENGE_TIMEOUT = 'challenge-timeout';
|
||||
|
||||
/**
|
||||
* Shared secret for the site.
|
||||
@ -123,6 +123,12 @@ class ReCaptcha
|
||||
*/
|
||||
private $requestMethod;
|
||||
|
||||
private $hostname;
|
||||
private $apkPackageName;
|
||||
private $action;
|
||||
private $threshold;
|
||||
private $timeoutSeconds;
|
||||
|
||||
/**
|
||||
* Create a configured instance to use the reCAPTCHA service.
|
||||
*
|
||||
|
@ -39,7 +39,6 @@ namespace ReCaptcha;
|
||||
*/
|
||||
interface RequestMethod
|
||||
{
|
||||
|
||||
/**
|
||||
* Submit the request with the specified parameters.
|
||||
*
|
||||
|
@ -39,7 +39,6 @@ namespace ReCaptcha\RequestMethod;
|
||||
*/
|
||||
class Curl
|
||||
{
|
||||
|
||||
/**
|
||||
* @see http://php.net/curl_init
|
||||
* @param string $url
|
||||
|
@ -51,6 +51,8 @@ class SocketPost implements RequestMethod
|
||||
*/
|
||||
private $socket;
|
||||
|
||||
private $siteVerifyUrl;
|
||||
|
||||
/**
|
||||
* Only needed if you want to override the defaults
|
||||
*
|
||||
@ -81,7 +83,7 @@ class SocketPost implements RequestMethod
|
||||
|
||||
$content = $params->toQueryString();
|
||||
|
||||
$request = "POST " . $urlParsed['path'] . " HTTP/1.1\r\n";
|
||||
$request = "POST " . $urlParsed['path'] . " HTTP/1.0\r\n";
|
||||
$request .= "Host: " . $urlParsed['host'] . "\r\n";
|
||||
$request .= "Content-Type: application/x-www-form-urlencoded\r\n";
|
||||
$request .= "Content-length: " . strlen($content) . "\r\n";
|
||||
@ -97,7 +99,7 @@ class SocketPost implements RequestMethod
|
||||
|
||||
$this->socket->fclose();
|
||||
|
||||
if (0 !== strpos($response, 'HTTP/1.1 200 OK')) {
|
||||
if (0 !== strpos($response, 'HTTP/1.0 200 OK')) {
|
||||
return '{"success": false, "error-codes": ["'.ReCaptcha::E_BAD_RESPONSE.'"]}';
|
||||
}
|
||||
|
||||
|
@ -95,11 +95,11 @@ class Response
|
||||
return new Response(false, array(ReCaptcha::E_INVALID_JSON));
|
||||
}
|
||||
|
||||
$hostname = isset($responseData['hostname']) ? $responseData['hostname'] : null;
|
||||
$challengeTs = isset($responseData['challenge_ts']) ? $responseData['challenge_ts'] : null;
|
||||
$apkPackageName = isset($responseData['apk_package_name']) ? $responseData['apk_package_name'] : null;
|
||||
$hostname = isset($responseData['hostname']) ? $responseData['hostname'] : '';
|
||||
$challengeTs = isset($responseData['challenge_ts']) ? $responseData['challenge_ts'] : '';
|
||||
$apkPackageName = isset($responseData['apk_package_name']) ? $responseData['apk_package_name'] : '';
|
||||
$score = isset($responseData['score']) ? floatval($responseData['score']) : null;
|
||||
$action = isset($responseData['action']) ? $responseData['action'] : null;
|
||||
$action = isset($responseData['action']) ? $responseData['action'] : '';
|
||||
|
||||
if (isset($responseData['success']) && $responseData['success'] == true) {
|
||||
return new Response(true, array(), $hostname, $challengeTs, $apkPackageName, $score, $action);
|
||||
@ -123,7 +123,7 @@ class Response
|
||||
* @param string $action
|
||||
* @param array $errorCodes
|
||||
*/
|
||||
public function __construct($success, array $errorCodes = array(), $hostname = null, $challengeTs = null, $apkPackageName = null, $score = null, $action = null)
|
||||
public function __construct($success, array $errorCodes = array(), $hostname = '', $challengeTs = '', $apkPackageName = '', $score = null, $action = '')
|
||||
{
|
||||
$this->success = $success;
|
||||
$this->hostname = $hostname;
|
||||
|
@ -1,198 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* This is a PHP library that handles calling reCAPTCHA.
|
||||
*
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
namespace ReCaptcha;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class ReCaptchaTest extends TestCase
|
||||
{
|
||||
|
||||
/**
|
||||
* @expectedException \RuntimeException
|
||||
* @dataProvider invalidSecretProvider
|
||||
*/
|
||||
public function testExceptionThrownOnInvalidSecret($invalid)
|
||||
{
|
||||
$rc = new ReCaptcha($invalid);
|
||||
}
|
||||
|
||||
public function invalidSecretProvider()
|
||||
{
|
||||
return array(
|
||||
array(''),
|
||||
array(null),
|
||||
array(0),
|
||||
array(new \stdClass()),
|
||||
array(array()),
|
||||
);
|
||||
}
|
||||
|
||||
public function testVerifyReturnsErrorOnMissingResponse()
|
||||
{
|
||||
$rc = new ReCaptcha('secret');
|
||||
$response = $rc->verify('');
|
||||
$this->assertFalse($response->isSuccess());
|
||||
$this->assertEquals(array(Recaptcha::E_MISSING_INPUT_RESPONSE), $response->getErrorCodes());
|
||||
}
|
||||
|
||||
private function getMockRequestMethod($responseJson)
|
||||
{
|
||||
$method = $this->getMockBuilder(\ReCaptcha\RequestMethod::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('submit'))
|
||||
->getMock();
|
||||
$method->expects($this->any())
|
||||
->method('submit')
|
||||
->with($this->callback(function ($params) {
|
||||
return true;
|
||||
}))
|
||||
->will($this->returnValue($responseJson));
|
||||
return $method;
|
||||
}
|
||||
|
||||
public function testVerifyReturnsResponse()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->verify('response');
|
||||
$this->assertTrue($response->isSuccess());
|
||||
}
|
||||
|
||||
public function testVerifyReturnsInitialResponseWithoutAdditionalChecks()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$initialResponse = $rc->verify('response');
|
||||
$this->assertEquals($initialResponse, $rc->verify('response'));
|
||||
}
|
||||
|
||||
public function testVerifyHostnameMatch()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "hostname": "host.name"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setExpectedHostname('host.name')->verify('response');
|
||||
$this->assertTrue($response->isSuccess());
|
||||
}
|
||||
|
||||
public function testVerifyHostnameMisMatch()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "hostname": "host.NOTname"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setExpectedHostname('host.name')->verify('response');
|
||||
$this->assertFalse($response->isSuccess());
|
||||
$this->assertEquals(array(ReCaptcha::E_HOSTNAME_MISMATCH), $response->getErrorCodes());
|
||||
}
|
||||
|
||||
public function testVerifyApkPackageNameMatch()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "apk_package_name": "apk.name"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setExpectedApkPackageName('apk.name')->verify('response');
|
||||
$this->assertTrue($response->isSuccess());
|
||||
}
|
||||
|
||||
public function testVerifyApkPackageNameMisMatch()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "apk_package_name": "apk.NOTname"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setExpectedApkPackageName('apk.name')->verify('response');
|
||||
$this->assertFalse($response->isSuccess());
|
||||
$this->assertEquals(array(ReCaptcha::E_APK_PACKAGE_NAME_MISMATCH), $response->getErrorCodes());
|
||||
}
|
||||
|
||||
public function testVerifyActionMatch()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "action": "action/name"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setExpectedAction('action/name')->verify('response');
|
||||
$this->assertTrue($response->isSuccess());
|
||||
}
|
||||
|
||||
public function testVerifyActionMisMatch()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "action": "action/NOTname"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setExpectedAction('action/name')->verify('response');
|
||||
$this->assertFalse($response->isSuccess());
|
||||
$this->assertEquals(array(ReCaptcha::E_ACTION_MISMATCH), $response->getErrorCodes());
|
||||
}
|
||||
|
||||
public function testVerifyAboveThreshold()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "score": "0.9"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setScoreThreshold('0.5')->verify('response');
|
||||
$this->assertTrue($response->isSuccess());
|
||||
}
|
||||
|
||||
public function testVerifyBelowThreshold()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": true, "score": "0.1"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setScoreThreshold('0.5')->verify('response');
|
||||
$this->assertFalse($response->isSuccess());
|
||||
$this->assertEquals(array(ReCaptcha::E_SCORE_THRESHOLD_NOT_MET), $response->getErrorCodes());
|
||||
}
|
||||
|
||||
public function testVerifyWithinTimeout()
|
||||
{
|
||||
// Responses come back like 2018-07-31T13:48:41Z
|
||||
$challengeTs = date('Y-M-d\TH:i:s\Z', time());
|
||||
$method = $this->getMockRequestMethod('{"success": true, "challenge_ts": "'.$challengeTs.'"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setChallengeTimeout('1000')->verify('response');
|
||||
$this->assertTrue($response->isSuccess());
|
||||
}
|
||||
|
||||
public function testVerifyOverTimeout()
|
||||
{
|
||||
// Responses come back like 2018-07-31T13:48:41Z
|
||||
$challengeTs = date('Y-M-d\TH:i:s\Z', time() - 600);
|
||||
$method = $this->getMockRequestMethod('{"success": true, "challenge_ts": "'.$challengeTs.'"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setChallengeTimeout('60')->verify('response');
|
||||
$this->assertFalse($response->isSuccess());
|
||||
$this->assertEquals(array(ReCaptcha::E_CHALLENGE_TIMEOUT), $response->getErrorCodes());
|
||||
}
|
||||
|
||||
public function testVerifyMergesErrors()
|
||||
{
|
||||
$method = $this->getMockRequestMethod('{"success": false, "error-codes": ["initial-error"], "score": "0.1"}');
|
||||
$rc = new ReCaptcha('secret', $method);
|
||||
$response = $rc->setScoreThreshold('0.5')->verify('response');
|
||||
$this->assertFalse($response->isSuccess());
|
||||
$this->assertEquals(array('initial-error', ReCaptcha::E_SCORE_THRESHOLD_NOT_MET), $response->getErrorCodes());
|
||||
}
|
||||
}
|
@ -1,123 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* This is a PHP library that handles calling reCAPTCHA.
|
||||
*
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
namespace ReCaptcha\RequestMethod;
|
||||
|
||||
use \ReCaptcha\ReCaptcha;
|
||||
use \ReCaptcha\RequestParameters;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class CurlPostTest extends TestCase
|
||||
{
|
||||
protected function setUp()
|
||||
{
|
||||
if (!extension_loaded('curl')) {
|
||||
$this->markTestSkipped(
|
||||
'The cURL extension is not available.'
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
public function testSubmit()
|
||||
{
|
||||
$curl = $this->getMockBuilder(\ReCaptcha\RequestMethod\Curl::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('init', 'setoptArray', 'exec', 'close'))
|
||||
->getMock();
|
||||
$curl->expects($this->once())
|
||||
->method('init')
|
||||
->willReturn(new \stdClass);
|
||||
$curl->expects($this->once())
|
||||
->method('setoptArray')
|
||||
->willReturn(true);
|
||||
$curl->expects($this->once())
|
||||
->method('exec')
|
||||
->willReturn('RESPONSEBODY');
|
||||
$curl->expects($this->once())
|
||||
->method('close');
|
||||
|
||||
$pc = new CurlPost($curl);
|
||||
$response = $pc->submit(new RequestParameters("secret", "response"));
|
||||
$this->assertEquals('RESPONSEBODY', $response);
|
||||
}
|
||||
|
||||
public function testOverrideSiteVerifyUrl()
|
||||
{
|
||||
$url = 'OVERRIDE';
|
||||
|
||||
$curl = $this->getMockBuilder(\ReCaptcha\RequestMethod\Curl::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('init', 'setoptArray', 'exec', 'close'))
|
||||
->getMock();
|
||||
$curl->expects($this->once())
|
||||
->method('init')
|
||||
->with($url)
|
||||
->willReturn(new \stdClass);
|
||||
$curl->expects($this->once())
|
||||
->method('setoptArray')
|
||||
->willReturn(true);
|
||||
$curl->expects($this->once())
|
||||
->method('exec')
|
||||
->willReturn('RESPONSEBODY');
|
||||
$curl->expects($this->once())
|
||||
->method('close');
|
||||
|
||||
$pc = new CurlPost($curl, $url);
|
||||
$response = $pc->submit(new RequestParameters("secret", "response"));
|
||||
$this->assertEquals('RESPONSEBODY', $response);
|
||||
}
|
||||
|
||||
public function testConnectionFailureReturnsError()
|
||||
{
|
||||
$curl = $this->getMockBuilder(\ReCaptcha\RequestMethod\Curl::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('init', 'setoptArray', 'exec', 'close'))
|
||||
->getMock();
|
||||
$curl->expects($this->once())
|
||||
->method('init')
|
||||
->willReturn(new \stdClass);
|
||||
$curl->expects($this->once())
|
||||
->method('setoptArray')
|
||||
->willReturn(true);
|
||||
$curl->expects($this->once())
|
||||
->method('exec')
|
||||
->willReturn(false);
|
||||
$curl->expects($this->once())
|
||||
->method('close');
|
||||
|
||||
$pc = new CurlPost($curl);
|
||||
$response = $pc->submit(new RequestParameters("secret", "response"));
|
||||
$this->assertEquals('{"success": false, "error-codes": ["'.ReCaptcha::E_CONNECTION_FAILED.'"]}', $response);
|
||||
}
|
||||
}
|
@ -1,149 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* This is a PHP library that handles calling reCAPTCHA.
|
||||
*
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
namespace ReCaptcha\RequestMethod;
|
||||
|
||||
use \ReCaptcha\ReCaptcha;
|
||||
use ReCaptcha\RequestParameters;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class PostTest extends TestCase
|
||||
{
|
||||
public static $assert = null;
|
||||
protected $parameters = null;
|
||||
protected $runcount = 0;
|
||||
|
||||
public function setUp()
|
||||
{
|
||||
$this->parameters = new RequestParameters('secret', 'response', 'remoteip', 'version');
|
||||
}
|
||||
|
||||
public function tearDown()
|
||||
{
|
||||
self::$assert = null;
|
||||
}
|
||||
|
||||
public function testHTTPContextOptions()
|
||||
{
|
||||
$req = new Post();
|
||||
self::$assert = array($this, 'httpContextOptionsCallback');
|
||||
$req->submit($this->parameters);
|
||||
$this->assertEquals(1, $this->runcount, 'The assertion was ran');
|
||||
}
|
||||
|
||||
public function testSSLContextOptions()
|
||||
{
|
||||
$req = new Post();
|
||||
self::$assert = array($this, 'sslContextOptionsCallback');
|
||||
$req->submit($this->parameters);
|
||||
$this->assertEquals(1, $this->runcount, 'The assertion was ran');
|
||||
}
|
||||
|
||||
public function testOverrideVerifyUrl()
|
||||
{
|
||||
$req = new Post('https://over.ride/some/path');
|
||||
self::$assert = array($this, 'overrideUrlOptions');
|
||||
$req->submit($this->parameters);
|
||||
$this->assertEquals(1, $this->runcount, 'The assertion was ran');
|
||||
}
|
||||
|
||||
public function testConnectionFailureReturnsError()
|
||||
{
|
||||
$req = new Post('https://bad.connection/');
|
||||
self::$assert = array($this, 'connectionFailureResponse');
|
||||
$response = $req->submit($this->parameters);
|
||||
$this->assertEquals('{"success": false, "error-codes": ["'.ReCaptcha::E_CONNECTION_FAILED.'"]}', $response);
|
||||
}
|
||||
|
||||
public function connectionFailureResponse()
|
||||
{
|
||||
return false;
|
||||
}
|
||||
public function overrideUrlOptions(array $args)
|
||||
{
|
||||
$this->runcount++;
|
||||
$this->assertEquals('https://over.ride/some/path', $args[0]);
|
||||
}
|
||||
|
||||
public function httpContextOptionsCallback(array $args)
|
||||
{
|
||||
$this->runcount++;
|
||||
$this->assertCommonOptions($args);
|
||||
|
||||
$options = stream_context_get_options($args[2]);
|
||||
$this->assertArrayHasKey('http', $options);
|
||||
|
||||
$this->assertArrayHasKey('method', $options['http']);
|
||||
$this->assertEquals('POST', $options['http']['method']);
|
||||
|
||||
$this->assertArrayHasKey('content', $options['http']);
|
||||
$this->assertEquals($this->parameters->toQueryString(), $options['http']['content']);
|
||||
|
||||
$this->assertArrayHasKey('header', $options['http']);
|
||||
$headers = array(
|
||||
'Content-type: application/x-www-form-urlencoded',
|
||||
);
|
||||
foreach ($headers as $header) {
|
||||
$this->assertContains($header, $options['http']['header']);
|
||||
}
|
||||
}
|
||||
|
||||
public function sslContextOptionsCallback(array $args)
|
||||
{
|
||||
$this->runcount++;
|
||||
$this->assertCommonOptions($args);
|
||||
|
||||
$options = stream_context_get_options($args[2]);
|
||||
$this->assertArrayHasKey('http', $options);
|
||||
$this->assertArrayHasKey('verify_peer', $options['http']);
|
||||
$this->assertTrue($options['http']['verify_peer']);
|
||||
}
|
||||
|
||||
protected function assertCommonOptions(array $args)
|
||||
{
|
||||
$this->assertCount(3, $args);
|
||||
$this->assertStringStartsWith('https://www.google.com/', $args[0]);
|
||||
$this->assertFalse($args[1]);
|
||||
$this->assertTrue(is_resource($args[2]), 'The context options should be a resource');
|
||||
}
|
||||
}
|
||||
|
||||
function file_get_contents()
|
||||
{
|
||||
if (PostTest::$assert) {
|
||||
return call_user_func(PostTest::$assert, func_get_args());
|
||||
}
|
||||
// Since we can't represent maxlen in userland...
|
||||
return call_user_func_array('file_get_contents', func_get_args());
|
||||
}
|
@ -1,136 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* This is a PHP library that handles calling reCAPTCHA.
|
||||
*
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
namespace ReCaptcha\RequestMethod;
|
||||
|
||||
use ReCaptcha\ReCaptcha;
|
||||
use ReCaptcha\RequestParameters;
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class SocketPostTest extends TestCase
|
||||
{
|
||||
public function testSubmitSuccess()
|
||||
{
|
||||
$socket = $this->getMockBuilder(\ReCaptcha\RequestMethod\Socket::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('fsockopen', 'fwrite', 'fgets', 'feof', 'fclose'))
|
||||
->getMock();
|
||||
$socket->expects($this->once())
|
||||
->method('fsockopen')
|
||||
->willReturn(true);
|
||||
$socket->expects($this->once())
|
||||
->method('fwrite');
|
||||
$socket->expects($this->once())
|
||||
->method('fgets')
|
||||
->willReturn("HTTP/1.1 200 OK\n\nRESPONSEBODY");
|
||||
$socket->expects($this->exactly(2))
|
||||
->method('feof')
|
||||
->will($this->onConsecutiveCalls(false, true));
|
||||
$socket->expects($this->once())
|
||||
->method('fclose')
|
||||
->willReturn(true);
|
||||
|
||||
$ps = new SocketPost($socket);
|
||||
$response = $ps->submit(new RequestParameters("secret", "response", "remoteip", "version"));
|
||||
$this->assertEquals('RESPONSEBODY', $response);
|
||||
}
|
||||
|
||||
public function testOverrideSiteVerifyUrl()
|
||||
{
|
||||
$socket = $this->getMockBuilder(\ReCaptcha\RequestMethod\Socket::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('fsockopen', 'fwrite', 'fgets', 'feof', 'fclose'))
|
||||
->getMock();
|
||||
$socket->expects($this->once())
|
||||
->method('fsockopen')
|
||||
->with('ssl://over.ride', 443, 0, '', 30)
|
||||
->willReturn(true);
|
||||
$socket->expects($this->once())
|
||||
->method('fwrite')
|
||||
->with($this->matchesRegularExpression('/^POST \/some\/path.*Host: over\.ride/s'));
|
||||
$socket->expects($this->once())
|
||||
->method('fgets')
|
||||
->willReturn("HTTP/1.1 200 OK\n\nRESPONSEBODY");
|
||||
$socket->expects($this->exactly(2))
|
||||
->method('feof')
|
||||
->will($this->onConsecutiveCalls(false, true));
|
||||
$socket->expects($this->once())
|
||||
->method('fclose')
|
||||
->willReturn(true);
|
||||
|
||||
$ps = new SocketPost($socket, 'https://over.ride/some/path');
|
||||
$response = $ps->submit(new RequestParameters("secret", "response", "remoteip", "version"));
|
||||
$this->assertEquals('RESPONSEBODY', $response);
|
||||
}
|
||||
|
||||
public function testSubmitBadResponse()
|
||||
{
|
||||
$socket = $this->getMockBuilder(\ReCaptcha\RequestMethod\Socket::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('fsockopen', 'fwrite', 'fgets', 'feof', 'fclose'))
|
||||
->getMock();
|
||||
$socket->expects($this->once())
|
||||
->method('fsockopen')
|
||||
->willReturn(true);
|
||||
$socket->expects($this->once())
|
||||
->method('fwrite');
|
||||
$socket->expects($this->once())
|
||||
->method('fgets')
|
||||
->willReturn("HTTP/1.1 500 NOPEn\\nBOBBINS");
|
||||
$socket->expects($this->exactly(2))
|
||||
->method('feof')
|
||||
->will($this->onConsecutiveCalls(false, true));
|
||||
$socket->expects($this->once())
|
||||
->method('fclose')
|
||||
->willReturn(true);
|
||||
|
||||
$ps = new SocketPost($socket);
|
||||
$response = $ps->submit(new RequestParameters("secret", "response", "remoteip", "version"));
|
||||
$this->assertEquals('{"success": false, "error-codes": ["'.ReCaptcha::E_BAD_RESPONSE.'"]}', $response);
|
||||
}
|
||||
|
||||
public function testConnectionFailureReturnsError()
|
||||
{
|
||||
$socket = $this->getMockBuilder(\ReCaptcha\RequestMethod\Socket::class)
|
||||
->disableOriginalConstructor()
|
||||
->setMethods(array('fsockopen'))
|
||||
->getMock();
|
||||
$socket->expects($this->once())
|
||||
->method('fsockopen')
|
||||
->willReturn(false);
|
||||
$ps = new SocketPost($socket);
|
||||
$response = $ps->submit(new RequestParameters("secret", "response", "remoteip", "version"));
|
||||
$this->assertEquals('{"success": false, "error-codes": ["'.ReCaptcha::E_CONNECTION_FAILED.'"]}', $response);
|
||||
}
|
||||
}
|
@ -1,70 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* This is a PHP library that handles calling reCAPTCHA.
|
||||
*
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
namespace ReCaptcha;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class RequestParametersTest extends Testcase
|
||||
{
|
||||
public function provideValidData()
|
||||
{
|
||||
return array(
|
||||
array('SECRET', 'RESPONSE', 'REMOTEIP', 'VERSION',
|
||||
array('secret' => 'SECRET', 'response' => 'RESPONSE', 'remoteip' => 'REMOTEIP', 'version' => 'VERSION'),
|
||||
'secret=SECRET&response=RESPONSE&remoteip=REMOTEIP&version=VERSION'),
|
||||
array('SECRET', 'RESPONSE', null, null,
|
||||
array('secret' => 'SECRET', 'response' => 'RESPONSE'),
|
||||
'secret=SECRET&response=RESPONSE'),
|
||||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* @dataProvider provideValidData
|
||||
*/
|
||||
public function testToArray($secret, $response, $remoteIp, $version, $expectedArray, $expectedQuery)
|
||||
{
|
||||
$params = new RequestParameters($secret, $response, $remoteIp, $version);
|
||||
$this->assertEquals($params->toArray(), $expectedArray);
|
||||
}
|
||||
|
||||
/**
|
||||
* @dataProvider provideValidData
|
||||
*/
|
||||
public function testToQueryString($secret, $response, $remoteIp, $version, $expectedArray, $expectedQuery)
|
||||
{
|
||||
$params = new RequestParameters($secret, $response, $remoteIp, $version);
|
||||
$this->assertEquals($params->toQueryString(), $expectedQuery);
|
||||
}
|
||||
}
|
@ -1,173 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* This is a PHP library that handles calling reCAPTCHA.
|
||||
*
|
||||
* BSD 3-Clause License
|
||||
* @copyright (c) 2019, Google Inc.
|
||||
* @link https://www.google.com/recaptcha
|
||||
* All rights reserved.
|
||||
*
|
||||
* Redistribution and use in source and binary forms, with or without
|
||||
* modification, are permitted provided that the following conditions are met:
|
||||
* 1. Redistributions of source code must retain the above copyright notice, this
|
||||
* list of conditions and the following disclaimer.
|
||||
*
|
||||
* 2. Redistributions in binary form must reproduce the above copyright notice,
|
||||
* this list of conditions and the following disclaimer in the documentation
|
||||
* and/or other materials provided with the distribution.
|
||||
*
|
||||
* 3. Neither the name of the copyright holder nor the names of its
|
||||
* contributors may be used to endorse or promote products derived from
|
||||
* this software without specific prior written permission.
|
||||
*
|
||||
* THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
||||
* AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
||||
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
|
||||
* DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT HOLDER OR CONTRIBUTORS BE LIABLE
|
||||
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
|
||||
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
|
||||
* SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER
|
||||
* CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY,
|
||||
* OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
|
||||
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
|
||||
*/
|
||||
|
||||
namespace ReCaptcha;
|
||||
|
||||
use PHPUnit\Framework\TestCase;
|
||||
|
||||
class ResponseTest extends TestCase
|
||||
{
|
||||
|
||||
/**
|
||||
* @dataProvider provideJson
|
||||
*/
|
||||
public function testFromJson($json, $success, $errorCodes, $hostname, $challengeTs, $apkPackageName, $score, $action)
|
||||
{
|
||||
$response = Response::fromJson($json);
|
||||
$this->assertEquals($success, $response->isSuccess());
|
||||
$this->assertEquals($errorCodes, $response->getErrorCodes());
|
||||
$this->assertEquals($hostname, $response->getHostname());
|
||||
$this->assertEquals($challengeTs, $response->getChallengeTs());
|
||||
$this->assertEquals($apkPackageName, $response->getApkPackageName());
|
||||
$this->assertEquals($score, $response->getScore());
|
||||
$this->assertEquals($action, $response->getAction());
|
||||
}
|
||||
|
||||
public function provideJson()
|
||||
{
|
||||
return array(
|
||||
array(
|
||||
'{"success": true}',
|
||||
true, array(), null, null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'{"success": true, "hostname": "google.com"}',
|
||||
true, array(), 'google.com', null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'{"success": false, "error-codes": ["test"]}',
|
||||
false, array('test'), null, null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'{"success": false, "error-codes": ["test"], "hostname": "google.com"}',
|
||||
false, array('test'), 'google.com', null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'{"success": false, "error-codes": ["test"], "hostname": "google.com", "challenge_ts": "timestamp", "apk_package_name": "apk", "score": "0.5", "action": "action"}',
|
||||
false, array('test'), 'google.com', 'timestamp', 'apk', 0.5, 'action',
|
||||
),
|
||||
array(
|
||||
'{"success": true, "error-codes": ["test"]}',
|
||||
true, array(), null, null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'{"success": true, "error-codes": ["test"], "hostname": "google.com"}',
|
||||
true, array(), 'google.com', null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'{"success": false}',
|
||||
false, array(ReCaptcha::E_UNKNOWN_ERROR), null, null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'{"success": false, "hostname": "google.com"}',
|
||||
false, array(ReCaptcha::E_UNKNOWN_ERROR), 'google.com', null, null, null, null,
|
||||
),
|
||||
array(
|
||||
'BAD JSON',
|
||||
false, array(ReCaptcha::E_INVALID_JSON), null, null, null, null, null,
|
||||
),
|
||||
);
|
||||
}
|
||||
|
||||
public function testIsSuccess()
|
||||
{
|
||||
$response = new Response(true);
|
||||
$this->assertTrue($response->isSuccess());
|
||||
|
||||
$response = new Response(false);
|
||||
$this->assertFalse($response->isSuccess());
|
||||
|
||||
$response = new Response(true, array(), 'example.com');
|
||||
$this->assertEquals('example.com', $response->getHostName());
|
||||
}
|
||||
|
||||
public function testGetErrorCodes()
|
||||
{
|
||||
$errorCodes = array('test');
|
||||
$response = new Response(true, $errorCodes);
|
||||
$this->assertEquals($errorCodes, $response->getErrorCodes());
|
||||
}
|
||||
|
||||
public function testGetHostname()
|
||||
{
|
||||
$hostname = 'google.com';
|
||||
$errorCodes = array();
|
||||
$response = new Response(true, $errorCodes, $hostname);
|
||||
$this->assertEquals($hostname, $response->getHostname());
|
||||
}
|
||||
|
||||
public function testGetChallengeTs()
|
||||
{
|
||||
$timestamp = 'timestamp';
|
||||
$errorCodes = array();
|
||||
$response = new Response(true, array(), 'hostname', $timestamp);
|
||||
$this->assertEquals($timestamp, $response->getChallengeTs());
|
||||
}
|
||||
|
||||
public function TestGetApkPackageName()
|
||||
{
|
||||
$apk = 'apk';
|
||||
$response = new Response(true, array(), 'hostname', 'timestamp', 'apk');
|
||||
$this->assertEquals($apk, $response->getApkPackageName());
|
||||
}
|
||||
|
||||
public function testGetScore()
|
||||
{
|
||||
$score = 0.5;
|
||||
$response = new Response(true, array(), 'hostname', 'timestamp', 'apk', $score);
|
||||
$this->assertEquals($score, $response->getScore());
|
||||
}
|
||||
|
||||
public function testGetAction()
|
||||
{
|
||||
$action = 'homepage';
|
||||
$response = new Response(true, array(), 'hostname', 'timestamp', 'apk', '0.5', 'homepage');
|
||||
$this->assertEquals($action, $response->getAction());
|
||||
}
|
||||
|
||||
public function testToArray()
|
||||
{
|
||||
$response = new Response(true, array(), 'hostname', 'timestamp', 'apk', '0.5', 'homepage');
|
||||
$expected = array(
|
||||
'success' => true,
|
||||
'error-codes' => array(),
|
||||
'hostname' => 'hostname',
|
||||
'challenge_ts' => 'timestamp',
|
||||
'apk_package_name' => 'apk',
|
||||
'score' => 0.5,
|
||||
'action' => 'homepage',
|
||||
);
|
||||
$this->assertEquals($expected, $response->toArray());
|
||||
}
|
||||
}
|
674
vendor/kanellov/slim-twig-flash/LICENSE
vendored
674
vendor/kanellov/slim-twig-flash/LICENSE
vendored
@ -1,674 +0,0 @@
|
||||
GNU GENERAL PUBLIC LICENSE
|
||||
Version 3, 29 June 2007
|
||||
|
||||
Copyright (C) 2007 Free Software Foundation, Inc. <http://fsf.org/>
|
||||
Everyone is permitted to copy and distribute verbatim copies
|
||||
of this license document, but changing it is not allowed.
|
||||
|
||||
Preamble
|
||||
|
||||
The GNU General Public License is a free, copyleft license for
|
||||
software and other kinds of works.
|
||||
|
||||
The licenses for most software and other practical works are designed
|
||||
to take away your freedom to share and change the works. By contrast,
|
||||
the GNU General Public License is intended to guarantee your freedom to
|
||||
share and change all versions of a program--to make sure it remains free
|
||||
software for all its users. We, the Free Software Foundation, use the
|
||||
GNU General Public License for most of our software; it applies also to
|
||||
any other work released this way by its authors. You can apply it to
|
||||
your programs, too.
|
||||
|
||||
When we speak of free software, we are referring to freedom, not
|
||||
price. Our General Public Licenses are designed to make sure that you
|
||||
have the freedom to distribute copies of free software (and charge for
|
||||
them if you wish), that you receive source code or can get it if you
|
||||
want it, that you can change the software or use pieces of it in new
|
||||
free programs, and that you know you can do these things.
|
||||
|
||||
To protect your rights, we need to prevent others from denying you
|
||||
these rights or asking you to surrender the rights. Therefore, you have
|
||||
certain responsibilities if you distribute copies of the software, or if
|
||||
you modify it: responsibilities to respect the freedom of others.
|
||||
|
||||
For example, if you distribute copies of such a program, whether
|
||||
gratis or for a fee, you must pass on to the recipients the same
|
||||
freedoms that you received. You must make sure that they, too, receive
|
||||
or can get the source code. And you must show them these terms so they
|
||||
know their rights.
|
||||
|
||||
Developers that use the GNU GPL protect your rights with two steps:
|
||||
(1) assert copyright on the software, and (2) offer you this License
|
||||
giving you legal permission to copy, distribute and/or modify it.
|
||||
|
||||
For the developers' and authors' protection, the GPL clearly explains
|
||||
that there is no warranty for this free software. For both users' and
|
||||
authors' sake, the GPL requires that modified versions be marked as
|
||||
changed, so that their problems will not be attributed erroneously to
|
||||
authors of previous versions.
|
||||
|
||||
Some devices are designed to deny users access to install or run
|
||||
modified versions of the software inside them, although the manufacturer
|
||||
can do so. This is fundamentally incompatible with the aim of
|
||||
protecting users' freedom to change the software. The systematic
|
||||
pattern of such abuse occurs in the area of products for individuals to
|
||||
use, which is precisely where it is most unacceptable. Therefore, we
|
||||
have designed this version of the GPL to prohibit the practice for those
|
||||
products. If such problems arise substantially in other domains, we
|
||||
stand ready to extend this provision to those domains in future versions
|
||||
of the GPL, as needed to protect the freedom of users.
|
||||
|
||||
Finally, every program is threatened constantly by software patents.
|
||||
States should not allow patents to restrict development and use of
|
||||
software on general-purpose computers, but in those that do, we wish to
|
||||
avoid the special danger that patents applied to a free program could
|
||||
make it effectively proprietary. To prevent this, the GPL assures that
|
||||
patents cannot be used to render the program non-free.
|
||||
|
||||
The precise terms and conditions for copying, distribution and
|
||||
modification follow.
|
||||
|
||||
TERMS AND CONDITIONS
|
||||
|
||||
0. Definitions.
|
||||
|
||||
"This License" refers to version 3 of the GNU General Public License.
|
||||
|
||||
"Copyright" also means copyright-like laws that apply to other kinds of
|
||||
works, such as semiconductor masks.
|
||||
|
||||
"The Program" refers to any copyrightable work licensed under this
|
||||
License. Each licensee is addressed as "you". "Licensees" and
|
||||
"recipients" may be individuals or organizations.
|
||||
|
||||
To "modify" a work means to copy from or adapt all or part of the work
|
||||
in a fashion requiring copyright permission, other than the making of an
|
||||
exact copy. The resulting work is called a "modified version" of the
|
||||
earlier work or a work "based on" the earlier work.
|
||||
|
||||
A "covered work" means either the unmodified Program or a work based
|
||||
on the Program.
|
||||
|
||||
To "propagate" a work means to do anything with it that, without
|
||||
permission, would make you directly or secondarily liable for
|
||||
infringement under applicable copyright law, except executing it on a
|
||||
computer or modifying a private copy. Propagation includes copying,
|
||||
distribution (with or without modification), making available to the
|
||||
public, and in some countries other activities as well.
|
||||
|
||||
To "convey" a work means any kind of propagation that enables other
|
||||
parties to make or receive copies. Mere interaction with a user through
|
||||
a computer network, with no transfer of a copy, is not conveying.
|
||||
|
||||
An interactive user interface displays "Appropriate Legal Notices"
|
||||
to the extent that it includes a convenient and prominently visible
|
||||
feature that (1) displays an appropriate copyright notice, and (2)
|
||||
tells the user that there is no warranty for the work (except to the
|
||||
extent that warranties are provided), that licensees may convey the
|
||||
work under this License, and how to view a copy of this License. If
|
||||
the interface presents a list of user commands or options, such as a
|
||||
menu, a prominent item in the list meets this criterion.
|
||||
|
||||
1. Source Code.
|
||||
|
||||
The "source code" for a work means the preferred form of the work
|
||||
for making modifications to it. "Object code" means any non-source
|
||||
form of a work.
|
||||
|
||||
A "Standard Interface" means an interface that either is an official
|
||||
standard defined by a recognized standards body, or, in the case of
|
||||
interfaces specified for a particular programming language, one that
|
||||
is widely used among developers working in that language.
|
||||
|
||||
The "System Libraries" of an executable work include anything, other
|
||||
than the work as a whole, that (a) is included in the normal form of
|
||||
packaging a Major Component, but which is not part of that Major
|
||||
Component, and (b) serves only to enable use of the work with that
|
||||
Major Component, or to implement a Standard Interface for which an
|
||||
implementation is available to the public in source code form. A
|
||||
"Major Component", in this context, means a major essential component
|
||||
(kernel, window system, and so on) of the specific operating system
|
||||
(if any) on which the executable work runs, or a compiler used to
|
||||
produce the work, or an object code interpreter used to run it.
|
||||
|
||||
The "Corresponding Source" for a work in object code form means all
|
||||
the source code needed to generate, install, and (for an executable
|
||||
work) run the object code and to modify the work, including scripts to
|
||||
control those activities. However, it does not include the work's
|
||||
System Libraries, or general-purpose tools or generally available free
|
||||
programs which are used unmodified in performing those activities but
|
||||
which are not part of the work. For example, Corresponding Source
|
||||
includes interface definition files associated with source files for
|
||||
the work, and the source code for shared libraries and dynamically
|
||||
linked subprograms that the work is specifically designed to require,
|
||||
such as by intimate data communication or control flow between those
|
||||
subprograms and other parts of the work.
|
||||
|
||||
The Corresponding Source need not include anything that users
|
||||
can regenerate automatically from other parts of the Corresponding
|
||||
Source.
|
||||
|
||||
The Corresponding Source for a work in source code form is that
|
||||
same work.
|
||||
|
||||
2. Basic Permissions.
|
||||
|
||||
All rights granted under this License are granted for the term of
|
||||
copyright on the Program, and are irrevocable provided the stated
|
||||
conditions are met. This License explicitly affirms your unlimited
|
||||
permission to run the unmodified Program. The output from running a
|
||||
covered work is covered by this License only if the output, given its
|
||||
content, constitutes a covered work. This License acknowledges your
|
||||
rights of fair use or other equivalent, as provided by copyright law.
|
||||
|
||||
You may make, run and propagate covered works that you do not
|
||||
convey, without conditions so long as your license otherwise remains
|
||||
in force. You may convey covered works to others for the sole purpose
|
||||
of having them make modifications exclusively for you, or provide you
|
||||
with facilities for running those works, provided that you comply with
|
||||
the terms of this License in conveying all material for which you do
|
||||
not control copyright. Those thus making or running the covered works
|
||||
for you must do so exclusively on your behalf, under your direction
|
||||
and control, on terms that prohibit them from making any copies of
|
||||
your copyrighted material outside their relationship with you.
|
||||
|
||||
Conveying under any other circumstances is permitted solely under
|
||||
the conditions stated below. Sublicensing is not allowed; section 10
|
||||
makes it unnecessary.
|
||||
|
||||
3. Protecting Users' Legal Rights From Anti-Circumvention Law.
|
||||
|
||||
No covered work shall be deemed part of an effective technological
|
||||
measure under any applicable law fulfilling obligations under article
|
||||
11 of the WIPO copyright treaty adopted on 20 December 1996, or
|
||||
similar laws prohibiting or restricting circumvention of such
|
||||
measures.
|
||||
|
||||
When you convey a covered work, you waive any legal power to forbid
|
||||
circumvention of technological measures to the extent such circumvention
|
||||
is effected by exercising rights under this License with respect to
|
||||
the covered work, and you disclaim any intention to limit operation or
|
||||
modification of the work as a means of enforcing, against the work's
|
||||
users, your or third parties' legal rights to forbid circumvention of
|
||||
technological measures.
|
||||
|
||||
4. Conveying Verbatim Copies.
|
||||
|
||||
You may convey verbatim copies of the Program's source code as you
|
||||
receive it, in any medium, provided that you conspicuously and
|
||||
appropriately publish on each copy an appropriate copyright notice;
|
||||
keep intact all notices stating that this License and any
|
||||
non-permissive terms added in accord with section 7 apply to the code;
|
||||
keep intact all notices of the absence of any warranty; and give all
|
||||
recipients a copy of this License along with the Program.
|
||||
|
||||
You may charge any price or no price for each copy that you convey,
|
||||
and you may offer support or warranty protection for a fee.
|
||||
|
||||
5. Conveying Modified Source Versions.
|
||||
|
||||
You may convey a work based on the Program, or the modifications to
|
||||
produce it from the Program, in the form of source code under the
|
||||
terms of section 4, provided that you also meet all of these conditions:
|
||||
|
||||
a) The work must carry prominent notices stating that you modified
|
||||
it, and giving a relevant date.
|
||||
|
||||
b) The work must carry prominent notices stating that it is
|
||||
released under this License and any conditions added under section
|
||||
7. This requirement modifies the requirement in section 4 to
|
||||
"keep intact all notices".
|
||||
|
||||
c) You must license the entire work, as a whole, under this
|
||||
License to anyone who comes into possession of a copy. This
|
||||
License will therefore apply, along with any applicable section 7
|
||||
additional terms, to the whole of the work, and all its parts,
|
||||
regardless of how they are packaged. This License gives no
|
||||
permission to license the work in any other way, but it does not
|
||||
invalidate such permission if you have separately received it.
|
||||
|
||||
d) If the work has interactive user interfaces, each must display
|
||||
Appropriate Legal Notices; however, if the Program has interactive
|
||||
interfaces that do not display Appropriate Legal Notices, your
|
||||
work need not make them do so.
|
||||
|
||||
A compilation of a covered work with other separate and independent
|
||||
works, which are not by their nature extensions of the covered work,
|
||||
and which are not combined with it such as to form a larger program,
|
||||
in or on a volume of a storage or distribution medium, is called an
|
||||
"aggregate" if the compilation and its resulting copyright are not
|
||||
used to limit the access or legal rights of the compilation's users
|
||||
beyond what the individual works permit. Inclusion of a covered work
|
||||
in an aggregate does not cause this License to apply to the other
|
||||
parts of the aggregate.
|
||||
|
||||
6. Conveying Non-Source Forms.
|
||||
|
||||
You may convey a covered work in object code form under the terms
|
||||
of sections 4 and 5, provided that you also convey the
|
||||
machine-readable Corresponding Source under the terms of this License,
|
||||
in one of these ways:
|
||||
|
||||
a) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by the
|
||||
Corresponding Source fixed on a durable physical medium
|
||||
customarily used for software interchange.
|
||||
|
||||
b) Convey the object code in, or embodied in, a physical product
|
||||
(including a physical distribution medium), accompanied by a
|
||||
written offer, valid for at least three years and valid for as
|
||||
long as you offer spare parts or customer support for that product
|
||||
model, to give anyone who possesses the object code either (1) a
|
||||
copy of the Corresponding Source for all the software in the
|
||||
product that is covered by this License, on a durable physical
|
||||
medium customarily used for software interchange, for a price no
|
||||
more than your reasonable cost of physically performing this
|
||||
conveying of source, or (2) access to copy the
|
||||
Corresponding Source from a network server at no charge.
|
||||
|
||||
c) Convey individual copies of the object code with a copy of the
|
||||
written offer to provide the Corresponding Source. This
|
||||
alternative is allowed only occasionally and noncommercially, and
|
||||
only if you received the object code with such an offer, in accord
|
||||
with subsection 6b.
|
||||
|
||||
d) Convey the object code by offering access from a designated
|
||||
place (gratis or for a charge), and offer equivalent access to the
|
||||
Corresponding Source in the same way through the same place at no
|
||||
further charge. You need not require recipients to copy the
|
||||
Corresponding Source along with the object code. If the place to
|
||||
copy the object code is a network server, the Corresponding Source
|
||||
may be on a different server (operated by you or a third party)
|
||||
that supports equivalent copying facilities, provided you maintain
|
||||
clear directions next to the object code saying where to find the
|
||||
Corresponding Source. Regardless of what server hosts the
|
||||
Corresponding Source, you remain obligated to ensure that it is
|
||||
available for as long as needed to satisfy these requirements.
|
||||
|
||||
e) Convey the object code using peer-to-peer transmission, provided
|
||||
you inform other peers where the object code and Corresponding
|
||||
Source of the work are being offered to the general public at no
|
||||
charge under subsection 6d.
|
||||
|
||||
A separable portion of the object code, whose source code is excluded
|
||||
from the Corresponding Source as a System Library, need not be
|
||||
included in conveying the object code work.
|
||||
|
||||
A "User Product" is either (1) a "consumer product", which means any
|
||||
tangible personal property which is normally used for personal, family,
|
||||
or household purposes, or (2) anything designed or sold for incorporation
|
||||
into a dwelling. In determining whether a product is a consumer product,
|
||||
doubtful cases shall be resolved in favor of coverage. For a particular
|
||||
product received by a particular user, "normally used" refers to a
|
||||
typical or common use of that class of product, regardless of the status
|
||||
of the particular user or of the way in which the particular user
|
||||
actually uses, or expects or is expected to use, the product. A product
|
||||
is a consumer product regardless of whether the product has substantial
|
||||
commercial, industrial or non-consumer uses, unless such uses represent
|
||||
the only significant mode of use of the product.
|
||||
|
||||
"Installation Information" for a User Product means any methods,
|
||||
procedures, authorization keys, or other information required to install
|
||||
and execute modified versions of a covered work in that User Product from
|
||||
a modified version of its Corresponding Source. The information must
|
||||
suffice to ensure that the continued functioning of the modified object
|
||||
code is in no case prevented or interfered with solely because
|
||||
modification has been made.
|
||||
|
||||
If you convey an object code work under this section in, or with, or
|
||||
specifically for use in, a User Product, and the conveying occurs as
|
||||
part of a transaction in which the right of possession and use of the
|
||||
User Product is transferred to the recipient in perpetuity or for a
|
||||
fixed term (regardless of how the transaction is characterized), the
|
||||
Corresponding Source conveyed under this section must be accompanied
|
||||
by the Installation Information. But this requirement does not apply
|
||||
if neither you nor any third party retains the ability to install
|
||||
modified object code on the User Product (for example, the work has
|
||||
been installed in ROM).
|
||||
|
||||
The requirement to provide Installation Information does not include a
|
||||
requirement to continue to provide support service, warranty, or updates
|
||||
for a work that has been modified or installed by the recipient, or for
|
||||
the User Product in which it has been modified or installed. Access to a
|
||||
network may be denied when the modification itself materially and
|
||||
adversely affects the operation of the network or violates the rules and
|
||||
protocols for communication across the network.
|
||||
|
||||
Corresponding Source conveyed, and Installation Information provided,
|
||||
in accord with this section must be in a format that is publicly
|
||||
documented (and with an implementation available to the public in
|
||||
source code form), and must require no special password or key for
|
||||
unpacking, reading or copying.
|
||||
|
||||
7. Additional Terms.
|
||||
|
||||
"Additional permissions" are terms that supplement the terms of this
|
||||
License by making exceptions from one or more of its conditions.
|
||||
Additional permissions that are applicable to the entire Program shall
|
||||
be treated as though they were included in this License, to the extent
|
||||
that they are valid under applicable law. If additional permissions
|
||||
apply only to part of the Program, that part may be used separately
|
||||
under those permissions, but the entire Program remains governed by
|
||||
this License without regard to the additional permissions.
|
||||
|
||||
When you convey a copy of a covered work, you may at your option
|
||||
remove any additional permissions from that copy, or from any part of
|
||||
it. (Additional permissions may be written to require their own
|
||||
removal in certain cases when you modify the work.) You may place
|
||||
additional permissions on material, added by you to a covered work,
|
||||
for which you have or can give appropriate copyright permission.
|
||||
|
||||
Notwithstanding any other provision of this License, for material you
|
||||
add to a covered work, you may (if authorized by the copyright holders of
|
||||
that material) supplement the terms of this License with terms:
|
||||
|
||||
a) Disclaiming warranty or limiting liability differently from the
|
||||
terms of sections 15 and 16 of this License; or
|
||||
|
||||
b) Requiring preservation of specified reasonable legal notices or
|
||||
author attributions in that material or in the Appropriate Legal
|
||||
Notices displayed by works containing it; or
|
||||
|
||||
c) Prohibiting misrepresentation of the origin of that material, or
|
||||
requiring that modified versions of such material be marked in
|
||||
reasonable ways as different from the original version; or
|
||||
|
||||
d) Limiting the use for publicity purposes of names of licensors or
|
||||
authors of the material; or
|
||||
|
||||
e) Declining to grant rights under trademark law for use of some
|
||||
trade names, trademarks, or service marks; or
|
||||
|
||||
f) Requiring indemnification of licensors and authors of that
|
||||
material by anyone who conveys the material (or modified versions of
|
||||
it) with contractual assumptions of liability to the recipient, for
|
||||
any liability that these contractual assumptions directly impose on
|
||||
those licensors and authors.
|
||||
|
||||
All other non-permissive additional terms are considered "further
|
||||
restrictions" within the meaning of section 10. If the Program as you
|
||||
received it, or any part of it, contains a notice stating that it is
|
||||
governed by this License along with a term that is a further
|
||||
restriction, you may remove that term. If a license document contains
|
||||
a further restriction but permits relicensing or conveying under this
|
||||
License, you may add to a covered work material governed by the terms
|
||||
of that license document, provided that the further restriction does
|
||||
not survive such relicensing or conveying.
|
||||
|
||||
If you add terms to a covered work in accord with this section, you
|
||||
must place, in the relevant source files, a statement of the
|
||||
additional terms that apply to those files, or a notice indicating
|
||||
where to find the applicable terms.
|
||||
|
||||
Additional terms, permissive or non-permissive, may be stated in the
|
||||
form of a separately written license, or stated as exceptions;
|
||||
the above requirements apply either way.
|
||||
|
||||
8. Termination.
|
||||
|
||||
You may not propagate or modify a covered work except as expressly
|
||||
provided under this License. Any attempt otherwise to propagate or
|
||||
modify it is void, and will automatically terminate your rights under
|
||||
this License (including any patent licenses granted under the third
|
||||
paragraph of section 11).
|
||||
|
||||
However, if you cease all violation of this License, then your
|
||||
license from a particular copyright holder is reinstated (a)
|
||||
provisionally, unless and until the copyright holder explicitly and
|
||||
finally terminates your license, and (b) permanently, if the copyright
|
||||
holder fails to notify you of the violation by some reasonable means
|
||||
prior to 60 days after the cessation.
|
||||
|
||||
Moreover, your license from a particular copyright holder is
|
||||
reinstated permanently if the copyright holder notifies you of the
|
||||
violation by some reasonable means, this is the first time you have
|
||||
received notice of violation of this License (for any work) from that
|
||||
copyright holder, and you cure the violation prior to 30 days after
|
||||
your receipt of the notice.
|
||||
|
||||
Termination of your rights under this section does not terminate the
|
||||
licenses of parties who have received copies or rights from you under
|
||||
this License. If your rights have been terminated and not permanently
|
||||
reinstated, you do not qualify to receive new licenses for the same
|
||||
material under section 10.
|
||||
|
||||
9. Acceptance Not Required for Having Copies.
|
||||
|
||||
You are not required to accept this License in order to receive or
|
||||
run a copy of the Program. Ancillary propagation of a covered work
|
||||
occurring solely as a consequence of using peer-to-peer transmission
|
||||
to receive a copy likewise does not require acceptance. However,
|
||||
nothing other than this License grants you permission to propagate or
|
||||
modify any covered work. These actions infringe copyright if you do
|
||||
not accept this License. Therefore, by modifying or propagating a
|
||||
covered work, you indicate your acceptance of this License to do so.
|
||||
|
||||
10. Automatic Licensing of Downstream Recipients.
|
||||
|
||||
Each time you convey a covered work, the recipient automatically
|
||||
receives a license from the original licensors, to run, modify and
|
||||
propagate that work, subject to this License. You are not responsible
|
||||
for enforcing compliance by third parties with this License.
|
||||
|
||||
An "entity transaction" is a transaction transferring control of an
|
||||
organization, or substantially all assets of one, or subdividing an
|
||||
organization, or merging organizations. If propagation of a covered
|
||||
work results from an entity transaction, each party to that
|
||||
transaction who receives a copy of the work also receives whatever
|
||||
licenses to the work the party's predecessor in interest had or could
|
||||
give under the previous paragraph, plus a right to possession of the
|
||||
Corresponding Source of the work from the predecessor in interest, if
|
||||
the predecessor has it or can get it with reasonable efforts.
|
||||
|
||||
You may not impose any further restrictions on the exercise of the
|
||||
rights granted or affirmed under this License. For example, you may
|
||||
not impose a license fee, royalty, or other charge for exercise of
|
||||
rights granted under this License, and you may not initiate litigation
|
||||
(including a cross-claim or counterclaim in a lawsuit) alleging that
|
||||
any patent claim is infringed by making, using, selling, offering for
|
||||
sale, or importing the Program or any portion of it.
|
||||
|
||||
11. Patents.
|
||||
|
||||
A "contributor" is a copyright holder who authorizes use under this
|
||||
License of the Program or a work on which the Program is based. The
|
||||
work thus licensed is called the contributor's "contributor version".
|
||||
|
||||
A contributor's "essential patent claims" are all patent claims
|
||||
owned or controlled by the contributor, whether already acquired or
|
||||
hereafter acquired, that would be infringed by some manner, permitted
|
||||
by this License, of making, using, or selling its contributor version,
|
||||
but do not include claims that would be infringed only as a
|
||||
consequence of further modification of the contributor version. For
|
||||
purposes of this definition, "control" includes the right to grant
|
||||
patent sublicenses in a manner consistent with the requirements of
|
||||
this License.
|
||||
|
||||
Each contributor grants you a non-exclusive, worldwide, royalty-free
|
||||
patent license under the contributor's essential patent claims, to
|
||||
make, use, sell, offer for sale, import and otherwise run, modify and
|
||||
propagate the contents of its contributor version.
|
||||
|
||||
In the following three paragraphs, a "patent license" is any express
|
||||
agreement or commitment, however denominated, not to enforce a patent
|
||||
(such as an express permission to practice a patent or covenant not to
|
||||
sue for patent infringement). To "grant" such a patent license to a
|
||||
party means to make such an agreement or commitment not to enforce a
|
||||
patent against the party.
|
||||
|
||||
If you convey a covered work, knowingly relying on a patent license,
|
||||
and the Corresponding Source of the work is not available for anyone
|
||||
to copy, free of charge and under the terms of this License, through a
|
||||
publicly available network server or other readily accessible means,
|
||||
then you must either (1) cause the Corresponding Source to be so
|
||||
available, or (2) arrange to deprive yourself of the benefit of the
|
||||
patent license for this particular work, or (3) arrange, in a manner
|
||||
consistent with the requirements of this License, to extend the patent
|
||||
license to downstream recipients. "Knowingly relying" means you have
|
||||
actual knowledge that, but for the patent license, your conveying the
|
||||
covered work in a country, or your recipient's use of the covered work
|
||||
in a country, would infringe one or more identifiable patents in that
|
||||
country that you have reason to believe are valid.
|
||||
|
||||
If, pursuant to or in connection with a single transaction or
|
||||
arrangement, you convey, or propagate by procuring conveyance of, a
|
||||
covered work, and grant a patent license to some of the parties
|
||||
receiving the covered work authorizing them to use, propagate, modify
|
||||
or convey a specific copy of the covered work, then the patent license
|
||||
you grant is automatically extended to all recipients of the covered
|
||||
work and works based on it.
|
||||
|
||||
A patent license is "discriminatory" if it does not include within
|
||||
the scope of its coverage, prohibits the exercise of, or is
|
||||
conditioned on the non-exercise of one or more of the rights that are
|
||||
specifically granted under this License. You may not convey a covered
|
||||
work if you are a party to an arrangement with a third party that is
|
||||
in the business of distributing software, under which you make payment
|
||||
to the third party based on the extent of your activity of conveying
|
||||
the work, and under which the third party grants, to any of the
|
||||
parties who would receive the covered work from you, a discriminatory
|
||||
patent license (a) in connection with copies of the covered work
|
||||
conveyed by you (or copies made from those copies), or (b) primarily
|
||||
for and in connection with specific products or compilations that
|
||||
contain the covered work, unless you entered into that arrangement,
|
||||
or that patent license was granted, prior to 28 March 2007.
|
||||
|
||||
Nothing in this License shall be construed as excluding or limiting
|
||||
any implied license or other defenses to infringement that may
|
||||
otherwise be available to you under applicable patent law.
|
||||
|
||||
12. No Surrender of Others' Freedom.
|
||||
|
||||
If conditions are imposed on you (whether by court order, agreement or
|
||||
otherwise) that contradict the conditions of this License, they do not
|
||||
excuse you from the conditions of this License. If you cannot convey a
|
||||
covered work so as to satisfy simultaneously your obligations under this
|
||||
License and any other pertinent obligations, then as a consequence you may
|
||||
not convey it at all. For example, if you agree to terms that obligate you
|
||||
to collect a royalty for further conveying from those to whom you convey
|
||||
the Program, the only way you could satisfy both those terms and this
|
||||
License would be to refrain entirely from conveying the Program.
|
||||
|
||||
13. Use with the GNU Affero General Public License.
|
||||
|
||||
Notwithstanding any other provision of this License, you have
|
||||
permission to link or combine any covered work with a work licensed
|
||||
under version 3 of the GNU Affero General Public License into a single
|
||||
combined work, and to convey the resulting work. The terms of this
|
||||
License will continue to apply to the part which is the covered work,
|
||||
but the special requirements of the GNU Affero General Public License,
|
||||
section 13, concerning interaction through a network will apply to the
|
||||
combination as such.
|
||||
|
||||
14. Revised Versions of this License.
|
||||
|
||||
The Free Software Foundation may publish revised and/or new versions of
|
||||
the GNU General Public License from time to time. Such new versions will
|
||||
be similar in spirit to the present version, but may differ in detail to
|
||||
address new problems or concerns.
|
||||
|
||||
Each version is given a distinguishing version number. If the
|
||||
Program specifies that a certain numbered version of the GNU General
|
||||
Public License "or any later version" applies to it, you have the
|
||||
option of following the terms and conditions either of that numbered
|
||||
version or of any later version published by the Free Software
|
||||
Foundation. If the Program does not specify a version number of the
|
||||
GNU General Public License, you may choose any version ever published
|
||||
by the Free Software Foundation.
|
||||
|
||||
If the Program specifies that a proxy can decide which future
|
||||
versions of the GNU General Public License can be used, that proxy's
|
||||
public statement of acceptance of a version permanently authorizes you
|
||||
to choose that version for the Program.
|
||||
|
||||
Later license versions may give you additional or different
|
||||
permissions. However, no additional obligations are imposed on any
|
||||
author or copyright holder as a result of your choosing to follow a
|
||||
later version.
|
||||
|
||||
15. Disclaimer of Warranty.
|
||||
|
||||
THERE IS NO WARRANTY FOR THE PROGRAM, TO THE EXTENT PERMITTED BY
|
||||
APPLICABLE LAW. EXCEPT WHEN OTHERWISE STATED IN WRITING THE COPYRIGHT
|
||||
HOLDERS AND/OR OTHER PARTIES PROVIDE THE PROGRAM "AS IS" WITHOUT WARRANTY
|
||||
OF ANY KIND, EITHER EXPRESSED OR IMPLIED, INCLUDING, BUT NOT LIMITED TO,
|
||||
THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
|
||||
PURPOSE. THE ENTIRE RISK AS TO THE QUALITY AND PERFORMANCE OF THE PROGRAM
|
||||
IS WITH YOU. SHOULD THE PROGRAM PROVE DEFECTIVE, YOU ASSUME THE COST OF
|
||||
ALL NECESSARY SERVICING, REPAIR OR CORRECTION.
|
||||
|
||||
16. Limitation of Liability.
|
||||
|
||||
IN NO EVENT UNLESS REQUIRED BY APPLICABLE LAW OR AGREED TO IN WRITING
|
||||
WILL ANY COPYRIGHT HOLDER, OR ANY OTHER PARTY WHO MODIFIES AND/OR CONVEYS
|
||||
THE PROGRAM AS PERMITTED ABOVE, BE LIABLE TO YOU FOR DAMAGES, INCLUDING ANY
|
||||
GENERAL, SPECIAL, INCIDENTAL OR CONSEQUENTIAL DAMAGES ARISING OUT OF THE
|
||||
USE OR INABILITY TO USE THE PROGRAM (INCLUDING BUT NOT LIMITED TO LOSS OF
|
||||
DATA OR DATA BEING RENDERED INACCURATE OR LOSSES SUSTAINED BY YOU OR THIRD
|
||||
PARTIES OR A FAILURE OF THE PROGRAM TO OPERATE WITH ANY OTHER PROGRAMS),
|
||||
EVEN IF SUCH HOLDER OR OTHER PARTY HAS BEEN ADVISED OF THE POSSIBILITY OF
|
||||
SUCH DAMAGES.
|
||||
|
||||
17. Interpretation of Sections 15 and 16.
|
||||
|
||||
If the disclaimer of warranty and limitation of liability provided
|
||||
above cannot be given local legal effect according to their terms,
|
||||
reviewing courts shall apply local law that most closely approximates
|
||||
an absolute waiver of all civil liability in connection with the
|
||||
Program, unless a warranty or assumption of liability accompanies a
|
||||
copy of the Program in return for a fee.
|
||||
|
||||
END OF TERMS AND CONDITIONS
|
||||
|
||||
How to Apply These Terms to Your New Programs
|
||||
|
||||
If you develop a new program, and you want it to be of the greatest
|
||||
possible use to the public, the best way to achieve this is to make it
|
||||
free software which everyone can redistribute and change under these terms.
|
||||
|
||||
To do so, attach the following notices to the program. It is safest
|
||||
to attach them to the start of each source file to most effectively
|
||||
state the exclusion of warranty; and each file should have at least
|
||||
the "copyright" line and a pointer to where the full notice is found.
|
||||
|
||||
{one line to give the program's name and a brief idea of what it does.}
|
||||
Copyright (C) {year} {name of author}
|
||||
|
||||
This program is free software: you can redistribute it and/or modify
|
||||
it under the terms of the GNU General Public License as published by
|
||||
the Free Software Foundation, either version 3 of the License, or
|
||||
(at your option) any later version.
|
||||
|
||||
This program is distributed in the hope that it will be useful,
|
||||
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
GNU General Public License for more details.
|
||||
|
||||
You should have received a copy of the GNU General Public License
|
||||
along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
|
||||
Also add information on how to contact you by electronic and paper mail.
|
||||
|
||||
If the program does terminal interaction, make it output a short
|
||||
notice like this when it starts in an interactive mode:
|
||||
|
||||
{project} Copyright (C) {year} {fullname}
|
||||
This program comes with ABSOLUTELY NO WARRANTY; for details type `show w'.
|
||||
This is free software, and you are welcome to redistribute it
|
||||
under certain conditions; type `show c' for details.
|
||||
|
||||
The hypothetical commands `show w' and `show c' should show the appropriate
|
||||
parts of the General Public License. Of course, your program's commands
|
||||
might be different; for a GUI interface, you would use an "about box".
|
||||
|
||||
You should also get your employer (if you work as a programmer) or school,
|
||||
if any, to sign a "copyright disclaimer" for the program, if necessary.
|
||||
For more information on this, and how to apply and follow the GNU GPL, see
|
||||
<http://www.gnu.org/licenses/>.
|
||||
|
||||
The GNU General Public License does not permit incorporating your program
|
||||
into proprietary programs. If your program is a subroutine library, you
|
||||
may consider it more useful to permit linking proprietary applications with
|
||||
the library. If this is what you want to do, use the GNU Lesser General
|
||||
Public License instead of this License. But first, please read
|
||||
<http://www.gnu.org/philosophy/why-not-lgpl.html>.
|
53
vendor/kanellov/slim-twig-flash/README.md
vendored
53
vendor/kanellov/slim-twig-flash/README.md
vendored
@ -1,53 +0,0 @@
|
||||
# Slim Twig Flash
|
||||
A Twig extension to access Slim Flash messages in templates.
|
||||
|
||||
| **master** | **develop** |
|
||||
|------------|--------------|
|
||||
| [](https://travis-ci.org/kanellov/slim-twig-flash) | [](https://travis-ci.org/kanellov/slim-twig-flash) |
|
||||
|
||||
## Install
|
||||
|
||||
Via [Composer](https://getcomposer.org/)
|
||||
|
||||
``` terminal
|
||||
composer require kanellov/slim-twig-flash
|
||||
```
|
||||
|
||||
Requires:
|
||||
|
||||
- PHP 5.5.0 or newer
|
||||
- Slim Framework Flash Messages 0.1.0 or newer
|
||||
- Twig 1.18.0 or newer
|
||||
|
||||
## Usage
|
||||
|
||||
- Add extension to your twig view
|
||||
|
||||
``` php
|
||||
...
|
||||
$view->addExtension(new Knlv\Slim\Views\TwigMessages(
|
||||
new Slim\Flash\Messages()
|
||||
));
|
||||
...
|
||||
```
|
||||
|
||||
- In templates use `flash()` or `flash('some_key')` to fetch messages from Flash service
|
||||
|
||||
``` html
|
||||
...
|
||||
<ul class="alert alert-danger">
|
||||
{% for msg in flash('error') %}
|
||||
<li>{{ msg }}</li>
|
||||
{% endfor %}
|
||||
</ul>
|
||||
...
|
||||
```
|
||||
|
||||
## Testing
|
||||
|
||||
``` terminal
|
||||
phpunit
|
||||
```
|
||||
|
||||
## License
|
||||
The GNU GENERAL PUBLIC LICENSE Version 3. Please see [License File](LICENSE) for more information.
|
30
vendor/kanellov/slim-twig-flash/composer.json
vendored
30
vendor/kanellov/slim-twig-flash/composer.json
vendored
@ -1,30 +0,0 @@
|
||||
{
|
||||
"name": "kanellov/slim-twig-flash",
|
||||
"type": "library",
|
||||
"description": "A Twig extension to access Slim Flash messages in templates",
|
||||
"license": "GNU GPLv3",
|
||||
"keywords": ["slim","framework","provider","flash","message", "twig", "extension", "view"],
|
||||
"authors": [
|
||||
{
|
||||
"name": "Vassilis Kanellopoulos",
|
||||
"email": "contact@kanellov.com",
|
||||
"homepage": "http://kanellov.com"
|
||||
}
|
||||
],
|
||||
"require": {
|
||||
"php": ">=5.5.0",
|
||||
"twig/twig": ">=1.18",
|
||||
"slim/flash": ">=0.1.0"
|
||||
},
|
||||
"require-dev": {
|
||||
"friendsofphp/php-cs-fixer": "1.*",
|
||||
"phpunit/PHPUnit": "4.8.0",
|
||||
"satooshi/php-coveralls": "dev-master",
|
||||
"phpunit/phpcov": "2.*"
|
||||
},
|
||||
"autoload": {
|
||||
"psr-4": {
|
||||
"Knlv\\Slim\\Views\\": "src"
|
||||
}
|
||||
}
|
||||
}
|
@ -1,71 +0,0 @@
|
||||
<?php
|
||||
/**
|
||||
* Slim Twig Flash.
|
||||
*
|
||||
* @link https://github.com/kanellov/slim-twig-flash for the canonical source repository
|
||||
*
|
||||
* @copyright Copyright (c) 2016 Vassilis Kanellopoulos <contact@kanellov.com>
|
||||
* @license GNU GPLv3 http://www.gnu.org/licenses/gpl-3.0-standalone.html
|
||||
*/
|
||||
namespace Knlv\Slim\Views;
|
||||
|
||||
use Slim\Flash\Messages;
|
||||
use Twig_Extension;
|
||||
use Twig_SimpleFunction;
|
||||
|
||||
class TwigMessages extends Twig_Extension
|
||||
{
|
||||
/**
|
||||
* @var Messages
|
||||
*/
|
||||
protected $flash;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
*
|
||||
* @param Messages $flash the Flash messages service provider
|
||||
*/
|
||||
public function __construct(Messages $flash)
|
||||
{
|
||||
$this->flash = $flash;
|
||||
}
|
||||
|
||||
/**
|
||||
* Extension name.
|
||||
*
|
||||
* @return string
|
||||
*/
|
||||
public function getName()
|
||||
{
|
||||
return 'slim-twig-flash';
|
||||
}
|
||||
|
||||
/**
|
||||
* Callback for twig.
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getFunctions()
|
||||
{
|
||||
return [
|
||||
new Twig_SimpleFunction('flash', [$this, 'getMessages']),
|
||||
];
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns Flash messages; If key is provided then returns messages
|
||||
* for that key.
|
||||
*
|
||||
* @param string $key
|
||||
*
|
||||
* @return array
|
||||
*/
|
||||
public function getMessages($key = null)
|
||||
{
|
||||
if (null !== $key) {
|
||||
return $this->flash->getMessage($key);
|
||||
}
|
||||
|
||||
return $this->flash->getMessages();
|
||||
}
|
||||
}
|
35
vendor/monolog/monolog/CHANGELOG.md
vendored
35
vendor/monolog/monolog/CHANGELOG.md
vendored
@ -1,3 +1,38 @@
|
||||
### 1.27.1 (2022-06-09)
|
||||
|
||||
* Fixed MandrillHandler support for SwiftMailer 6 (#1676)
|
||||
* Fixed StreamHandler chunk size (backport from #1552)
|
||||
|
||||
### 1.27.0 (2022-03-13)
|
||||
|
||||
* Added $maxDepth / setMaxDepth to NormalizerFormatter / JsonFormatter to configure the maximum depth if the default of 9 does not work for you (#1633)
|
||||
|
||||
### 1.26.1 (2021-05-28)
|
||||
|
||||
* Fixed PHP 8.1 deprecation warning
|
||||
|
||||
### 1.26.0 (2020-12-14)
|
||||
|
||||
* Added $dateFormat and $removeUsedContextFields arguments to PsrLogMessageProcessor (backport from 2.x)
|
||||
|
||||
### 1.25.5 (2020-07-23)
|
||||
|
||||
* Fixed array access on null in RavenHandler
|
||||
* Fixed unique_id in WebProcessor not being disableable
|
||||
|
||||
### 1.25.4 (2020-05-22)
|
||||
|
||||
* Fixed GitProcessor type error when there is no git repo present
|
||||
* Fixed normalization of SoapFault objects containing deeply nested objects as "detail"
|
||||
* Fixed support for relative paths in RotatingFileHandler
|
||||
|
||||
### 1.25.3 (2019-12-20)
|
||||
|
||||
* Fixed formatting of resources in JsonFormatter
|
||||
* Fixed RedisHandler failing to use MULTI properly when passed a proxied Redis instance (e.g. in Symfony with lazy services)
|
||||
* Fixed FilterHandler triggering a notice when handleBatch was filtering all records passed to it
|
||||
* Fixed Turkish locale messing up the conversion of level names to their constant values
|
||||
|
||||
### 1.25.2 (2019-11-13)
|
||||
|
||||
* Fixed normalization of Traversables to avoid traversing them as not all of them are rewindable
|
||||
|
18
vendor/monolog/monolog/composer.json
vendored
18
vendor/monolog/monolog/composer.json
vendored
@ -26,10 +26,8 @@
|
||||
"php-amqplib/php-amqplib": "~2.4",
|
||||
"swiftmailer/swiftmailer": "^5.3|^6.0",
|
||||
"php-console/php-console": "^3.1.3",
|
||||
"phpunit/phpunit-mock-objects": "2.3.0",
|
||||
"jakub-onderka/php-parallel-lint": "0.9"
|
||||
"phpstan/phpstan": "^0.12.59"
|
||||
},
|
||||
"_": "phpunit/phpunit-mock-objects required in 2.3.0 due to https://github.com/sebastianbergmann/phpunit-mock-objects/issues/223 - needs hhvm 3.8+ on travis",
|
||||
"suggest": {
|
||||
"graylog2/gelf-php": "Allow sending log messages to a GrayLog2 server",
|
||||
"sentry/sentry": "Allow sending log messages to a Sentry server",
|
||||
@ -52,15 +50,11 @@
|
||||
"provide": {
|
||||
"psr/log-implementation": "1.0.0"
|
||||
},
|
||||
"extra": {
|
||||
"branch-alias": {
|
||||
"dev-master": "2.0.x-dev"
|
||||
}
|
||||
},
|
||||
"scripts": {
|
||||
"test": [
|
||||
"parallel-lint . --exclude vendor --exclude src/Monolog/Handler/FormattableHandlerInterface.php --exclude src/Monolog/Handler/FormattableHandlerTrait.php --exclude src/Monolog/Handler/ProcessableHandlerInterface.php --exclude src/Monolog/Handler/ProcessableHandlerTrait.php",
|
||||
"phpunit"
|
||||
]
|
||||
"test": "vendor/bin/phpunit",
|
||||
"phpstan": "vendor/bin/phpstan analyse"
|
||||
},
|
||||
"config": {
|
||||
"lock": false
|
||||
}
|
||||
}
|
||||
|
@ -14,7 +14,6 @@ namespace Monolog;
|
||||
use Psr\Log\LoggerInterface;
|
||||
use Psr\Log\LogLevel;
|
||||
use Monolog\Handler\AbstractHandler;
|
||||
use Monolog\Registry;
|
||||
|
||||
/**
|
||||
* Monolog error handler
|
||||
@ -63,6 +62,7 @@ class ErrorHandler
|
||||
//Forces the autoloader to run for LogLevel. Fixes an autoload issue at compile-time on PHP5.3. See https://github.com/Seldaek/monolog/pull/929
|
||||
class_exists('\\Psr\\Log\\LogLevel', true);
|
||||
|
||||
/** @phpstan-ignore-next-line */
|
||||
$handler = new static($logger);
|
||||
if ($errorLevelMap !== false) {
|
||||
$handler->registerErrorHandler($errorLevelMap);
|
||||
|
@ -38,9 +38,11 @@ class JsonFormatter extends NormalizerFormatter
|
||||
/**
|
||||
* @param int $batchMode
|
||||
* @param bool $appendNewline
|
||||
* @param int $maxDepth
|
||||
*/
|
||||
public function __construct($batchMode = self::BATCH_MODE_JSON, $appendNewline = true)
|
||||
public function __construct($batchMode = self::BATCH_MODE_JSON, $appendNewline = true, $maxDepth = 9)
|
||||
{
|
||||
parent::__construct(null, $maxDepth);
|
||||
$this->batchMode = $batchMode;
|
||||
$this->appendNewline = $appendNewline;
|
||||
}
|
||||
@ -141,8 +143,8 @@ class JsonFormatter extends NormalizerFormatter
|
||||
*/
|
||||
protected function normalize($data, $depth = 0)
|
||||
{
|
||||
if ($depth > 9) {
|
||||
return 'Over 9 levels deep, aborting normalization';
|
||||
if ($depth > $this->maxDepth) {
|
||||
return 'Over '.$this->maxDepth.' levels deep, aborting normalization';
|
||||
}
|
||||
|
||||
if (is_array($data)) {
|
||||
@ -165,6 +167,10 @@ class JsonFormatter extends NormalizerFormatter
|
||||
return $this->normalizeException($data);
|
||||
}
|
||||
|
||||
if (is_resource($data)) {
|
||||
return parent::normalize($data);
|
||||
}
|
||||
|
||||
return $data;
|
||||
}
|
||||
|
||||
|
@ -24,13 +24,16 @@ class NormalizerFormatter implements FormatterInterface
|
||||
const SIMPLE_DATE = "Y-m-d H:i:s";
|
||||
|
||||
protected $dateFormat;
|
||||
protected $maxDepth;
|
||||
|
||||
/**
|
||||
* @param string $dateFormat The format of the timestamp: one supported by DateTime::format
|
||||
* @param int $maxDepth
|
||||
*/
|
||||
public function __construct($dateFormat = null)
|
||||
public function __construct($dateFormat = null, $maxDepth = 9)
|
||||
{
|
||||
$this->dateFormat = $dateFormat ?: static::SIMPLE_DATE;
|
||||
$this->maxDepth = $maxDepth;
|
||||
if (!function_exists('json_encode')) {
|
||||
throw new \RuntimeException('PHP\'s json extension is required to use Monolog\'s NormalizerFormatter');
|
||||
}
|
||||
@ -56,10 +59,26 @@ class NormalizerFormatter implements FormatterInterface
|
||||
return $records;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return int
|
||||
*/
|
||||
public function getMaxDepth()
|
||||
{
|
||||
return $this->maxDepth;
|
||||
}
|
||||
|
||||
/**
|
||||
* @param int $maxDepth
|
||||
*/
|
||||
public function setMaxDepth($maxDepth)
|
||||
{
|
||||
$this->maxDepth = $maxDepth;
|
||||
}
|
||||
|
||||
protected function normalize($data, $depth = 0)
|
||||
{
|
||||
if ($depth > 9) {
|
||||
return 'Over 9 levels deep, aborting normalization';
|
||||
if ($depth > $this->maxDepth) {
|
||||
return 'Over '.$this->maxDepth.' levels deep, aborting normalization';
|
||||
}
|
||||
|
||||
if (null === $data || is_scalar($data)) {
|
||||
@ -142,8 +161,12 @@ class NormalizerFormatter implements FormatterInterface
|
||||
$data['faultactor'] = $e->faultactor;
|
||||
}
|
||||
|
||||
if (isset($e->detail) && (is_string($e->detail) || is_object($e->detail) || is_array($e->detail))) {
|
||||
$data['detail'] = is_string($e->detail) ? $e->detail : reset($e->detail);
|
||||
if (isset($e->detail)) {
|
||||
if (is_string($e->detail)) {
|
||||
$data['detail'] = $e->detail;
|
||||
} elseif (is_object($e->detail) || is_array($e->detail)) {
|
||||
$data['detail'] = $this->toJson($e->detail, true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -33,7 +33,7 @@ abstract class AbstractHandler implements HandlerInterface, ResettableInterface
|
||||
protected $processors = array();
|
||||
|
||||
/**
|
||||
* @param int $level The minimum logging level at which this handler will be triggered
|
||||
* @param int|string $level The minimum logging level at which this handler will be triggered
|
||||
* @param bool $bubble Whether the messages that are handled can bubble up the stack or not
|
||||
*/
|
||||
public function __construct($level = Logger::DEBUG, $bubble = true)
|
||||
|
@ -77,6 +77,7 @@ class DynamoDbHandler extends AbstractProcessingHandler
|
||||
if ($this->version === 3) {
|
||||
$formatted = $this->marshaler->marshalItem($filtered);
|
||||
} else {
|
||||
/** @phpstan-ignore-next-line */
|
||||
$formatted = $this->client->formatAttributes($filtered);
|
||||
}
|
||||
|
||||
|
@ -128,8 +128,10 @@ class FilterHandler extends AbstractHandler
|
||||
}
|
||||
}
|
||||
|
||||
if (count($filtered) > 0) {
|
||||
$this->getHandler($filtered[count($filtered) - 1])->handleBatch($filtered);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* Return the nested handler
|
||||
|
@ -72,7 +72,7 @@ class FirePHPHandler extends AbstractProcessingHandler
|
||||
*
|
||||
* @see createHeader()
|
||||
* @param array $record
|
||||
* @return string
|
||||
* @return array
|
||||
*/
|
||||
protected function createRecordHeader(array $record)
|
||||
{
|
||||
|
@ -27,7 +27,7 @@ use Monolog\Formatter\GelfMessageFormatter;
|
||||
class GelfHandler extends AbstractProcessingHandler
|
||||
{
|
||||
/**
|
||||
* @var Publisher the publisher object that sends the message to the server
|
||||
* @var Publisher|PublisherInterface|IMessagePublisher the publisher object that sends the message to the server
|
||||
*/
|
||||
protected $publisher;
|
||||
|
||||
|
@ -270,10 +270,10 @@ class HipChatHandler extends SocketHandler
|
||||
* will be the highest level from the given records. Datetime will be taken
|
||||
* from the first record.
|
||||
*
|
||||
* @param $records
|
||||
* @param array $records
|
||||
* @return array
|
||||
*/
|
||||
private function combineRecords($records)
|
||||
private function combineRecords(array $records)
|
||||
{
|
||||
$batchRecord = null;
|
||||
$batchRecords = array();
|
||||
|
@ -50,7 +50,11 @@ class MandrillHandler extends MailHandler
|
||||
{
|
||||
$message = clone $this->message;
|
||||
$message->setBody($content);
|
||||
if (version_compare(\Swift::VERSION, '6.0.0', '>=')) {
|
||||
$message->setDate(new \DateTimeImmutable());
|
||||
} else {
|
||||
$message->setDate(time());
|
||||
}
|
||||
|
||||
$ch = curl_init();
|
||||
|
||||
|
@ -50,7 +50,7 @@ class RavenHandler extends AbstractProcessingHandler
|
||||
protected $ravenClient;
|
||||
|
||||
/**
|
||||
* @var LineFormatter The formatter to use for the logs generated via handleBatch()
|
||||
* @var FormatterInterface The formatter to use for the logs generated via handleBatch()
|
||||
*/
|
||||
protected $batchFormatter;
|
||||
|
||||
@ -86,7 +86,7 @@ class RavenHandler extends AbstractProcessingHandler
|
||||
|
||||
// the record with the highest severity is the "main" one
|
||||
$record = array_reduce($records, function ($highest, $record) {
|
||||
if ($record['level'] > $highest['level']) {
|
||||
if (null === $highest || $record['level'] > $highest['level']) {
|
||||
return $record;
|
||||
}
|
||||
|
||||
|
@ -36,7 +36,7 @@ class RedisHandler extends AbstractProcessingHandler
|
||||
* @param string $key The key name to push records to
|
||||
* @param int $level The minimum logging level at which this handler will be triggered
|
||||
* @param bool $bubble Whether the messages that are handled can bubble up the stack or not
|
||||
* @param int $capSize Number of entries to limit list size to
|
||||
* @param int|false $capSize Number of entries to limit list size to
|
||||
*/
|
||||
public function __construct($redis, $key, $level = Logger::DEBUG, $bubble = true, $capSize = false)
|
||||
{
|
||||
@ -73,7 +73,8 @@ class RedisHandler extends AbstractProcessingHandler
|
||||
protected function writeCapped(array $record)
|
||||
{
|
||||
if ($this->redisClient instanceof \Redis) {
|
||||
$this->redisClient->multi()
|
||||
$mode = defined('\Redis::MULTI') ? \Redis::MULTI : 1;
|
||||
$this->redisClient->multi($mode)
|
||||
->rpush($this->redisKey, $record["formatted"])
|
||||
->ltrim($this->redisKey, -$this->capSize, -1)
|
||||
->exec();
|
||||
|
@ -12,6 +12,7 @@
|
||||
namespace Monolog\Handler;
|
||||
|
||||
use Monolog\Logger;
|
||||
use Monolog\Utils;
|
||||
|
||||
/**
|
||||
* Stores logs to files that are rotated every day and a limited number of files are kept.
|
||||
@ -45,7 +46,7 @@ class RotatingFileHandler extends StreamHandler
|
||||
*/
|
||||
public function __construct($filename, $maxFiles = 0, $level = Logger::DEBUG, $bubble = true, $filePermission = null, $useLocking = false)
|
||||
{
|
||||
$this->filename = $filename;
|
||||
$this->filename = Utils::canonicalizePath($filename);
|
||||
$this->maxFiles = (int) $maxFiles;
|
||||
$this->nextRotation = new \DateTime('tomorrow');
|
||||
$this->filenameFormat = '{filename}-{date}';
|
||||
|
@ -12,6 +12,7 @@
|
||||
namespace Monolog\Handler;
|
||||
|
||||
use Monolog\Logger;
|
||||
use Monolog\Utils;
|
||||
|
||||
/**
|
||||
* Stores to any stream resource
|
||||
@ -22,6 +23,10 @@ use Monolog\Logger;
|
||||
*/
|
||||
class StreamHandler extends AbstractProcessingHandler
|
||||
{
|
||||
/** @private 512KB */
|
||||
const CHUNK_SIZE = 524288;
|
||||
|
||||
/** @var resource|null */
|
||||
protected $stream;
|
||||
protected $url;
|
||||
private $errorMessage;
|
||||
@ -44,8 +49,9 @@ class StreamHandler extends AbstractProcessingHandler
|
||||
parent::__construct($level, $bubble);
|
||||
if (is_resource($stream)) {
|
||||
$this->stream = $stream;
|
||||
$this->streamSetChunkSize();
|
||||
} elseif (is_string($stream)) {
|
||||
$this->url = $stream;
|
||||
$this->url = Utils::canonicalizePath($stream);
|
||||
} else {
|
||||
throw new \InvalidArgumentException('A stream must either be a resource or a string.');
|
||||
}
|
||||
@ -105,8 +111,10 @@ class StreamHandler extends AbstractProcessingHandler
|
||||
restore_error_handler();
|
||||
if (!is_resource($this->stream)) {
|
||||
$this->stream = null;
|
||||
throw new \UnexpectedValueException(sprintf('The stream or file "%s" could not be opened: '.$this->errorMessage, $this->url));
|
||||
|
||||
throw new \UnexpectedValueException(sprintf('The stream or file "%s" could not be opened in append mode: '.$this->errorMessage, $this->url));
|
||||
}
|
||||
$this->streamSetChunkSize();
|
||||
}
|
||||
|
||||
if ($this->useLocking) {
|
||||
@ -131,6 +139,15 @@ class StreamHandler extends AbstractProcessingHandler
|
||||
fwrite($stream, (string) $record['formatted']);
|
||||
}
|
||||
|
||||
protected function streamSetChunkSize()
|
||||
{
|
||||
if (version_compare(PHP_VERSION, '5.4.0', '>=')) {
|
||||
return stream_set_chunk_size($this->stream, self::CHUNK_SIZE);
|
||||
}
|
||||
|
||||
return false;
|
||||
}
|
||||
|
||||
private function customErrorHandler($code, $msg)
|
||||
{
|
||||
$this->errorMessage = preg_replace('{^(fopen|mkdir)\(.*?\): }', '', $msg);
|
||||
@ -152,7 +169,7 @@ class StreamHandler extends AbstractProcessingHandler
|
||||
return dirname(substr($stream, 7));
|
||||
}
|
||||
|
||||
return;
|
||||
return null;
|
||||
}
|
||||
|
||||
private function createDir()
|
||||
|
13
vendor/monolog/monolog/src/Monolog/Logger.php
vendored
13
vendor/monolog/monolog/src/Monolog/Logger.php
vendored
@ -321,7 +321,7 @@ class Logger implements LoggerInterface, ResettableInterface
|
||||
if ($this->microsecondTimestamps && PHP_VERSION_ID < 70100) {
|
||||
$ts = \DateTime::createFromFormat('U.u', sprintf('%.6F', microtime(true)), static::$timezone);
|
||||
} else {
|
||||
$ts = new \DateTime(null, static::$timezone);
|
||||
$ts = new \DateTime('now', static::$timezone);
|
||||
}
|
||||
$ts->setTimezone(static::$timezone);
|
||||
|
||||
@ -522,13 +522,18 @@ class Logger implements LoggerInterface, ResettableInterface
|
||||
/**
|
||||
* Converts PSR-3 levels to Monolog ones if necessary
|
||||
*
|
||||
* @param string|int Level number (monolog) or name (PSR-3)
|
||||
* @param string|int $level Level number (monolog) or name (PSR-3)
|
||||
* @return int
|
||||
*/
|
||||
public static function toMonologLevel($level)
|
||||
{
|
||||
if (is_string($level) && defined(__CLASS__.'::'.strtoupper($level))) {
|
||||
return constant(__CLASS__.'::'.strtoupper($level));
|
||||
if (is_string($level)) {
|
||||
// Contains chars of all log levels and avoids using strtoupper() which may have
|
||||
// strange results depending on locale (for example, "i" will become "İ")
|
||||
$upper = strtr($level, 'abcdefgilmnortuwy', 'ABCDEFGILMNORTUWY');
|
||||
if (defined(__CLASS__.'::'.$upper)) {
|
||||
return constant(__CLASS__ . '::' . $upper);
|
||||
}
|
||||
}
|
||||
|
||||
return $level;
|
||||
|
@ -52,7 +52,7 @@ class GitProcessor implements ProcessorInterface
|
||||
}
|
||||
|
||||
$branches = `git branch -v --no-abbrev`;
|
||||
if (preg_match('{^\* (.+?)\s+([a-f0-9]{40})(?:\s|$)}m', $branches, $matches)) {
|
||||
if ($branches && preg_match('{^\* (.+?)\s+([a-f0-9]{40})(?:\s|$)}m', $branches, $matches)) {
|
||||
return self::$cache = array(
|
||||
'branch' => $matches[1],
|
||||
'commit' => $matches[2],
|
||||
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue
Block a user