{"action":"created","issue":{"url":"https://api.github.com/repos/joomla/joomla-cms/issues/8573","labels_url":"https://api.github.com/repos/joomla/joomla-cms/issues/8573/labels{/name}","comments_url":"https://api.github.com/repos/joomla/joomla-cms/issues/8573/comments","events_url":"https://api.github.com/repos/joomla/joomla-cms/issues/8573/events","html_url":"https://github.com/joomla/joomla-cms/issues/8573","id":119451844,"number":8573,"title":"303 response code on wrong URLs instead of 404 response code","user":{"login":"Sulpher","id":3432048,"avatar_url":"https://avatars.githubusercontent.com/u/3432048?v=3","gravatar_id":"","url":"https://api.github.com/users/Sulpher","html_url":"https://github.com/Sulpher","followers_url":"https://api.github.com/users/Sulpher/followers","following_url":"https://api.github.com/users/Sulpher/following{/other_user}","gists_url":"https://api.github.com/users/Sulpher/gists{/gist_id}","starred_url":"https://api.github.com/users/Sulpher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sulpher/subscriptions","organizations_url":"https://api.github.com/users/Sulpher/orgs","repos_url":"https://api.github.com/users/Sulpher/repos","events_url":"https://api.github.com/users/Sulpher/events{/privacy}","received_events_url":"https://api.github.com/users/Sulpher/received_events","type":"User","site_admin":false},"labels":[{"url":"https://api.github.com/repos/joomla/joomla-cms/labels/No%20Code%20Attached%20Yet","name":"No Code Attached Yet","color":"ededed"}],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-11-30T09:30:32Z","updated_at":"2015-11-30T09:32:26Z","closed_at":null,"body":"#### Steps to reproduce the issue\r\nI've tested new version of website had to make website offline and work on its SEO and to validate URLs in content.   I turned website offline in global configuration, then log in a front-end under super administrator's credentials and tried to enter any wrong URL.\r\nCorrect url: /about-us.html\r\nIncorrect url that I'm trying to enter: /about-us222abcd.html\r\n\r\n#### Expected result\r\nI must get 404 response code when input wrong URL. \r\n\r\n#### Actual result\r\nRedirect at index.php with 303 response code. \r\n\r\n\r\n#### System information (as much as possible)\r\nI tested it with Joomla 3.4.5\r\n\r\n\r\n#### Additional comments\r\n\r\nIt's happen when website is offline and because of these .htaccess rules:\r\n\r\n## Begin - Joomla! core SEF Section.\r\n#\r\nRewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]\r\n#\r\n# If the requested path and file is not /index.php and the request\r\n# has not already been internally rewritten to the index.php script\r\nRewriteCond %{REQUEST_URI} !^/index\\.php\r\n# and the requested path and file doesn't directly match a physical file\r\nRewriteCond %{REQUEST_FILENAME} !-f\r\n# and the requested path and file doesn't directly match a physical folder\r\nRewriteCond %{REQUEST_FILENAME} !-d\r\n# internally rewrite the request to the index.php script\r\nRewriteRule .* index.php [L]\r\n#\r\n## End - Joomla! core SEF Section.\r\n\r\n\r\n\r\nPlease take a look this issue happens when website is offline and you're logged in as user with enough permissions (administrator and above) at front-end side. URLs should work correct in offline too."},"comment":{"url":"https://api.github.com/repos/joomla/joomla-cms/issues/comments/160570756","html_url":"https://github.com/joomla/joomla-cms/issues/8573#issuecomment-160570756","issue_url":"https://api.github.com/repos/joomla/joomla-cms/issues/8573","id":160570756,"user":{"login":"Sulpher","id":3432048,"avatar_url":"https://avatars.githubusercontent.com/u/3432048?v=3","gravatar_id":"","url":"https://api.github.com/users/Sulpher","html_url":"https://github.com/Sulpher","followers_url":"https://api.github.com/users/Sulpher/followers","following_url":"https://api.github.com/users/Sulpher/following{/other_user}","gists_url":"https://api.github.com/users/Sulpher/gists{/gist_id}","starred_url":"https://api.github.com/users/Sulpher/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Sulpher/subscriptions","organizations_url":"https://api.github.com/users/Sulpher/orgs","repos_url":"https://api.github.com/users/Sulpher/repos","events_url":"https://api.github.com/users/Sulpher/events{/privacy}","received_events_url":"https://api.github.com/users/Sulpher/received_events","type":"User","site_admin":false},"created_at":"2015-11-30T09:32:26Z","updated_at":"2015-11-30T09:32:26Z","body":"Oh, the .htaccess code was stripped in the message above.\n\nHere is it:\n\n## Begin - Joomla! core SEF Section.\n#\nRewriteRule .* - [E=HTTP_AUTHORIZATION:%{HTTP:Authorization}]\n#\n# If the requested path and file is not /index.php and the request\n# has not already been internally rewritten to the index.php script\nRewriteCond %{REQUEST_URI} !^/index\\.php\n# and the requested path and file doesn't directly match a physical file\nRewriteCond %{REQUEST_FILENAME} !-f\n# and the requested path and file doesn't directly match a physical folder\nRewriteCond %{REQUEST_FILENAME} !-d\n# internally rewrite the request to the index.php script\nRewriteRule .* index.php [L]\n#\n## End - Joomla! core SEF Section.<hr /><sub>This comment was created with the <a href=\"https://github.com/joomla/jissues\">J!Tracker Application</a> at <a href=\"https://issues.joomla.org/tracker/joomla-cms/8573\">issues.joomla.org/joomla-cms/8573</a>.</sub>"}}