Laravel: v5.4.28
Passport: v1.0.17
League\OAuth2: v5.1.5
I suddenly began seeing this error on my production environment when mobile app was trying to authenticate via API:
ErrorException: You must set the encryption key going forward to improve the security of this library - see this page for more information https://oauth2.thephpleague.com/v5-security-improvements/
If you follow that link you will see that AuthorizationServer now requires you to explicitly call setEncryptionKey() on AuthorizationServer which of course is never happening.
Since PassportServiceProvider instantiates AuthorizationServer shouldn't it also call setEncryptionKey() to avoid this error?
I'm seeing this as well. for the time being if I force "league/oauth2-server": "5.1.3" in composer.json the error goes away.
Version v1.0.18 fixes this.
I just updated to version 1.0.18 in a Laravel 5.3.31 project and I got this error:
PersonalAccessTokenFactory.php line 98: Trying to get property of non-object
Seems like the $client is null for some reason.
Please update to Passport 3.0.* to address these issues.
Most helpful comment
I'm seeing this as well. for the time being if I force "league/oauth2-server": "5.1.3" in composer.json the error goes away.