for testing and deploying your application
for finding and fixing issues
for empowering human code reviews
<?php
declare(strict_types=1);
/*
* The MIT License (MIT)
*
* Copyright (c) 2014-2018 Spomky-Labs
* This software may be modified and distributed under the terms
* of the MIT license. See the LICENSE file for details.
*/
namespace OAuth2Framework\Bundle\Component\ClientAuthentication;
use OAuth2Framework\Bundle\Component\Component;
use Symfony\Component\Config\Definition\Builder\NodeDefinition;
use Symfony\Component\Config\FileLocator;
use Symfony\Component\DependencyInjection\ContainerBuilder;
use Symfony\Component\DependencyInjection\Loader\PhpFileLoader;
class NoneSource implements Component
{
/**
* @return string
public function name(): string
return 'none';
}
* {@inheritdoc}
public function load(array $configs, ContainerBuilder $container)
if ($configs['client_authentication']['none']['enabled']) {
$loader = new PhpFileLoader($container, new FileLocator(__DIR__.'/../../Resources/config/client_authentication'));
$loader->load('none.php');
public function getNodeDefinition(NodeDefinition $node)
$node->children()
->arrayNode($this->name())
->info('The "none" authentication method is designed for public clients')
->canBeEnabled()
->end()
->end();
public function build(ContainerBuilder $container)
//Nothing to do
public function prepend(ContainerBuilder $container, array $config): array
return [];