{"action":"created","issue":{"url":"https://api.github.com/repos/ezsystems/LegacyBridge/issues/28","labels_url":"https://api.github.com/repos/ezsystems/LegacyBridge/issues/28/labels{/name}","comments_url":"https://api.github.com/repos/ezsystems/LegacyBridge/issues/28/comments","events_url":"https://api.github.com/repos/ezsystems/LegacyBridge/issues/28/events","html_url":"https://github.com/ezsystems/LegacyBridge/pull/28","id":86621602,"number":28,"title":"Fix EZP-24463: Preview will fail with remember me activated in Legacy and Symfony","user":{"login":"lolautruche","id":313528,"avatar_url":"https://avatars.githubusercontent.com/u/313528?v=3","gravatar_id":"","url":"https://api.github.com/users/lolautruche","html_url":"https://github.com/lolautruche","followers_url":"https://api.github.com/users/lolautruche/followers","following_url":"https://api.github.com/users/lolautruche/following{/other_user}","gists_url":"https://api.github.com/users/lolautruche/gists{/gist_id}","starred_url":"https://api.github.com/users/lolautruche/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lolautruche/subscriptions","organizations_url":"https://api.github.com/users/lolautruche/orgs","repos_url":"https://api.github.com/users/lolautruche/repos","events_url":"https://api.github.com/users/lolautruche/events{/privacy}","received_events_url":"https://api.github.com/users/lolautruche/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-06-09T14:38:55Z","updated_at":"2015-06-10T08:17:42Z","closed_at":null,"pull_request":{"url":"https://api.github.com/repos/ezsystems/LegacyBridge/pulls/28","html_url":"https://github.com/ezsystems/LegacyBridge/pull/28","diff_url":"https://github.com/ezsystems/LegacyBridge/pull/28.diff","patch_url":"https://github.com/ezsystems/LegacyBridge/pull/28.patch"},"body":"> https://jira.ez.no/browse/EZP-24463\r\n\r\nSee [EZP-24367](https://jira.ez.no/browse/EZP-24367) and https://github.com/ezsystems/LegacyBridge/pull/26\r\n\r\nPrevious PR removed `$token->setAuthenticated( true )` as this is not permitted with some tokens like RememberMeToken (hence the exception before).\r\nHowever, not being authenticated has a side effect. The AuthorizationChecker will indeed ensure by default that current token is authenticated before checking authorization. And as preview checks if\r\ncurrent user is granted permission in the PreviewController, permission is denied and the system tries to redirect to the login page.\r\n\r\nThis PR introduces `LegacyToken` which decorates current token. It will always say that it's authenticated. Note that there is no security risk as authentication has already been made by the legacy kernel."},"comment":{"url":"https://api.github.com/repos/ezsystems/LegacyBridge/issues/comments/110646717","html_url":"https://github.com/ezsystems/LegacyBridge/pull/28#issuecomment-110646717","issue_url":"https://api.github.com/repos/ezsystems/LegacyBridge/issues/28","id":110646717,"user":{"login":"glye","id":289744,"avatar_url":"https://avatars.githubusercontent.com/u/289744?v=3","gravatar_id":"","url":"https://api.github.com/users/glye","html_url":"https://github.com/glye","followers_url":"https://api.github.com/users/glye/followers","following_url":"https://api.github.com/users/glye/following{/other_user}","gists_url":"https://api.github.com/users/glye/gists{/gist_id}","starred_url":"https://api.github.com/users/glye/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/glye/subscriptions","organizations_url":"https://api.github.com/users/glye/orgs","repos_url":"https://api.github.com/users/glye/repos","events_url":"https://api.github.com/users/glye/events{/privacy}","received_events_url":"https://api.github.com/users/glye/received_events","type":"User","site_admin":false},"created_at":"2015-06-10T08:17:42Z","updated_at":"2015-06-10T08:17:42Z","body":"+1"}}