xdmod icon indicating copy to clipboard operation
xdmod copied to clipboard

Refactor REST API token authentication code to allow for use of existing role-based authorization code.

Open aaronweeden opened this issue 1 year ago • 0 comments

Description

This refactors the authenticateToken() method in classes/Rest/Controllers/BaseControllerProvider.php so that it sets _USER property of the $request object rather than returning the $user object. This allows for the authorize($request, $requirements) method to be subsequently called.

Motivation and Context

Tests performed

Checklist:

  • [ ] The pull request description is suitable for a Changelog entry
  • [ ] The milestone is set correctly on the pull request
  • [ ] The appropriate labels have been added to the pull request

aaronweeden avatar Jul 18 '23 13:07 aaronweeden