stable

Clone or download

Read-only

Save user-app association

Part of story #14570 Authorization grant confirmation page How to test: - Create a new OAuth2 app in a project administration. - Access the authorization endpoint. '<client_id> and <redirect_uri> must be replaced. <redirect_uri> should be URL-encoded. https://tuleap.example.com/oauth2/authorize?client_id=<client_id>&state=xyz&response_type=code&scope=demo%20read:project&redirect_uri=<redirect_uri> When you click on "Authorize", you should be redirected to the <redirect_uri> with a "code" parameter representing the authorization code. A new row will be saved in DB table tuleap.oauth2_authorization with your user's ID and the authorized app's ID. Change-Id: Ic32a7dca59b1e4eb52c91fa2b5c14220dc25b52b

Modified Files

Name
M plugins/oauth2_server/db/install.sql +7 −0 Go to diff View file
A plugins/oauth2_server/db/mysql/2020/202003110930_create_authorization_table.php +47 −0 Go to diff View file
M plugins/oauth2_server/db/uninstall.sql +1 −0 Go to diff View file
M plugins/oauth2_server/include/AuthorizationServer/AuthorizationEndpointPostController.php +30 −6 Go to diff View file
M plugins/oauth2_server/include/AuthorizationServer/AuthorizationFormPresenter.php +8 −2 Go to diff View file
A plugins/oauth2_server/include/User/AuthorizationDao.php +43 −0 Go to diff View file
A plugins/oauth2_server/include/User/AuthorizationManager.php +43 −0 Go to diff View file
M plugins/oauth2_server/include/oauth2_serverPlugin.php +1 −0 Go to diff View file
M plugins/oauth2_server/phpunit/AuthorizationServer/AuthorizationEndpointPostControllerTest.php +34 −6 Go to diff View file
A plugins/oauth2_server/phpunit/User/AuthorizationManagerTest.php +74 −0 Go to diff View file
M plugins/oauth2_server/templates/authorization-form.mustache +1 −0 Go to diff View file