IBX-8656: Skipped credentials check for SelfValidatingPassport
#411
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Related PRs:
Description:
Another step in our "new security" journey. As an example,
ibexa/oauth2-client
bundle is an integration withknpuniversity/oauth2-client-bundle
. Due to Symfony security layer revamp we needed to adjust accordingly, as in other cases touching authentication in general.This case exposed one issue related to
src/lib/MVC/Symfony/Security/Authentication/EventSubscriber/RepositoryUserAuthenticationSubscriber.php
though - full credentials and password hash type check which is needed for a regular authorization doesn't make much sense in that scenario.The reason for that is explicit usage of
Symfony\Component\Security\Http\Authenticator\Passport\SelfValidatingPassport
for users coming from outside of our system. In such cases we need to allow bypassing any additional validation since it's done by 3rd party provider (e.g. Azure, Google, Microsoft etc) already. Users coming from outside are only mapped to our content model and undergo a regularPermissionResolver
flow afterwards. I made sure this case is also covered within existing test case.On this occasion I got rid of unused
InteractiveLoginEvent
which has its Symfony counterpart. The latter is already in use in almost all the cases within Ibexa DXP so this is another natural step.