CWEweakness

CWE-825 Expired Pointer Dereference

Official page ↗
Alternate terms
Dangling pointer
Abstraction
Base
Structure
Simple
Status
Incomplete
Languages
C, C++, Memory-Unsafe
CWE version
5.0

Description

The product dereferences a pointer that contains a location for memory that was previously valid, but is no longer valid.

Common consequences

• Confidentiality: Read Memory — If the expired pointer is used in a read operation, an attacker might be able to control data read in by the application. • Availability: DoS: Crash, Exit, or Restart — If the expired pointer references a memory location that is not accessible to the product, or points to a location that is "malformed" (such as NULL) or larger than expected by a read or write operation, then a crash may occur. • Integrity, Confidentiality, Availability: Execute Unauthorized Code or Commands — If the expired pointer is used in a function call, or points to unexpected data in a write operation, then code execution may be possible.

Potential mitigations

• [Architecture and Design] Choose a language that provides automatic memory management. • [Implementation] When freeing pointers, be sure to set them to NULL once they are freed. However, the utilization of multiple or complex data structures may lower the usefulness of this strategy.

Detection methods

• Automated Static Analysis: Automated static analysis, commonly referred to as Static Application Security Testing (SAST), can find some instances of this weakness by analyzing source code (or binary/compiled code) without having to execute it. Typically, this is done by building a model of data flow and control flow, then searching for potentially-vulnerable patterns that connect "sources" (origins of input) with "sinks" (destinations where the data interacts with external components, a lower layer such as the OS, etc.) • Automated Dynamic Analysis: Use tools that are integrated during compilation to insert runtime error-checking mechanisms related to memory safety errors, such as AddressSanitizer (ASan) for C/C++ [REF-1518].

Observed examples

• CVE-2023-26463: Chain: IPSec VPN product uses the same variable for multiple purposes in the same function (CWE-1109), leading to incorrect access control (CWE-284) and expired pointer dereference (CWE-825) • CVE-2008-5013: access of expired memory address leads to arbitrary code execution • CVE-2010-3257: stale pointer issue leads to denial of service and possibly other consequences • CVE-2008-0062: Chain: a message having an unknown message type may cause a reference to uninitialized memory resulting in a null pointer dereference (CWE-476) or dangling pointer (CWE-825), possibly crashing the system or causing heap corruption. • CVE-2007-1211: read of value at an offset into a structure after the offset is no longer valid

Related

Observed example · CVE (5)

  • CVE-2023-26463 strongSwan 5.9.8 and 5.9.9 potentially allows remote code execution because it uses a variable named "public" for two different purposes… vulnerability
  • CVE-2010-3257 Use-after-free vulnerability in WebKit, as used in Apple Safari before 4.1.3 and 5.0.x before 5.0.3, Google Chrome before 6.0.472.53, and… vulnerability
  • CVE-2008-5013 Mozilla Firefox 2.x before 2.0.0.18 and SeaMonkey 1.x before 1.1.13 do not properly check when the Flash module has been dynamically… vulnerability
  • CVE-2008-0062 KDC in MIT Kerberos 5 (krb5kdc) does not set a global variable for some krb4 message types, which allows remote attackers to cause a denial… vulnerability
  • CVE-2007-1211 Unspecified kernel GDI functions in Microsoft Windows 2000 SP4; XP SP2; and Server 2003 Gold, SP1, and SP2 allows user-assisted remote… vulnerability

Can precede · CWE (2)

  • CWE-125 Out-of-bounds Read weakness
  • CWE-787 Out-of-bounds Write weakness

Child of · CWE (2)

  • CWE-119 Improper Restriction of Operations within the Bounds of a Memory Buffer weakness
  • CWE-672 Operation on a Resource after Expiration or Release weakness

Referenced by CVE · weakness (97)

  • CVE-2026-53918 odhcpd is the DHCPv6, DHCPv4, and router-advertisement server used by OpenWrt. vulnerability
  • CVE-2026-86845 A flaw was found in DPDK lib/vhost vhost-crypto. vulnerability
  • CVE-2026-19939 The AVDTP signalling layer arms a 6-second command timeout (AVDTP_TIMEOUT) in avdtp_send_cmd() whenever the local device issues an AVDTP… vulnerability
  • CVE-2026-104034 A flaw was found in SSSD. vulnerability
  • CVE-2026-104039 A flaw was found in SSSD. vulnerability
  • CVE-2026-102010 A flaw was found in GCC. vulnerability
  • CVE-2026-65970 OpenImageIO is a toolset for reading, writing, and manipulating image files of any image file format relevant to VFX / animation. vulnerability
  • CVE-2026-78123 strongSwan 5.0.2 through 6.0.7 has an Expired Pointer Dereference in PKCS#7 parsing in the openssl plugin. vulnerability
  • CVE-2026-77220 PDFio before 1.6.5 contains a dangling pointer vulnerability in the dictionary string-formatting function that stores a pointer to a… vulnerability
  • CVE-2026-76890 Crash in sharkd in 4.6.0 to 4.6.7 and 4.4.0 to 4.4.18 allows denial of service vulnerability
  • CVE-2026-76891 Crash in sharkd in 4.6.0 to 4.6.7 and 4.4.0 to 4.4.18 allows denial of service vulnerability
  • CVE-2026-10671 In Zephyr's kernel pipe implementation, the userspace syscall verifier z_vrfy_k_pipe_init() in kernel/pipe.c used K_SYSCALL_OBJ() (which… vulnerability
  • CVE-2026-54778 CoreWCF is a port of the service side of Windows Communication Foundation (WCF) to .NET Core. vulnerability
  • CVE-2026-58592 Ladybird before commit 2f9dc7e contains a dangling-reference memory-safety flaw in its WebAssembly ESM-integration module loader. vulnerability
  • CVE-2026-12610 A flaw was found in sssd. vulnerability
  • CVE-2026-53175 In the Linux kernel, the following vulnerability has been resolved: inet: frags: fix use-after-free caused by the fqdir_pre_exit() flush On… vulnerability
  • CVE-2026-57435 Nokogiri is an open source XML and HTML library for the Ruby programming language. vulnerability
  • CVE-2026-52923 In the Linux kernel, the following vulnerability has been resolved: ipc: limit next_id allocation to the valid ID range The… vulnerability
  • CVE-2026-52924 In the Linux kernel, the following vulnerability has been resolved: sctp: purge outqueue on stale COOKIE-ECHO handling sctp_stream_update()… vulnerability
  • CVE-2026-52950 In the Linux kernel, the following vulnerability has been resolved: drm/xe/dma-buf: fix UAF with retry loop Retry doesn't work here, since… vulnerability
  • CVE-2026-52952 In the Linux kernel, the following vulnerability has been resolved: iommu: Fix WARN_ON in __iommu_group_set_domain_nofail() due to reset In… vulnerability
  • CVE-2026-52973 In the Linux kernel, the following vulnerability has been resolved: futex: Drop CLONE_THREAD requirement for private default hash alloc… vulnerability
  • CVE-2026-52976 In the Linux kernel, the following vulnerability has been resolved: drm/xe: Fix error cleanup in xe_exec_queue_create_ioctl() Two error… vulnerability
  • CVE-2026-53006 In the Linux kernel, the following vulnerability has been resolved: ipv6: fix possible UAF in icmpv6_rcv() Caching saddr and daddr before… vulnerability
  • CVE-2026-53033 In the Linux kernel, the following vulnerability has been resolved: bpf, sockmap: Take state lock for af_unix iter When a BPF iterator… vulnerability
  • CVE-2026-53085 In the Linux kernel, the following vulnerability has been resolved: bpf: fix mm lifecycle in open-coded task_vma iterator The open-coded… vulnerability
  • CVE-2026-12291 Use-after-free in the Networking: HTTP component. vulnerability
  • CVE-2026-12293 Use-after-free in the Graphics: WebGPU component. vulnerability
  • CVE-2026-12326 Memory safety bugs present in Firefox 151 and Thunderbird 151. vulnerability
  • CVE-2026-12328 Memory safety bugs present in Firefox ESR 115.36, Firefox ESR 140.11, Thunderbird ESR 140.11, Firefox 151 and Thunderbird 151. vulnerability
Show all 97 ›

Referenced by CWE · can precede (1)

  • CWE-562 Return of Stack Variable Address weakness

Referenced by CWE · child of (2)

Referenced by CWE · has member (1)