Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
[make:registration] drop guard authentication support (#1243)
Co-authored-by: Ryan Weaver <weaverryan+github@gmail.com>
- Loading branch information
1 parent
744ad00
commit cbf2646
Showing
10 changed files
with
462 additions
and
60 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the Symfony MakerBundle package. | ||
* | ||
* (c) Fabien Potencier <fabien@symfony.com> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
namespace Symfony\Bundle\MakerBundle\Security\Model; | ||
|
||
/** | ||
* @author Jesse Rushlow<jr@rushlow.dev> | ||
* | ||
* @internal | ||
*/ | ||
final class Authenticator | ||
{ | ||
public function __construct( | ||
public AuthenticatorType $type, | ||
public string $firewallName, | ||
public ?string $authenticatorClass = null, | ||
) { | ||
} | ||
|
||
/** | ||
* Useful for asking questions like "Which authenticator do you want to use?". | ||
*/ | ||
public function __toString(): string | ||
{ | ||
return sprintf( | ||
'"%s" in the "%s" firewall', | ||
$this->authenticatorClass ?? $this->type->value, | ||
$this->firewallName, | ||
); | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
<?php | ||
|
||
/* | ||
* This file is part of the Symfony MakerBundle package. | ||
* | ||
* (c) Fabien Potencier <fabien@symfony.com> | ||
* | ||
* For the full copyright and license information, please view the LICENSE | ||
* file that was distributed with this source code. | ||
*/ | ||
|
||
namespace Symfony\Bundle\MakerBundle\Security\Model; | ||
|
||
/** | ||
* @author Jesse Rushlow <jr@rushlow.dev> | ||
* | ||
* @internal | ||
*/ | ||
enum AuthenticatorType: string | ||
{ | ||
case FORM_LOGIN = 'form_login'; | ||
case JSON_LOGIN = 'json_login'; | ||
case HTTP_BASIC = 'http_basic'; | ||
case LOGIN_LINK = 'login_link'; | ||
case ACCESS_TOKEN = 'access_token'; | ||
case X509 = 'x509'; | ||
case REMOTE_USER = 'remote_user'; | ||
|
||
case CUSTOM = 'custom_authenticator'; | ||
} |
Oops, something went wrong.