Releases: leafsphp/auth
Releases Β· leafsphp/auth
π₯ Sea Buckthorn '1'
v3.3.1 - 22 Dec 2024
Fixed
- Fixed checks for preventing assigning the same role multiple times
- Merged duplicates from permission list of multiple roles
π₯ Sea Buckthorn
v3.3 - 15 Dec 2024
Added
- Added support for roles/permissions
- Added
Auth::createUserFor()
method - Added
Auth::find()
method
Changed
- Added default behaviour for all auth middleware
π₯ Blackthorn
v3.2 - 6 Dec 2024
Fixed
- Rename model
get()
totable()
to avoid confusion with Leaf DBget()
Changed
- Add overload function to skip calling
get()
on model
π₯ Hawthorn '1'
v3.1.1 - 3 Dec 2024
Fixed
- Disable password auth when using
fromOAuth()
π₯ Hawthorn
v3.1 - 2 Dec 2024
Added
- Added
fromOAuth()
method to save a user and create a new session from an OAuth response - Added
oauthToken()
to get currently active tokens added withfromOAuth()
Changed
- Replaced user relationships with model for interacting with other tables with user data
π₯ Firethorn '3'
v3.0.3 - 12 Nov 2024
Fixed
- Patched up JWT expiry error
- Patched up failures from non-numeric session lifetimes
π₯ Firethorn '2'
v3.0.2 - 12 Nov 2024
Fixed
- Patched up exceptions thrown for JWT decode failures
π₯ Firethorn
v3.0.1 - 8 Nov 2024
Fixed
- Check DB connection on user
π₯ Firethorn
v3.0 - 7 Nov 2024
Added
- Auth v3 comes with built-in middleware that integrates with Leaf which means you don't need to write the above or your own middleware or even use guards
- removes the numerous redirect options and removes session guards as well.
- This release adds a super powerful user object which can be used to get user data from the auth layer and db layer
- When you call any method that doesn't exist on the user object, Leaf Auth will assume that you mean to get data related to the current user from the database
- Added
updatePassword()
method to quickly update user passwords in db
Fixed
- Fixed outdated JWT options
Changed
- Session and token auth is more normalized, leaving side effects to you instead of trying to anticipate what you want to do (to the detriment of other users).
- Uniques are now shared between
register()
andupdate()
- Session/Token auth + login, register and update all behave the same way, which leads to more predictable and consistent behaviour
- Back to the user object, it used to return an array which was the user information without any hidden fields. This behaviour has been updated to now return an entire user class. This class has methods and properties for getting user data, tokens and related db as we saw above
- Switched config to camel case to match other modules
Removed
- Removed all redirect configs
- Removed session guards in favour of new middleware
Beyond these changes, we've maintained every other thing v2 came with which means if you had no custom config and didn't use session guards, you can upgrade to v3 with almost zero changes to your existing code.
π Robben Island
v2.4 - 25 August 2024
Added
- Added internal safeties for non-existent values
- Added autoConnect test when no connection is detected
Fixed
- Added
SESSION_REDIRECT_ON_REGISTER
by @milosPavic @ibnsultan - Returned
false
instead ofnull
when errors occur
Changed
- Updated to Leaf's new config API
Removed
- Removed unused methods