CVEfocus › CVE database › CVE-2020-7063

CVE-2020-7063Files added to tar with Phar::buildFromIterator have all-access permissions

CVSS 5.5 MediumEPSS 1.6% (higher than 76% of CVEs)Published 2020-02-27Updated 2024-09-16Assigner: php

In PHP versions 7.2.x below 7.2.28, 7.3.x below 7.3.15 and 7.4.x below 7.4.3, when creating PHAR archive using PharData::buildFromIterator() function, the files are added with default permissions (0666, or all access) even if the original files on the filesystem were with more restrictive permissions. This may result in files having more lax permissions than intended when such archive is extracted.

CWE-281

What to do

Fixed builds are available from AlmaLinux, Alpine, Red Hat, Rocky Linux, Ubuntu: see the table below for the fixed version per release.

Ubuntu has not shipped a fix for every release yet.

Is your server affected? One read-only command checks every installed package against this CVE and all others, using each vendor's fixed versions. Get started or get a free API key.

curl -sS "https://api.cvefocus.com/v1/check?format=text" -H "Authorization: Bearer $CVEFOCUS_KEY" \
  -H "Content-Type: text/plain" --data-binary @inventory.txt

Vendor status at a glance

89Fixed
1Fix pending
56Will not fix

Status by vendor and release

From each vendor's own security data and VEX statements. "Fixed" means a fixed build is published for that release.

ReleasePackageStatusFixed versionAdvisory
Ubuntu 18.04php7.2Fixed7.2.24-0ubuntu0.18.04.4UBUNTU-CVE-2020-7063
Ubuntu 16.04php7.0Fixed7.0.33-0ubuntu0.16.04.14UBUNTU-CVE-2020-7063
Ubuntu 14.04php5Fix pending5.5.9+dfsg-1ubuntu4.29+esm11 (Ubuntu Pro)UBUNTU-CVE-2020-7063
Red Hat Enterprise Linux 8apcu-panelFixed
Will not fix
0:5.1.17-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8libzipFixed
Will not fix
0:1.5.2-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8libzip-develFixed
Will not fix
0:1.5.2-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8libzip-toolsFixed
Will not fix
0:1.5.2-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8phpFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-bcmathFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-cliFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-commonFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-dbaFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-dbgFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-develFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-embeddedFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-enchantFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-ffiWill not fix
Will not fix
Red Hat Enterprise Linux 8php-fpmFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-gdFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-gmpFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-intlFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-jsonFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-ldapFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-mbstringFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-mysqlndFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-odbcFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-opcacheFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-pdoFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-pearFixed
Will not fix
1:1.10.9-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8php-pecl-apcuFixed
Will not fix
0:5.1.17-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8php-pecl-apcu-develFixed
Will not fix
0:5.1.17-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8php-pecl-rrdFixed
Will not fix
0:2.0.1-1.module+el8.2.0+4968+1d5097dbRHSA-2020:3662
Red Hat Enterprise Linux 8php-pecl-xdebugFixed
Will not fix
0:2.8.0-1.module+el8.2.0+4968+1d5097dbRHSA-2020:3662
Red Hat Enterprise Linux 8php-pecl-xdebug3Will not fix
Will not fix
Red Hat Enterprise Linux 8php-pecl-zipFixed
Will not fix
0:1.15.4-1.module+el8.1.0+3189+a1bff096RHSA-2020:3662
Red Hat Enterprise Linux 8php-pgsqlFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-processFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-recodeFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-snmpFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-soapFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-xmlFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 8php-xmlrpcFixed
Will not fix
0:7.3.20-1.module+el8.2.0+7373+b272fdefRHSA-2020:3662
Red Hat Enterprise Linux 7phpWill not fix
Will not fix
Red Hat Enterprise Linux 7php-bcmathWill not fix
Will not fix
Red Hat Enterprise Linux 7php-cliWill not fix
Will not fix
Red Hat Enterprise Linux 7php-commonWill not fix
Will not fix
Red Hat Enterprise Linux 7php-dbaWill not fix
Will not fix
Red Hat Enterprise Linux 7php-develWill not fix
Will not fix
Red Hat Enterprise Linux 7php-embeddedWill not fix
Will not fix
Red Hat Enterprise Linux 7php-enchantWill not fix
Will not fix
Red Hat Enterprise Linux 7php-fpmWill not fix
Will not fix
Red Hat Enterprise Linux 7php-gdWill not fix
Will not fix
Red Hat Enterprise Linux 7php-intlWill not fix
Will not fix
Red Hat Enterprise Linux 7php-ldapWill not fix
Will not fix
Red Hat Enterprise Linux 7php-mbstringWill not fix
Will not fix
Red Hat Enterprise Linux 7php-mysqlWill not fix
Will not fix
Red Hat Enterprise Linux 7php-mysqlndWill not fix
Will not fix
Red Hat Enterprise Linux 7php-odbcWill not fix
Will not fix
Red Hat Enterprise Linux 7php-pdoWill not fix
Will not fix
Red Hat Enterprise Linux 7php-pgsqlWill not fix
Will not fix
Red Hat Enterprise Linux 7php-processWill not fix
Will not fix
Red Hat Enterprise Linux 7php-pspellWill not fix
Will not fix
Red Hat Enterprise Linux 7php-recodeWill not fix
Will not fix
Red Hat Enterprise Linux 7php-snmpWill not fix
Will not fix
Red Hat Enterprise Linux 7php-soapWill not fix
Will not fix
Red Hat Enterprise Linux 7php-xmlWill not fix
Will not fix
Red Hat Enterprise Linux 7php-xmlrpcWill not fix
Will not fix
Red Hat Enterprise Linux 6phpWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-bcmathWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-cliWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-commonWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-dbaWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-develWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-embeddedWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-enchantWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-fpmWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-gdWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-imapWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-intlWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-ldapWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-mbstringWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-mysqlWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-odbcWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-pdoWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-pgsqlWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-processWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-pspellWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-recodeWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-snmpWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-soapWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-tidyWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-xmlWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-xmlrpcWill not fix
Out of support scope
Red Hat Enterprise Linux 6php-ztsWill not fix
Out of support scope
Red Hat Enterprise Linux 5phpWill not fix
Out of support scope
Red Hat Enterprise Linux 5php53Will not fix
Out of support scope
AlmaLinux 8apcu-panelFixed5.1.17-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8libzipFixed1.5.2-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8libzip-develFixed1.5.2-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8libzip-toolsFixed1.5.2-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8phpFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-bcmathFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-cliFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-commonFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-dbaFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-dbgFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-develFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-embeddedFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-enchantFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-fpmFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-gdFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-gmpFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-intlFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-jsonFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-ldapFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-mbstringFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-mysqlndFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-odbcFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-opcacheFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-pdoFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-pearFixed1:1.10.9-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-pecl-apcuFixed5.1.17-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-pecl-apcu-develFixed5.1.17-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-pecl-rrdFixed2.0.1-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-pecl-xdebugFixed2.8.0-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-pecl-zipFixed1.15.4-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-pgsqlFixed7.3.20-1.module_el8.3.0+2009+b272fdefALSA-2020:3662
AlmaLinux 8php-processFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-recodeFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
AlmaLinux 8php-snmpFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-soapFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-xmlFixed7.3.20-1.module_el8.5.0+152+112d3b8cALSA-2020:3662
AlmaLinux 8php-xmlrpcFixed7.3.20-1.module_el8.4.0+2229+b272fdefALSA-2020:3662
Rocky Linux 8libzipFixed0:1.5.2-1.module+el8.4.0+414+2e7afcddRLSA-2020:3662
Rocky Linux 8phpFixed0:7.3.20-1.module+el8.4.0+414+2e7afcddRLSA-2020:3662
Rocky Linux 8php-pearFixed1:1.10.9-1.module+el8.4.0+414+2e7afcddRLSA-2020:3662
Rocky Linux 8php-pecl-apcuFixed0:5.1.17-1.module+el8.4.0+414+2e7afcddRLSA-2020:3662
Rocky Linux 8php-pecl-rrdFixed0:2.0.1-1.module+el8.4.0+414+2e7afcddRLSA-2020:3662
Rocky Linux 8php-pecl-xdebugFixed0:2.8.0-1.module+el8.4.0+414+2e7afcddRLSA-2020:3662
Rocky Linux 8php-pecl-zipFixed0:1.15.4-1.module+el8.4.0+414+2e7afcddRLSA-2020:3662
Alpine Linux 3.15php7Fixed7.3.15-r0ALPINE-CVE-2020-7063
Alpine Linux 3.14php7Fixed7.3.15-r0ALPINE-CVE-2020-7063
Alpine Linux 3.13php7Fixed7.3.15-r0ALPINE-CVE-2020-7063
Alpine Linux 3.12php7Fixed7.3.15-r0ALPINE-CVE-2020-7063
Alpine Linux 3.11php7Fixed7.3.15-r0ALPINE-CVE-2020-7063
Alpine Linux 3.9php7Fixed7.2.31-r0ALPINE-CVE-2020-7063

What the vendor says

As published in the CVE record by php, the CVE's assigner (usually the vendor). Check the vendor's advisory before acting.

Workaround: Use different Phar class functions to compose the archive, such as addFile(), or reset file permissions upon extracting files from the archive.

Vendor advisories:

References

About this page

Compiled by CVEfocus from the CVE List, the security data and VEX statements of Ubuntu, Debian, Red Hat, AlmaLinux, Rocky Linux and Microsoft, CISA's Known Exploited Vulnerabilities catalog and FIRST EPSS, refreshed several times a day (data status). Information only; see the disclaimer. Official record: cve.org · NVD.