{"action":"created","issue":{"url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel/issues/690","repository_url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel","labels_url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel/issues/690/labels{/name}","comments_url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel/issues/690/comments","events_url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel/issues/690/events","html_url":"https://github.com/lucadegasperi/oauth2-server-laravel/issues/690","id":141070794,"number":690,"title":"Redirect URI redirect problem","user":{"login":"ultimateprogramer","id":177851,"avatar_url":"https://avatars.githubusercontent.com/u/177851?v=3","gravatar_id":"","url":"https://api.github.com/users/ultimateprogramer","html_url":"https://github.com/ultimateprogramer","followers_url":"https://api.github.com/users/ultimateprogramer/followers","following_url":"https://api.github.com/users/ultimateprogramer/following{/other_user}","gists_url":"https://api.github.com/users/ultimateprogramer/gists{/gist_id}","starred_url":"https://api.github.com/users/ultimateprogramer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ultimateprogramer/subscriptions","organizations_url":"https://api.github.com/users/ultimateprogramer/orgs","repos_url":"https://api.github.com/users/ultimateprogramer/repos","events_url":"https://api.github.com/users/ultimateprogramer/events{/privacy}","received_events_url":"https://api.github.com/users/ultimateprogramer/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel/labels/question","name":"question","color":"d4c5f9"}],"state":"closed","locked":false,"assignee":{"login":"lucadegasperi","id":820687,"avatar_url":"https://avatars.githubusercontent.com/u/820687?v=3","gravatar_id":"","url":"https://api.github.com/users/lucadegasperi","html_url":"https://github.com/lucadegasperi","followers_url":"https://api.github.com/users/lucadegasperi/followers","following_url":"https://api.github.com/users/lucadegasperi/following{/other_user}","gists_url":"https://api.github.com/users/lucadegasperi/gists{/gist_id}","starred_url":"https://api.github.com/users/lucadegasperi/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lucadegasperi/subscriptions","organizations_url":"https://api.github.com/users/lucadegasperi/orgs","repos_url":"https://api.github.com/users/lucadegasperi/repos","events_url":"https://api.github.com/users/lucadegasperi/events{/privacy}","received_events_url":"https://api.github.com/users/lucadegasperi/received_events","type":"User","site_admin":false},"milestone":null,"comments":9,"created_at":"2016-03-15T19:09:34Z","updated_at":"2016-03-26T06:51:16Z","closed_at":"2016-03-26T06:51:16Z","body":"Developed on top of the system a control panel which we log in and manage various OAuth parameters that are in the database tables (so we automate a lot of that). We just started testing he system by making use of systems that call the `oauth/authorize` endpoint on HTTP get. However, it ceases to redirect back to the calling application, what it does is it shows up the login screen and logs in to the control panel, instead of redirecting back to the caller.\r\n\r\nI made the following call to the OAuth System: `oauth/authorize?client_id=my_client_id&client_secret=my_secret&redirect_uri=http://localhost/redirect_url&scope=access&response_type=code`\r\n\r\nThis redirects me to `/login` (normal Auth login for the Control Panel). It never resumes calling back the endpoint for the callback in the redirect URL, after I login it sends me to my Control Panel's dashboard.\r\n\r\n**Further details**\r\n\r\n```\r\n'grant_types' => [\r\n        'authorization_code' => [\r\n            'class' => '\\League\\OAuth2\\Server\\Grant\\AuthCodeGrant',\r\n           ...\r\n        ]\r\n    ],\r\n```\r\n\r\n"},"comment":{"url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel/issues/comments/201719491","html_url":"https://github.com/lucadegasperi/oauth2-server-laravel/issues/690#issuecomment-201719491","issue_url":"https://api.github.com/repos/lucadegasperi/oauth2-server-laravel/issues/690","id":201719491,"user":{"login":"ultimateprogramer","id":177851,"avatar_url":"https://avatars.githubusercontent.com/u/177851?v=3","gravatar_id":"","url":"https://api.github.com/users/ultimateprogramer","html_url":"https://github.com/ultimateprogramer","followers_url":"https://api.github.com/users/ultimateprogramer/followers","following_url":"https://api.github.com/users/ultimateprogramer/following{/other_user}","gists_url":"https://api.github.com/users/ultimateprogramer/gists{/gist_id}","starred_url":"https://api.github.com/users/ultimateprogramer/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ultimateprogramer/subscriptions","organizations_url":"https://api.github.com/users/ultimateprogramer/orgs","repos_url":"https://api.github.com/users/ultimateprogramer/repos","events_url":"https://api.github.com/users/ultimateprogramer/events{/privacy}","received_events_url":"https://api.github.com/users/ultimateprogramer/received_events","type":"User","site_admin":false},"created_at":"2016-03-26T06:51:16Z","updated_at":"2016-03-26T06:51:16Z","body":"This is solved.. I just had to be smart enough on how to handle sessions in the Authentication middlewares (by employing URL checks). After which session states then allow us to redirect to the correct component."}}