{"action":"closed","number":6180,"pull_request":{"url":"https://api.github.com/repos/joomla/joomla-cms/pulls/6180","id":29995349,"html_url":"https://github.com/joomla/joomla-cms/pull/6180","diff_url":"https://github.com/joomla/joomla-cms/pull/6180.diff","patch_url":"https://github.com/joomla/joomla-cms/pull/6180.patch","issue_url":"https://api.github.com/repos/joomla/joomla-cms/issues/6180","number":6180,"state":"closed","locked":false,"title":"Fix #6173","user":{"login":"nikosdion","id":256041,"avatar_url":"https://avatars.githubusercontent.com/u/256041?v=3","gravatar_id":"","url":"https://api.github.com/users/nikosdion","html_url":"https://github.com/nikosdion","followers_url":"https://api.github.com/users/nikosdion/followers","following_url":"https://api.github.com/users/nikosdion/following{/other_user}","gists_url":"https://api.github.com/users/nikosdion/gists{/gist_id}","starred_url":"https://api.github.com/users/nikosdion/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikosdion/subscriptions","organizations_url":"https://api.github.com/users/nikosdion/orgs","repos_url":"https://api.github.com/users/nikosdion/repos","events_url":"https://api.github.com/users/nikosdion/events{/privacy}","received_events_url":"https://api.github.com/users/nikosdion/received_events","type":"User","site_admin":false},"body":"Reference: gh-6173 J3.4.0 cannot install certain extensions\r\n\r\n## Executive summary\r\n\r\nAn oversight in com_installer caused erroneous scanning of uploaded extension package files for raw PHP code inclusion and rejected them for this reason. This should not happen because installation packages are *supposed* to have executable PHP code by their very definition. This only happens with certain packages which have the string `<?` or `<?php` in them.\r\n\r\n## Test instructions\r\n\r\nIf you have an affected package, try installing it in vanilla Joomla! 3.4.0 using the Upload & Install method. The upload fails.\r\n\r\nApply the patch, retry installing the package. It now works.\r\n\r\n## Technical explanation\r\n\r\nJFile::upload was missing the fourth argument, resulting in file content scanning for ZIP file per the default options. Since installation package ZIP files may contain uncompressed .php files OR otherwise the string literals `<?` and `<?php` the upload was rejected. However, installation packages are *supposed* to contain executable code, therefore we should not pass them through the safe file (UploadShield) code.\r\n\r\n Moreover, this patch adds an optional fifth parameter to JFile::upload to allow developers to pass custom options to the safe file scanning (UploadShield) code, as was the original intention of the UploadShield feature when it was committed two years ago but lost during the refactoring for inclusion in Joomla! 3.4.\r\n\r\n Finally, the docblock for isSafeFile was reformatted for improved clarity of the parameters which can be passed to UploadShield.\r\n\r\n## Backwards compatibility\r\n\r\nThis patch is backwards compatible.\r\n\r\n## Translation impact\r\n\r\nNone","created_at":"2015-02-25T15:23:02Z","updated_at":"2015-02-26T09:13:00Z","closed_at":"2015-02-26T09:13:00Z","merged_at":"2015-02-26T09:13:00Z","merge_commit_sha":"b06a2d16b739a2ce2a35d749321da5f76ef76060","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/joomla/joomla-cms/pulls/6180/commits","review_comments_url":"https://api.github.com/repos/joomla/joomla-cms/pulls/6180/comments","review_comment_url":"https://api.github.com/repos/joomla/joomla-cms/pulls/comments{/number}","comments_url":"https://api.github.com/repos/joomla/joomla-cms/issues/6180/comments","statuses_url":"https://api.github.com/repos/joomla/joomla-cms/statuses/93ebe41bffeb1a31c91aa0e447d9e251d6c50356","head":{"label":"nikosdion:fix/6173-uploadshield-and-installer","ref":"fix/6173-uploadshield-and-installer","sha":"93ebe41bffeb1a31c91aa0e447d9e251d6c50356","user":{"login":"nikosdion","id":256041,"avatar_url":"https://avatars.githubusercontent.com/u/256041?v=3","gravatar_id":"","url":"https://api.github.com/users/nikosdion","html_url":"https://github.com/nikosdion","followers_url":"https://api.github.com/users/nikosdion/followers","following_url":"https://api.github.com/users/nikosdion/following{/other_user}","gists_url":"https://api.github.com/users/nikosdion/gists{/gist_id}","starred_url":"https://api.github.com/users/nikosdion/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikosdion/subscriptions","organizations_url":"https://api.github.com/users/nikosdion/orgs","repos_url":"https://api.github.com/users/nikosdion/repos","events_url":"https://api.github.com/users/nikosdion/events{/privacy}","received_events_url":"https://api.github.com/users/nikosdion/received_events","type":"User","site_admin":false},"repo":{"id":3344617,"name":"joomla-cms","full_name":"nikosdion/joomla-cms","owner":{"login":"nikosdion","id":256041,"avatar_url":"https://avatars.githubusercontent.com/u/256041?v=3","gravatar_id":"","url":"https://api.github.com/users/nikosdion","html_url":"https://github.com/nikosdion","followers_url":"https://api.github.com/users/nikosdion/followers","following_url":"https://api.github.com/users/nikosdion/following{/other_user}","gists_url":"https://api.github.com/users/nikosdion/gists{/gist_id}","starred_url":"https://api.github.com/users/nikosdion/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/nikosdion/subscriptions","organizations_url":"https://api.github.com/users/nikosdion/orgs","repos_url":"https://api.github.com/users/nikosdion/repos","events_url":"https://api.github.com/users/nikosdion/events{/privacy}","received_events_url":"https://api.github.com/users/nikosdion/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/nikosdion/joomla-cms","description":"Home of the Joomla! Content Management System","fork":true,"url":"https://api.github.com/repos/nikosdion/joomla-cms","forks_url":"https://api.github.com/repos/nikosdion/joomla-cms/forks","keys_url":"https://api.github.com/repos/nikosdion/joomla-cms/keys{/key_id}","collaborators_url":"https://api.github.com/repos/nikosdion/joomla-cms/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/nikosdion/joomla-cms/teams","hooks_url":"https://api.github.com/repos/nikosdion/joomla-cms/hooks","issue_events_url":"https://api.github.com/repos/nikosdion/joomla-cms/issues/events{/number}","events_url":"https://api.github.com/repos/nikosdion/joomla-cms/events","assignees_url":"https://api.github.com/repos/nikosdion/joomla-cms/assignees{/user}","branches_url":"https://api.github.com/repos/nikosdion/joomla-cms/branches{/branch}","tags_url":"https://api.github.com/repos/nikosdion/joomla-cms/tags","blobs_url":"https://api.github.com/repos/nikosdion/joomla-cms/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/nikosdion/joomla-cms/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/nikosdion/joomla-cms/git/refs{/sha}","trees_url":"https://api.github.com/repos/nikosdion/joomla-cms/git/trees{/sha}","statuses_url":"https://api.github.com/repos/nikosdion/joomla-cms/statuses/{sha}","languages_url":"https://api.github.com/repos/nikosdion/joomla-cms/languages","stargazers_url":"https://api.github.com/repos/nikosdion/joomla-cms/stargazers","contributors_url":"https://api.github.com/repos/nikosdion/joomla-cms/contributors","subscribers_url":"https://api.github.com/repos/nikosdion/joomla-cms/subscribers","subscription_url":"https://api.github.com/repos/nikosdion/joomla-cms/subscription","commits_url":"https://api.github.com/repos/nikosdion/joomla-cms/commits{/sha}","git_commits_url":"https://api.github.com/repos/nikosdion/joomla-cms/git/commits{/sha}","comments_url":"https://api.github.com/repos/nikosdion/joomla-cms/comments{/number}","issue_comment_url":"https://api.github.com/repos/nikosdion/joomla-cms/issues/comments{/number}","contents_url":"https://api.github.com/repos/nikosdion/joomla-cms/contents/{+path}","compare_url":"https://api.github.com/repos/nikosdion/joomla-cms/compare/{base}...{head}","merges_url":"https://api.github.com/repos/nikosdion/joomla-cms/merges","archive_url":"https://api.github.com/repos/nikosdion/joomla-cms/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/nikosdion/joomla-cms/downloads","issues_url":"https://api.github.com/repos/nikosdion/joomla-cms/issues{/number}","pulls_url":"https://api.github.com/repos/nikosdion/joomla-cms/pulls{/number}","milestones_url":"https://api.github.com/repos/nikosdion/joomla-cms/milestones{/number}","notifications_url":"https://api.github.com/repos/nikosdion/joomla-cms/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/nikosdion/joomla-cms/labels{/name}","releases_url":"https://api.github.com/repos/nikosdion/joomla-cms/releases{/id}","created_at":"2012-02-03T13:28:55Z","updated_at":"2014-08-07T20:05:36Z","pushed_at":"2015-02-26T07:33:41Z","git_url":"git://github.com/nikosdion/joomla-cms.git","ssh_url":"git@github.com:nikosdion/joomla-cms.git","clone_url":"https://github.com/nikosdion/joomla-cms.git","svn_url":"https://github.com/nikosdion/joomla-cms","homepage":"http://joomla.org","size":124116,"stargazers_count":1,"watchers_count":1,"language":"PHP","has_issues":false,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"joomla:staging","ref":"staging","sha":"b91f0384aa77c07cf92c586f92bac12f73a510f8","user":{"login":"joomla","id":751633,"avatar_url":"https://avatars.githubusercontent.com/u/751633?v=3","gravatar_id":"","url":"https://api.github.com/users/joomla","html_url":"https://github.com/joomla","followers_url":"https://api.github.com/users/joomla/followers","following_url":"https://api.github.com/users/joomla/following{/other_user}","gists_url":"https://api.github.com/users/joomla/gists{/gist_id}","starred_url":"https://api.github.com/users/joomla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joomla/subscriptions","organizations_url":"https://api.github.com/users/joomla/orgs","repos_url":"https://api.github.com/users/joomla/repos","events_url":"https://api.github.com/users/joomla/events{/privacy}","received_events_url":"https://api.github.com/users/joomla/received_events","type":"Organization","site_admin":false},"repo":{"id":2464908,"name":"joomla-cms","full_name":"joomla/joomla-cms","owner":{"login":"joomla","id":751633,"avatar_url":"https://avatars.githubusercontent.com/u/751633?v=3","gravatar_id":"","url":"https://api.github.com/users/joomla","html_url":"https://github.com/joomla","followers_url":"https://api.github.com/users/joomla/followers","following_url":"https://api.github.com/users/joomla/following{/other_user}","gists_url":"https://api.github.com/users/joomla/gists{/gist_id}","starred_url":"https://api.github.com/users/joomla/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/joomla/subscriptions","organizations_url":"https://api.github.com/users/joomla/orgs","repos_url":"https://api.github.com/users/joomla/repos","events_url":"https://api.github.com/users/joomla/events{/privacy}","received_events_url":"https://api.github.com/users/joomla/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/joomla/joomla-cms","description":"Home of the Joomla! Content Management System","fork":false,"url":"https://api.github.com/repos/joomla/joomla-cms","forks_url":"https://api.github.com/repos/joomla/joomla-cms/forks","keys_url":"https://api.github.com/repos/joomla/joomla-cms/keys{/key_id}","collaborators_url":"https://api.github.com/repos/joomla/joomla-cms/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/joomla/joomla-cms/teams","hooks_url":"https://api.github.com/repos/joomla/joomla-cms/hooks","issue_events_url":"https://api.github.com/repos/joomla/joomla-cms/issues/events{/number}","events_url":"https://api.github.com/repos/joomla/joomla-cms/events","assignees_url":"https://api.github.com/repos/joomla/joomla-cms/assignees{/user}","branches_url":"https://api.github.com/repos/joomla/joomla-cms/branches{/branch}","tags_url":"https://api.github.com/repos/joomla/joomla-cms/tags","blobs_url":"https://api.github.com/repos/joomla/joomla-cms/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/joomla/joomla-cms/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/joomla/joomla-cms/git/refs{/sha}","trees_url":"https://api.github.com/repos/joomla/joomla-cms/git/trees{/sha}","statuses_url":"https://api.github.com/repos/joomla/joomla-cms/statuses/{sha}","languages_url":"https://api.github.com/repos/joomla/joomla-cms/languages","stargazers_url":"https://api.github.com/repos/joomla/joomla-cms/stargazers","contributors_url":"https://api.github.com/repos/joomla/joomla-cms/contributors","subscribers_url":"https://api.github.com/repos/joomla/joomla-cms/subscribers","subscription_url":"https://api.github.com/repos/joomla/joomla-cms/subscription","commits_url":"https://api.github.com/repos/joomla/joomla-cms/commits{/sha}","git_commits_url":"https://api.github.com/repos/joomla/joomla-cms/git/commits{/sha}","comments_url":"https://api.github.com/repos/joomla/joomla-cms/comments{/number}","issue_comment_url":"https://api.github.com/repos/joomla/joomla-cms/issues/comments{/number}","contents_url":"https://api.github.com/repos/joomla/joomla-cms/contents/{+path}","compare_url":"https://api.github.com/repos/joomla/joomla-cms/compare/{base}...{head}","merges_url":"https://api.github.com/repos/joomla/joomla-cms/merges","archive_url":"https://api.github.com/repos/joomla/joomla-cms/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/joomla/joomla-cms/downloads","issues_url":"https://api.github.com/repos/joomla/joomla-cms/issues{/number}","pulls_url":"https://api.github.com/repos/joomla/joomla-cms/pulls{/number}","milestones_url":"https://api.github.com/repos/joomla/joomla-cms/milestones{/number}","notifications_url":"https://api.github.com/repos/joomla/joomla-cms/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/joomla/joomla-cms/labels{/name}","releases_url":"https://api.github.com/repos/joomla/joomla-cms/releases{/id}","created_at":"2011-09-27T02:07:38Z","updated_at":"2015-02-26T06:27:27Z","pushed_at":"2015-02-26T09:13:00Z","git_url":"git://github.com/joomla/joomla-cms.git","ssh_url":"git@github.com:joomla/joomla-cms.git","clone_url":"https://github.com/joomla/joomla-cms.git","svn_url":"https://github.com/joomla/joomla-cms","homepage":"http://joomla.org","size":305044,"stargazers_count":1453,"watchers_count":1453,"language":"PHP","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":1611,"mirror_url":null,"open_issues_count":551,"forks":1611,"open_issues":551,"watchers":1453,"default_branch":"staging"}},"_links":{"self":{"href":"https://api.github.com/repos/joomla/joomla-cms/pulls/6180"},"html":{"href":"https://github.com/joomla/joomla-cms/pull/6180"},"issue":{"href":"https://api.github.com/repos/joomla/joomla-cms/issues/6180"},"comments":{"href":"https://api.github.com/repos/joomla/joomla-cms/issues/6180/comments"},"review_comments":{"href":"https://api.github.com/repos/joomla/joomla-cms/pulls/6180/comments"},"review_comment":{"href":"https://api.github.com/repos/joomla/joomla-cms/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/joomla/joomla-cms/pulls/6180/commits"},"statuses":{"href":"https://api.github.com/repos/joomla/joomla-cms/statuses/93ebe41bffeb1a31c91aa0e447d9e251d6c50356"}},"merged":true,"mergeable":null,"mergeable_state":"unknown","merged_by":{"login":"Kubik-Rubik","id":1976103,"avatar_url":"https://avatars.githubusercontent.com/u/1976103?v=3","gravatar_id":"","url":"https://api.github.com/users/Kubik-Rubik","html_url":"https://github.com/Kubik-Rubik","followers_url":"https://api.github.com/users/Kubik-Rubik/followers","following_url":"https://api.github.com/users/Kubik-Rubik/following{/other_user}","gists_url":"https://api.github.com/users/Kubik-Rubik/gists{/gist_id}","starred_url":"https://api.github.com/users/Kubik-Rubik/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Kubik-Rubik/subscriptions","organizations_url":"https://api.github.com/users/Kubik-Rubik/orgs","repos_url":"https://api.github.com/users/Kubik-Rubik/repos","events_url":"https://api.github.com/users/Kubik-Rubik/events{/privacy}","received_events_url":"https://api.github.com/users/Kubik-Rubik/received_events","type":"User","site_admin":false},"comments":4,"review_comments":2,"commits":3,"additions":19,"deletions":16,"changed_files":4}}