SecurityFactoryInterface.php 1.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051
  1. <?php
  2. /*
  3. * This file is part of the Symfony package.
  4. *
  5. * (c) Fabien Potencier <fabien@symfony.com>
  6. *
  7. * For the full copyright and license information, please view the LICENSE
  8. * file that was distributed with this source code.
  9. */
  10. namespace Symfony\Bundle\SecurityBundle\DependencyInjection\Security\Factory;
  11. use Symfony\Component\Config\Definition\Builder\NodeDefinition;
  12. use Symfony\Component\DependencyInjection\ContainerBuilder;
  13. /**
  14. * SecurityFactoryInterface is the interface for all security authentication listener.
  15. *
  16. * @author Fabien Potencier <fabien@symfony.com>
  17. */
  18. interface SecurityFactoryInterface
  19. {
  20. /**
  21. * Configures the container services required to use the authentication listener.
  22. *
  23. * @return array containing three values:
  24. * - the provider id
  25. * - the listener id
  26. * - the entry point id
  27. */
  28. public function create(ContainerBuilder $container, string $id, array $config, string $userProviderId, ?string $defaultEntryPointId);
  29. /**
  30. * Defines the position at which the provider is called.
  31. * Possible values: pre_auth, form, http, and remember_me.
  32. *
  33. * @return string
  34. */
  35. public function getPosition();
  36. /**
  37. * Defines the configuration key used to reference the provider
  38. * in the firewall configuration.
  39. *
  40. * @return string
  41. */
  42. public function getKey();
  43. public function addConfiguration(NodeDefinition $builder);
  44. }