F1.18 Laravel(Lumen) Security: Implementation features (Wpf, Xamarin, Angular SPA, Reactjs SPA) - chempkovsky/CS2WPF-and-CS2XAMARIN GitHub Wiki
Note 1:
- Please refer to Lumen Security article
- We will use
- AuthServiceProvider
$this->app['auth']->viaRequest('api', function ($request) { ... });
- Since our project is not using Eloquent, we will use
- Illuminate\Auth\GenericUser
Note 2:
Microsoft implementation of JWT authentication (i.e. token()-method) expects the body of the post method to be not "json", but just the string like below
username=myname&password=myassword&grant_type=password
Note 3.1:
The generated code for JWT authentication follows the guidelines outlined in "The Simple & Efficient Way to Enable JWT auth in Laravel..." article.
Note 3.2:
firebase/php-jwt is used in our Symfony projects as well.
Note 4:
Since AspNetUser-table has no roles-column. The roles-field of the user will be filled with a separate request to the (AspNetUserRoles inner join AspNetRoles)-table.