Skip to content

Commit

Permalink
Remove SamlToken
Browse files Browse the repository at this point in the history
This concept was replaced by SamlBundle implementation. While at it, the
dead code that instantiated the SamlToken, but never used it was
removed.
  • Loading branch information
MKodde committed Mar 4, 2024
1 parent 6861648 commit 7106220
Show file tree
Hide file tree
Showing 2 changed files with 1 addition and 48 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -31,7 +31,6 @@
use Surfnet\StepupSelfService\SelfServiceBundle\Exception\MissingRequiredAttributeException;
use Surfnet\StepupSelfService\SelfServiceBundle\Locale\PreferredLocaleProvider;
use Surfnet\StepupSelfService\SelfServiceBundle\Security\Authentication\AuthenticatedIdentity;
use Surfnet\StepupSelfService\SelfServiceBundle\Security\Authentication\Token\SamlToken;
use Surfnet\StepupSelfService\SelfServiceBundle\Service\IdentityService;
use Symfony\Component\Security\Core\User\UserInterface;
use Symfony\Component\Security\Core\User\UserProviderInterface;
Expand Down Expand Up @@ -121,19 +120,12 @@ public function getUser(Assertion $assertion): UserInterface
$this->identityService->updateIdentity($identity);
}

$authenticatedIdentity = new AuthenticatedIdentity($identity);
$authenticatedToken = new SamlToken(['ROLE_USER']);

$authenticatedToken->setUser($authenticatedIdentity);

// return $authenticatedToken;
return $authenticatedIdentity;
return new AuthenticatedIdentity($identity);
}


public function refreshUser(UserInterface $user): UserInterface
{
// TODO: Implement refreshUser() method.
return $user;
}

Expand Down

This file was deleted.

0 comments on commit 7106220

Please sign in to comment.