-
Notifications
You must be signed in to change notification settings - Fork 110
4.x major: Remove deprecations, fix up MultiChecker. #748
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: 3.x
Are you sure you want to change the base?
Conversation
|
For some reason 4.x is now protected already, even though just created. |
The protection rule is set for |
Co-authored-by: ADmad <[email protected]>
Co-authored-by: ADmad <[email protected]>
Co-authored-by: ADmad <[email protected]>
|
Auth code looks pretty clean and cake-user-friendly now, doesnt it? |
|
@ADmad How do we merge our regression fix into this? |
|
Doing it in |
- Use lazy identifier initialization in getIdentifier() (3.x approach) - Add AuthenticationPlugin as main plugin class, Plugin as deprecated alias - Add redirect validation feature from 3.x - Update all authenticators to use getIdentifier() instead of direct property access
Co-authored-by: ADmad <[email protected]>
markstory
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Looking good. I think the impacts of these breaking changes should be a reasonable amount of work in a small section for most applications. I don't think we need to worry about rector here. I like how the authenticator + identifier relationship has ended up working.
|
Just to be clear: Config needs to change from: $identifier = [
'Authentication.Token' => [
'tokenField' => 'id',
'dataField' => 'key',
'resolver' => [
'className' => 'Authentication.Orm',
'finder' => 'auth',
],
],
];To: $identifier = [
'className' => 'Authentication.Token',
'tokenField' => 'id',
'dataField' => 'key',
'resolver' => [
'className' => 'Authentication.Orm',
'finder' => 'auth',
],
];We could shim this (allow for the old array one), but then it would be possible to also insert multiple array key/value pairs or alike. |
|
I think just clarifying the change in a migration guide should suffice |
Adds rules to automate the 3.x to 4.x migration for the authentication plugin: - Rename CakeRouterUrlChecker to DefaultUrlChecker - Rename DefaultUrlChecker (framework-agnostic) to GenericUrlChecker - Rename Plugin to AuthenticationPlugin - Remove loadIdentifier() method calls See: cakephp/authentication#748
|
Some things are auto-upgradable: cakephp/upgrade#370 Shall we start the release process on this major? |
Since we are doing a new major I think we can make this a "proper" CakePHP plugin, i.e. add If we do so then some housekeeping that can be done is, rename |
|
Technically, https://github.com/cakephp/authorization/blob/459cd4d752b3b93ff49791b33ae42a04b82cceb4/composer.json#L27 also only has one package Couldnt we do the housekeeping for it anyways? and document it as such? |
|
Yes we can do the same for Authorization too. |
Prepare #716