Every CVE Search/ Get API key

CVE-2018-12882

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a...

9.8 CriticalFix available

CVE-2018-12882 is a critical vulnerability (CVSS 9.8) in Php, published June 25, 2018. No source lists public exploit code. EPSS puts the chance of exploitation in the next 30 days at 6.48%, the 93rd percentile. Fixed in php7 7.0.7-50.41.1.

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a use-after-free (in exif_read_from_file) because it closes a stream that it is not responsible for closing. The vulnerable code is reachable through the PHP exif_read_data function.

Attack profile

How easy it is to exploit

Attack vector
Network
Complexity
Low
Privileges needed
None
User interaction
None

What an attacker can affect

Confidentiality
High
Integrity
High
Availability
High

Exploit likelihood

6.48%Up 5.2 points since Apr 14, 2021
90%50%10%1%

What each source reports

NVD Score used 9.8

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a use-after-free (in exif_read_from_file) because it closes a stream that it is not responsible for closing. The vulnerable code is reachable through the PHP exif_read_data function.

Record
CVE-2018-12882
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
CVSS 2.0
7.5 HighAV:N/AC:L/Au:N/C:P/I:P/A:P
Weakness
CWE-416
Updated
2026-11-02
CVE List No score

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a use-after-free (in exif_read_from_file) because it closes a stream that it is not responsible for closing. The vulnerable code is reachable through the PHP exif_read_data function.

Record
CVE-2018-12882
Updated
2026-11-02
EUVDEUVD-2018-4835 No score

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a use-after-free (in exif_read_from_file) because it closes a stream that it is not responsible for closing. The vulnerable code is reachable through the PHP exif_read_data function.

Record
EUVD-2018-4835
Updated
2026-11-03
GitHub AdvisoriesGHSA-p666-3cc6-g2c6 9.8

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a...

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a use-after-free (in exif_read_from_file) because it closes a stream that it is not responsible for closing. The vulnerable code is reachable through the PHP exif_read_data function.

Record
GHSA-p666-3cc6-g2c6
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Weakness
CWE-416
Updated
2026-11-02
OSV 9.8

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a use-after-free (in exif_read_from_file) because it closes a stream that it is not responsible for closing. The vulnerable code is reachable through the PHP exif_read_data function.

Record
CVE-2018-12882
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Updated
2026-11-02
OSVUBUNTU-CVE-2018-12882 9.8

exif_read_from_impl in ext/exif/exif.c in PHP 7.2.x through 7.2.7 allows attackers to trigger a use-after-free (in exif_read_from_file) because it closes a stream that it is not responsible for closing. The vulnerable code is reachable through the PHP exif_read_data function.

Record
UBUNTU-CVE-2018-12882
CVSS 3.0
9.8 CriticalCVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H
Updated
2026-11-02
Show 10 moreShow less
OSVopenSUSE-SU-2024:11167-1 No score

php7-7.4.24-1.1 on GA media

These are all security issues fixed in the php7-7.4.24-1.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:11167-1
Updated
2026-11-02
OSVopenSUSE-SU-2024:11169-1 No score

php8-8.0.11-1.1 on GA media

These are all security issues fixed in the php8-8.0.11-1.1 package on the GA media of openSUSE Tumbleweed.

Record
openSUSE-SU-2024:11169-1
Updated
2026-11-02
OSVSUSE-SU-2018:1886-1 No score

Security update for php7

This update for php7 fixes the following issues:

  • CVE-2018-12882: exif_read_from_impl allowed attackers to trigger a use-after-free (in exif_read_from_file) because it closed a stream that it is not responsible for closing (bsc#1099098)
Record
SUSE-SU-2018:1886-1
Updated
2026-11-02
OSVSUSE-SU-2018:1936-1 No score

Security update for php7

This update for php7 fixes the following issues:

  • CVE-2018-12882: exif_read_from_impl allowed attackers to trigger a use-after-free (in exif_read_from_file) because it closed a stream that it is not responsible for closing (bsc#1099098).
Record
SUSE-SU-2018:1936-1
Updated
2026-11-02
OSVSUSE-SU-2018:1936-2 No score

Security update for php7

This update for php7 fixes the following issues:

  • CVE-2018-12882: exif_read_from_impl allowed attackers to trigger a use-after-free (in exif_read_from_file) because it closed a stream that it is not responsible for closing (bsc#1099098).
Record
SUSE-SU-2018:1936-2
Updated
2026-11-02
OSVSUSE-SU-2018:2044-1 No score

Security update for php53

This update for php53 fixes the following issues:

The following security issue was fixed:

  • An out-of-bounds read in the do_core_note function in readelf.c in libmagic.a allowed remote attackers to cause a denial of service via a crafted ELF file (CVE-2018-10360, bsc#1096984)
  • CVE-2018-12882: exif_read_from_impl allowed attackers to trigger a use-after-free (in exif_read_from_file) because it closed a stream that it is not responsible for closing (bsc#1099098)
Record
SUSE-SU-2018:2044-1
Updated
2026-11-02
OSVSUSE-SU-2018:2682-1 No score

Security update for php5

This update for php5 fixes the following issues:

The following security issues were fixed:

  • CVE-2018-10360: Fixed an out-of-bounds read in the do_core_note function in readelf.c in libmagic.a, which allowed remote attackers to cause a denial of service via a crafted ELF file (bsc#1096984)
  • CVE-2018-14851: Fixed an out-of-bound read in exif_process_IFD_in_MAKERNOTE, which could be exploited by an attacker via crafted JPG files, and could result in an application crash. (bsc#1103659)
  • CVE-2018-12882: Fixed an use-after-free in exif_read_from_impl in ext/exif/exif.c (bsc#1099098)
  • CVE-2017-9118: Fixed an out of bounds access in php_pcre_replace_impl via a crafted preg_replace call (bsc#1105466)
Record
SUSE-SU-2018:2682-1
Updated
2026-11-02
OSVSUSE-SU-2022:4067-1 No score

Security update for php7

This update for php7 fixes the following issues:

  • Version update to 7.2.34 [jsc#SLE-23639]

  • CVE-2022-37454: Fixed SHA-3 buffer overflow (bsc#1204577).

  • Fix integer overflow in PHP_SHA3##bits (bsc#1204577#c26).

Record
SUSE-SU-2022:4067-1
Updated
2026-11-02
OSVUSN-3702-1 No score

php7.2 vulnerability

It was discovered that PHP incorrectly handled exif tags in certain images. A remote attacker could use this issue to cause PHP to crash, resulting in a denial of service, or possibly execute arbitrary code.

Record
USN-3702-1
Updated
2026-11-02
OSVUSN-3702-2 No score

php7.2 vulnerability

USN-3702-1 fixed a vulnerability in PHP. PHP 7.2.7 did not actually include the fix for CVE-2018-12882. This update adds a backported patch to correct the issue.

We apologize for the inconvenience.

Original advisory details:

It was discovered that PHP incorrectly handled exif tags in certain images. A remote attacker could use this issue to cause PHP to crash, resulting in a denial of service, or possibly execute arbitrary code.

Record
USN-3702-2
Updated
2026-11-02

Affected products

Affected packages

Affected packages
PackageAffectedFixed
php7
SUSE:Linux Enterprise Module for Web and Scripting 12
before 7.0.7-50.41.1
7.0.7-50.41.1
php7
SUSE:Linux Enterprise Software Development Kit 12 SP3
before 7.0.7-50.41.1
7.0.7-50.41.1
php7
SUSE:Linux Enterprise Module for Web and Scripting 15
before 7.2.5-4.3.1
7.2.5-4.3.1
php53
SUSE:Linux Enterprise Software Development Kit 11 SP4
before 5.3.17-112.28.1
5.3.17-112.28.1
php53
SUSE:Linux Enterprise Server 11 SP4
before 5.3.17-112.28.1
5.3.17-112.28.1
php53
SUSE:Linux Enterprise Server for SAP Applications 11 SP4
before 5.3.17-112.28.1
5.3.17-112.28.1
php5
SUSE:Linux Enterprise Module for Web and Scripting 12
before 5.5.14-109.38.1
5.5.14-109.38.1
php5
SUSE:Linux Enterprise Software Development Kit 12 SP3
before 5.5.14-109.38.1
5.5.14-109.38.1
php7
SUSE:Linux Enterprise High Performance Computing 15-ESPOS
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Linux Enterprise High Performance Computing 15-LTSS
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
Show 13 moreShow less
Affected packages
PackageAffectedFixed
php7
SUSE:Linux Enterprise High Performance Computing 15 SP1-ESPOS
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Linux Enterprise High Performance Computing 15 SP1-LTSS
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Linux Enterprise Server 15-LTSS
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Linux Enterprise Server 15 SP1-BCL
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Linux Enterprise Server 15 SP1-LTSS
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Linux Enterprise Server for SAP Applications 15
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Linux Enterprise Server for SAP Applications 15 SP1
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
SUSE:Enterprise Storage 6
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7
openSUSE:Leap 15.4
before 7.2.34-150000.4.103.1
7.2.34-150000.4.103.1
php7.2
Ubuntu:18.04:LTS
before 7.2.7-0ubuntu0.18.04.2, plus listed versions
7.2.1-1ubuntu27.2.2-1ubuntu17.2.2-1ubuntu27.2.3-1ubuntu17.2.5-0ubuntu0.18.04.17.2.7-0ubuntu0.18.04.1
7.2.7-0ubuntu0.18.04.2
php7.2
Ubuntu:18.04:LTS
before 7.2.7-0ubuntu0.18.04.1, plus listed versions
7.2.1-1ubuntu27.2.2-1ubuntu17.2.2-1ubuntu27.2.3-1ubuntu17.2.5-0ubuntu0.18.04.1
7.2.7-0ubuntu0.18.04.1
php7
openSUSE:Tumbleweed
before 7.4.24-1.1
7.4.24-1.1
php8
openSUSE:Tumbleweed
before 8.0.11-1.1
8.0.11-1.1

History

History
WhenChangedSources
2026-11-03aliasesEUVD
2026-11-02createdCVE List, GitHub Advisories, NVD, OSV

References

Show 139 moreShow less
MoveEnter Open