CWE-400
Weakness DiscouragedUncontrolled Resource Consumption
Abstraction: Class · Status: Draft
The product does not properly control the allocation and maintenance of a limited resource.
Dimensions
- Behavior-Property: Uncontrolled
- Behavior-Type: Consumption
- Resource-Type: Resource
Mapping guidance
CWE-400 is intended for incorrect behaviors in which the product is expected to track and restrict how many resources it consumes, but CWE-400 is often misused because it is conflated with the "technical impact" of vulnerabilities in which resource consumption occurs. It is sometimes used for low-information vulnerability reports. It is a level-1 Class (i.e., a child of a Pillar).
Closely analyze the specific mistake that is causing resource consumption, and perform a CWE mapping for that mistake. Consider children/descendants.
Modes of introduction
The product could be operated in a system or environment with lower resource limits than expected, which might make it easier for attackers to consume all available resources.
The product could be configured with lower resource limits than expected, which might make it easier for attackers to consume all available resources.
The designer might not consider how to handle and throttle excessive resource requests, which typically requires careful planning to handle more gracefully than a crash or exit.
There are at least three distinct scenarios that can commonly lead to resource exhaustion:
Lack of throttling for the number of allocated resources.
Losing all references to a resource before reaching the shutdown stage.
Not closing/returning a resource after processing.
Resource exhaustion problems often occur due to an incorrect implementation of the following situations:
Error conditions and other exceptional circumstances.
Confusion over which part of the program is responsible for releasing the resource.
Detection methods
Automated Static Analysis
Automated static analysis typically has limited utility in recognizing resource exhaustion problems, except for program-independent system resources such as files, sockets, and processes. For system resources, automated static analysis may be able to detect circumstances in which resources are not released after they have expired. Automated analysis of configuration files may be able to detect settings that do not specify a maximum value.
Automated static analysis tools will not be appropriate for detecting exhaustion of custom resources, such as an intended security policy in which a bulletin board user is only allowed to make a limited number of posts per day.
Effectiveness: Limited
Automated Dynamic Analysis
Certain automated dynamic analysis techniques may be effective in spotting resource exhaustion problems, especially with resources such as processes, memory, and connections. The technique may involve generating a large number of requests to the product within a short time frame.
Effectiveness: Moderate
Fuzzing
While fuzzing is typically geared toward finding low-level implementation bugs, it can inadvertently find resource exhaustion problems. This can occur when the fuzzer generates a large number of test cases but does not restart the targeted product in between test cases. If an individual test case produces a crash, but it does not do so reliably, then an inability to handle resource exhaustion may be the cause.
Effectiveness: Opportunistic
Notes
Theoretical
Vulnerability theory is largely about how behaviors and resources interact. "Resource exhaustion" can be regarded as either a consequence or an attack, depending on the perspective. This entry is an attempt to reflect the underlying weaknesses that enable these attacks (or consequences) to take place.
Other
Database queries that take a long time to process are good DoS targets. An attacker would have to write a few lines of code to generate enough traffic to exceed the site's ability to keep up. This would effectively prevent authorized users from using the site at all. Resources can be exploited simply by ensuring that the target machine must do much more work and consume more resources in order to service a request than the attacker must do to initiate a request.
A prime example of this can be found in old switches that were vulnerable to "macof" attacks (so named for a tool developed by Dugsong). These attacks flooded a switch with random IP and MAC address combinations, therefore exhausting the switch's cache, which held the information of which port corresponded to which MAC addresses. Once this cache was exhausted, the switch would fail in an insecure way and would begin to act simply as a hub, broadcasting all traffic on all ports and allowing for basic sniffing attacks.
Limited resources include memory, file system storage, database connection pool entries, CPU, and others.
Content history
Suggested mappings to ISA/IEC 62443.
Suggested mappings to ISA/IEC 62443.
Provided diagram to improve CWE usability.
updated Time_of_Introduction
Suggested OWASP Top Ten 2004 mapping
updated Common_Consequences, Relationships, Other_Notes, Taxonomy_Mappings
updated Description, Name, Relationships
updated Description
updated Name, Relationships
updated Description, Relationships
updated Relationships
updated Common_Consequences, Demonstrative_Examples, Detection_Factors, Likelihood_of_Exploit, Observed_Examples, Other_Notes, Potential_Mitigations, References
updated Detection_Factors, Potential_Mitigations, References, Taxonomy_Mappings
updated Related_Attack_Patterns
updated Description
updated Demonstrative_Examples
updated Common_Consequences, Relationships, Taxonomy_Mappings
updated Demonstrative_Examples, Related_Attack_Patterns, Relationships, Taxonomy_Mappings
updated Relationships
updated Relationships, Taxonomy_Mappings
updated Related_Attack_Patterns, Relationships
updated Relationships
updated Applicable_Platforms, Demonstrative_Examples, Likelihood_of_Exploit, Potential_Mitigations, References, Relationships
updated References, Type
updated Alternate_Terms, Description, Name, Relationships, Taxonomy_Mappings, Theoretical_Notes
updated Related_Attack_Patterns, Relationships
updated Description, Relationships
updated Description, References, Related_Attack_Patterns, Relationships
updated Description, Maintenance_Notes
updated Relationships
updated Related_Attack_Patterns
updated Observed_Examples, Relationships
updated Observed_Examples, Relationships
updated Common_Consequences, Description, Detection_Factors, Maintenance_Notes, Related_Attack_Patterns, Taxonomy_Mappings
updated Demonstrative_Examples, Relationships, Taxonomy_Mappings
updated Mapping_Notes, Relationships
updated Relationships
updated Common_Consequences, Description, Diagram, Modes_of_Introduction, Other_Notes, Time_of_Introduction
updated Observed_Examples, References
updated Applicable_Platforms, Maintenance_Notes, Weakness_Ordinalities
updated Applicable_Platforms, Maintenance_Notes, Mapping_Notes, Other_Notes
updated Applicable_Platforms, Dimensions, References, Relationships, Taxonomy_Mappings
7207 vulnerabilities reference this CWE, most recent first.
GHSA-4MCP-5QPC-WGF8
Vulnerability from github – Published: 2023-12-20 12:30 – Updated: 2026-02-23 09:31A vulnerable API method in M-Files Server before 23.12.13195.0 allows for uncontrolled resource consumption. Authenticated attacker can exhaust server storage space to a point where the server can no longer serve requests.
{
"affected": [],
"aliases": [
"CVE-2023-6910"
],
"database_specific": {
"cwe_ids": [
"CWE-400",
"CWE-770"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2023-12-20T10:15:08Z",
"severity": "MODERATE"
},
"details": "A vulnerable API method in M-Files Server before 23.12.13195.0 allows for uncontrolled resource consumption. Authenticated attacker can exhaust server storage space to a point where the server can no longer serve requests.",
"id": "GHSA-4mcp-5qpc-wgf8",
"modified": "2026-02-23T09:31:18Z",
"published": "2023-12-20T12:30:26Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2023-6910"
},
{
"type": "WEB",
"url": "https://empower.m-files.com/security-advisories/CVE-2023-6910"
},
{
"type": "WEB",
"url": "https://product.m-files.com/security-advisories/cve-2023-6910"
},
{
"type": "WEB",
"url": "https://www.m-files.com/about/trust-center/security-advisories/cve-2023-6910"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:L/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-4MCP-J554-P27J
Vulnerability from github – Published: 2022-05-17 02:31 – Updated: 2022-05-17 02:31The regex code in Webkit 2.4.11 allows remote attackers to cause a denial of service (memory consumption) as demonstrated in a large number of ($ (open parenthesis and dollar) followed by {-2,16} and a large number of +) (plus close parenthesis).
{
"affected": [],
"aliases": [
"CVE-2016-9643"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-03-07T16:59:00Z",
"severity": "HIGH"
},
"details": "The regex code in Webkit 2.4.11 allows remote attackers to cause a denial of service (memory consumption) as demonstrated in a large number of ($ (open parenthesis and dollar) followed by {-2,16} and a large number of +) (plus close parenthesis).",
"id": "GHSA-4mcp-j554-p27j",
"modified": "2022-05-17T02:31:09Z",
"published": "2022-05-17T02:31:09Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2016-9643"
},
{
"type": "WEB",
"url": "https://security.gentoo.org/glsa/201706-15"
},
{
"type": "WEB",
"url": "http://www.openwall.com/lists/oss-security/2016/11/26/2"
},
{
"type": "WEB",
"url": "http://www.openwall.com/lists/oss-security/2016/11/26/5"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/94559"
},
{
"type": "WEB",
"url": "http://www.securitytracker.com/id/1038137"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-4MFW-X7WQ-V7GW
Vulnerability from github – Published: 2022-06-03 00:00 – Updated: 2022-06-12 00:00Dell PowerStore contains an Uncontrolled Resource Consumption Vulnerability in PowerStore User Interface. A remote unauthenticated attacker could potentially exploit this vulnerability, leading to the Denial of Service.
{
"affected": [],
"aliases": [
"CVE-2022-22556"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2022-06-02T21:15:00Z",
"severity": "HIGH"
},
"details": "Dell PowerStore contains an Uncontrolled Resource Consumption Vulnerability in PowerStore User Interface. A remote unauthenticated attacker could potentially exploit this vulnerability, leading to the Denial of Service.",
"id": "GHSA-4mfw-x7wq-v7gw",
"modified": "2022-06-12T00:00:47Z",
"published": "2022-06-03T00:00:29Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-22556"
},
{
"type": "WEB",
"url": "https://www.dell.com/support/kbdoc/000196367"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-4MX5-H7CQ-WHF6
Vulnerability from github – Published: 2022-05-24 17:40 – Updated: 2022-05-24 17:40IBM MQ Internet Pass-Thru 2.1 and 9.2 could allow a remote user to cause a denial of service by sending malformed MQ data requests which would consume all available resources. IBM X-Force ID: 188093.
{
"affected": [],
"aliases": [
"CVE-2020-4766"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2021-01-22T17:15:00Z",
"severity": "HIGH"
},
"details": "IBM MQ Internet Pass-Thru 2.1 and 9.2 could allow a remote user to cause a denial of service by sending malformed MQ data requests which would consume all available resources. IBM X-Force ID: 188093.",
"id": "GHSA-4mx5-h7cq-whf6",
"modified": "2022-05-24T17:40:03Z",
"published": "2022-05-24T17:40:03Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2020-4766"
},
{
"type": "WEB",
"url": "https://exchange.xforce.ibmcloud.com/vulnerabilities/188903"
},
{
"type": "WEB",
"url": "https://www.ibm.com/support/pages/node/6406254"
}
],
"schema_version": "1.4.0",
"severity": []
}
GHSA-4P42-G8MG-3MC5
Vulnerability from github – Published: 2026-10-21 00:31 – Updated: 2026-10-21 00:31Vulnerability in Oracle REST Data Services (component: Database Actions). Supported versions that are affected are 24.2.0-26.1.0. Easily exploitable vulnerability allows high privileged attacker with network access via HTTP to compromise Oracle REST Data Services. Successful attacks of this vulnerability can result in unauthorized update, insert or delete access to some of Oracle REST Data Services accessible data as well as unauthorized read access to a subset of Oracle REST Data Services accessible data and unauthorized ability to cause a partial denial of service (partial DOS) of Oracle REST Data Services. CVSS 3.1 Base Score 4.7 (Confidentiality, Integrity and Availability impacts). CVSS Vector: (CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:L/I:L/A:L).
{
"affected": [],
"aliases": [
"CVE-2026-101365"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2026-10-20T22:17:43Z",
"severity": "MODERATE"
},
"details": "Vulnerability in Oracle REST Data Services (component: Database Actions). Supported versions that are affected are 24.2.0-26.1.0. Easily exploitable vulnerability allows high privileged attacker with network access via HTTP to compromise Oracle REST Data Services. Successful attacks of this vulnerability can result in unauthorized update, insert or delete access to some of Oracle REST Data Services accessible data as well as unauthorized read access to a subset of Oracle REST Data Services accessible data and unauthorized ability to cause a partial denial of service (partial DOS) of Oracle REST Data Services. CVSS 3.1 Base Score 4.7 (Confidentiality, Integrity and Availability impacts). CVSS Vector: (CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:L/I:L/A:L).",
"id": "GHSA-4p42-g8mg-3mc5",
"modified": "2026-10-21T00:31:41Z",
"published": "2026-10-21T00:31:41Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-101365"
},
{
"type": "WEB",
"url": "https://www.oracle.com/security-alerts/cpuoct2026.html"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:H/UI:N/S:U/C:L/I:L/A:L",
"type": "CVSS_V3"
}
]
}
GHSA-4P4P-JWPF-WG9Q
Vulnerability from github – Published: 2025-10-24 21:31 – Updated: 2025-10-24 21:31An issue was discovered in the NDIS Usermode IO driver (RtkIOAC60.sys, version 6.0.5600.16348) allowing local authenticated attackers to send a crafted IOCTL request to the driver to cause a denial of service.
{
"affected": [],
"aliases": [
"CVE-2025-60419"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2025-10-24T20:16:30Z",
"severity": "MODERATE"
},
"details": "An issue was discovered in the NDIS Usermode IO driver (RtkIOAC60.sys, version 6.0.5600.16348) allowing local authenticated attackers to send a crafted IOCTL request to the driver to cause a denial of service.",
"id": "GHSA-4p4p-jwpf-wg9q",
"modified": "2025-10-24T21:31:11Z",
"published": "2025-10-24T21:31:11Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2025-60419"
},
{
"type": "WEB",
"url": "https://splineuser.github.io/posts/RTKVuln"
},
{
"type": "WEB",
"url": "http://ndis.com"
},
{
"type": "WEB",
"url": "http://realtek.com"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:L/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-4P4V-VXHG-4MMR
Vulnerability from github – Published: 2022-05-13 01:45 – Updated: 2022-05-13 01:45A vulnerability in the TCP normalizer of Cisco Adaptive Security Appliance (ASA) Software (8.0 through 8.7 and 9.0 through 9.6) and Cisco Firepower Threat Defense (FTD) Software could allow an unauthenticated, remote attacker to cause Cisco ASA and FTD to drop any further incoming traffic on all interfaces, resulting in a denial of service (DoS) condition. The vulnerability is due to improper limitation of the global out-of-order TCP queue for specific block sizes. An attacker could exploit this vulnerability by sending a large number of unique permitted TCP connections with out-of-order segments. An exploit could allow the attacker to exhaust available blocks in the global out-of-order TCP queue, causing the dropping of any further incoming traffic on all interfaces and resulting in a DoS condition. Cisco Bug IDs: CSCvb46321.
{
"affected": [],
"aliases": [
"CVE-2017-3793"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2017-04-20T22:59:00Z",
"severity": "MODERATE"
},
"details": "A vulnerability in the TCP normalizer of Cisco Adaptive Security Appliance (ASA) Software (8.0 through 8.7 and 9.0 through 9.6) and Cisco Firepower Threat Defense (FTD) Software could allow an unauthenticated, remote attacker to cause Cisco ASA and FTD to drop any further incoming traffic on all interfaces, resulting in a denial of service (DoS) condition. The vulnerability is due to improper limitation of the global out-of-order TCP queue for specific block sizes. An attacker could exploit this vulnerability by sending a large number of unique permitted TCP connections with out-of-order segments. An exploit could allow the attacker to exhaust available blocks in the global out-of-order TCP queue, causing the dropping of any further incoming traffic on all interfaces and resulting in a DoS condition. Cisco Bug IDs: CSCvb46321.",
"id": "GHSA-4p4v-vxhg-4mmr",
"modified": "2022-05-13T01:45:54Z",
"published": "2022-05-13T01:45:54Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2017-3793"
},
{
"type": "WEB",
"url": "https://tools.cisco.com/security/center/content/CiscoSecurityAdvisory/cisco-sa-20170419-asa-norm"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/97923"
},
{
"type": "WEB",
"url": "http://www.securitytracker.com/id/1038329"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.0/AV:N/AC:H/PR:N/UI:N/S:C/C:N/I:N/A:L",
"type": "CVSS_V3"
}
]
}
GHSA-4P62-4Q7W-QMCG
Vulnerability from github – Published: 2022-05-13 01:03 – Updated: 2022-05-13 01:03nginx before versions 1.15.6 and 1.14.1 has a vulnerability in the implementation of HTTP/2 that can allow for excessive memory consumption. This issue affects nginx compiled with the ngx_http_v2_module (not compiled by default) if the 'http2' option of the 'listen' directive is used in a configuration file.
{
"affected": [],
"aliases": [
"CVE-2018-16843"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": false,
"github_reviewed_at": null,
"nvd_published_at": "2018-11-07T14:29:00Z",
"severity": "HIGH"
},
"details": "nginx before versions 1.15.6 and 1.14.1 has a vulnerability in the implementation of HTTP/2 that can allow for excessive memory consumption. This issue affects nginx compiled with the ngx_http_v2_module (not compiled by default) if the \u0027http2\u0027 option of the \u0027listen\u0027 directive is used in a configuration file.",
"id": "GHSA-4p62-4q7w-qmcg",
"modified": "2022-05-13T01:03:33Z",
"published": "2022-05-13T01:03:33Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2018-16843"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2018:3653"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2018:3680"
},
{
"type": "WEB",
"url": "https://access.redhat.com/errata/RHSA-2018:3681"
},
{
"type": "WEB",
"url": "https://bugzilla.redhat.com/show_bug.cgi?id=CVE-2018-16843"
},
{
"type": "WEB",
"url": "https://support.apple.com/kb/HT212818"
},
{
"type": "WEB",
"url": "https://usn.ubuntu.com/3812-1"
},
{
"type": "WEB",
"url": "https://www.debian.org/security/2018/dsa-4335"
},
{
"type": "WEB",
"url": "http://lists.opensuse.org/opensuse-security-announce/2019-09/msg00035.html"
},
{
"type": "WEB",
"url": "http://mailman.nginx.org/pipermail/nginx-announce/2018/000220.html"
},
{
"type": "WEB",
"url": "http://seclists.org/fulldisclosure/2021/Sep/36"
},
{
"type": "WEB",
"url": "http://www.securityfocus.com/bid/105868"
},
{
"type": "WEB",
"url": "http://www.securitytracker.com/id/1042038"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
]
}
GHSA-4P6F-M4F9-CH88
Vulnerability from github – Published: 2022-09-16 21:25 – Updated: 2022-09-16 21:25Impact
What kind of vulnerability is it? Who is impacted?
The vulnerability is a memory allocation vulnerability that can be exploited to allocate slices in memory with (arbitrary) excessive size value, which can either exhaust available memory or crash the whole program.
When using github.com/gagliardetto/binary to parse unchecked (or wrong type of) data from untrusted sources of input (e.g. the blockchain) into slices, it's possible to allocate memory with excessive size.
When dec.Decode(&val) method is used to parse data into a structure that is or contains slices of values, the length of the slice was previously read directly from the data itself without any checks on the size of it, and then a slice was allocated. This could lead to an overflow and an allocation of memory with excessive size value.
Example:
package main
import (
"github.com/gagliardetto/binary" // any version before v0.7.1 is vulnerable
"log"
)
type MyStruct struct {
Field1 []byte // field is a slice (could be a slice of any type)
}
func main() {
// Let's assume that the data is coming from the blockchain:
data := []byte{0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10}
var val MyStruct
// - To determine the size of the val.Field1 slice, the decoder will read the length
// of the slice from the data itself without any checks on the size of it.
//
// - This could lead to an allocation of memory with excessive size value.
// Which means: []byte{0x01, 0x02, 0x03, 0x04} will be read as the length
// of the slice (= 67305985) and then an allocation of memory with 67305985 bytes will be made.
//
dec := binary.NewBorshDecoder(data)
err := dec.Decode(&val) // or binary.UnmarshalBorsh(&val, data) or binary.UnmarshalBin(&val, data) etc.
if err != nil {
log.Fatal(err)
}
}
Patches
Has the problem been patched? What versions should users upgrade to?
The vulnerability has been patched in github.com/gagliardetto/binary v0.7.1
Users should upgrade to v0.7.1 or higher.
To upgrade to v0.7.1 or higher, run:
go get github.com/gagliardetto/binary@v0.7.1
# or
go get github.com/gagliardetto/binary@latest
Workarounds
Is there a way for users to fix or remediate the vulnerability without upgrading?
A workaround is not to rely on the dec.Decode(&val) function to parse the data, but to use a custom UnmarshalWithDecoder() method that reads and checks the length of any slice.
References
Are there any links users can visit to find out more?
For more information
If you have any questions or comments about this advisory: * Open an issue in github.com/gagliardetto/binary * DM me on twitter
{
"affected": [
{
"package": {
"ecosystem": "Go",
"name": "github.com/gagliardetto/binary"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "0.7.1"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2022-36078"
],
"database_specific": {
"cwe_ids": [
"CWE-400",
"CWE-789"
],
"github_reviewed": true,
"github_reviewed_at": "2022-09-16T21:25:03Z",
"nvd_published_at": "2022-09-02T13:15:00Z",
"severity": "HIGH"
},
"details": "### Impact\n\u003e _What kind of vulnerability is it? Who is impacted?_\n\nThe vulnerability is a memory allocation vulnerability that can be exploited to allocate slices in memory with (arbitrary) excessive size value, which can either exhaust available memory or crash the whole program.\n\nWhen using `github.com/gagliardetto/binary` to parse unchecked (or wrong type of) data from untrusted sources of input (e.g. the blockchain) into slices, it\u0027s possible to allocate memory with excessive size.\n\nWhen `dec.Decode(\u0026val)` method is used to parse data into a structure that is or contains slices of values, the length of the slice was previously read directly from the data itself without any checks on the size of it, and then a slice was allocated. This could lead to an overflow and an allocation of memory with excessive size value.\n\nExample:\n\n```go\npackage main\n\nimport (\n\t\"github.com/gagliardetto/binary\" // any version before v0.7.1 is vulnerable\n\t\"log\"\n)\n\ntype MyStruct struct {\n\tField1 []byte // field is a slice (could be a slice of any type)\n}\n\nfunc main() {\n\t// Let\u0027s assume that the data is coming from the blockchain:\n\tdata := []byte{0x01, 0x02, 0x03, 0x04, 0x05, 0x06, 0x07, 0x08, 0x09, 0x0a, 0x0b, 0x0c, 0x0d, 0x0e, 0x0f, 0x10}\n\t\n\tvar val MyStruct\n\t// - To determine the size of the val.Field1 slice, the decoder will read the length\n\t// of the slice from the data itself without any checks on the size of it.\n\t//\n\t// - This could lead to an allocation of memory with excessive size value.\n\t// Which means: []byte{0x01, 0x02, 0x03, 0x04} will be read as the length\n\t// of the slice (= 67305985) and then an allocation of memory with 67305985 bytes will be made.\n\t//\n\tdec := binary.NewBorshDecoder(data)\n\terr := dec.Decode(\u0026val) // or binary.UnmarshalBorsh(\u0026val, data) or binary.UnmarshalBin(\u0026val, data) etc.\n\tif err != nil {\n\t\tlog.Fatal(err)\n\t}\n}\n```\n\n### Patches\n\u003e _Has the problem been patched? What versions should users upgrade to?_\n\nThe vulnerability has been patched in `github.com/gagliardetto/binary` `v0.7.1`\n\nUsers should upgrade to `v0.7.1` or higher.\n\nTo upgrade to `v0.7.1` or higher, run:\n\n```bash\ngo get github.com/gagliardetto/binary@v0.7.1\n\n# or\n\ngo get github.com/gagliardetto/binary@latest\n```\n\n### Workarounds\n\u003e _Is there a way for users to fix or remediate the vulnerability without upgrading?_\n\nA workaround is not to rely on the `dec.Decode(\u0026val)` function to parse the data, but to use a custom `UnmarshalWithDecoder()` method that reads and checks the length of any slice.\n\n### References\n\u003e _Are there any links users can visit to find out more?_\n\n### For more information\nIf you have any questions or comments about this advisory:\n* Open an issue in [github.com/gagliardetto/binary](https://github.com/gagliardetto/binary)\n* DM me on [twitter](https://twitter.com/immaterial_ink)\n",
"id": "GHSA-4p6f-m4f9-ch88",
"modified": "2022-09-16T21:25:03Z",
"published": "2022-09-16T21:25:03Z",
"references": [
{
"type": "WEB",
"url": "https://github.com/gagliardetto/binary/security/advisories/GHSA-4p6f-m4f9-ch88"
},
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2022-36078"
},
{
"type": "WEB",
"url": "https://github.com/gagliardetto/binary/pull/7"
},
{
"type": "PACKAGE",
"url": "https://github.com/gagliardetto/binary"
},
{
"type": "WEB",
"url": "https://github.com/gagliardetto/binary/releases/tag/v0.7.1"
},
{
"type": "WEB",
"url": "https://pkg.go.dev/vuln/GO-2022-0963"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:R/S:U/C:H/I:H/A:H",
"type": "CVSS_V3"
}
],
"summary": "Binary vulnerable to Slice Memory Allocation with Excessive Size Value"
}
GHSA-4P9M-8GC4-RW2H
Vulnerability from github – Published: 2026-03-16 18:32 – Updated: 2026-10-02 22:40An issue in GoBGP gobgpd v.4.2.0 allows a remote attacker to cause a denial of service via the NEXT_HOP path attribute.
{
"affected": [
{
"database_specific": {
"last_known_affected_version_range": "\u003c= 4.3.0"
},
"package": {
"ecosystem": "Go",
"name": "github.com/osrg/gobgp/v4"
},
"ranges": [
{
"events": [
{
"introduced": "0"
},
{
"fixed": "4.4.0"
}
],
"type": "ECOSYSTEM"
}
]
}
],
"aliases": [
"CVE-2026-30405"
],
"database_specific": {
"cwe_ids": [
"CWE-400"
],
"github_reviewed": true,
"github_reviewed_at": "2026-03-18T12:58:45Z",
"nvd_published_at": "2026-03-16T17:16:29Z",
"severity": "HIGH"
},
"details": "An issue in GoBGP gobgpd v.4.2.0 allows a remote attacker to cause a denial of service via the NEXT_HOP path attribute.",
"id": "GHSA-4p9m-8gc4-rw2h",
"modified": "2026-10-02T22:40:10Z",
"published": "2026-03-16T18:32:03Z",
"references": [
{
"type": "ADVISORY",
"url": "https://nvd.nist.gov/vuln/detail/CVE-2026-30405"
},
{
"type": "WEB",
"url": "https://github.com/osrg/gobgp/issues/3305"
},
{
"type": "WEB",
"url": "https://github.com/osrg/gobgp/commit/583080a7258e22cc884162e15b078771aa2c2c80"
},
{
"type": "PACKAGE",
"url": "https://github.com/osrg/gobgp"
},
{
"type": "WEB",
"url": "https://github.com/osrg/gobgp/releases/tag/v4.4.0"
}
],
"schema_version": "1.4.0",
"severity": [
{
"score": "CVSS:3.1/AV:N/AC:L/PR:N/UI:N/S:U/C:N/I:N/A:H",
"type": "CVSS_V3"
}
],
"summary": "GoBGP vulnerable to a denial of service via the NEXT_HOP path attribute"
}
Mitigation
Design throttling mechanisms into the system architecture. The best protection is to limit the amount of resources that an unauthorized user can cause to be expended. A strong authentication and access control model will help prevent such attacks from occurring in the first place. The login application should be protected against DoS attacks as much as possible. Limiting the database access, perhaps by caching result sets, can help minimize the resources expended. To further limit the potential for a DoS attack, consider tracking the rate of requests received from users and blocking requests that exceed a defined rate threshold.
Mitigation
- Mitigation of resource exhaustion attacks requires that the target system either:
- recognizes the attack and denies that user further access for a given amount of time, or
- uniformly throttles all requests in order to make it more difficult to consume resources more quickly than they can again be freed.
- The first of these solutions is an issue in itself though, since it may allow attackers to prevent the use of the system by a particular valid user. If the attacker impersonates the valid user, they may be able to prevent the user from accessing the server in question.
- The second solution is simply difficult to effectively institute -- and even when properly done, it does not provide a full solution. It simply makes the attack require more resources on the part of the attacker.
Mitigation
Ensure that protocols have specific limits of scale placed on them.
Mitigation
Ensure that all failures in resource allocation place the system into a safe posture.
CAPEC-147: XML Ping of the Death
An attacker initiates a resource depletion attack where a large number of small XML messages are delivered at a sufficiently rapid rate to cause a denial of service or crash of the target. Transactions such as repetitive SOAP transactions can deplete resources faster than a simple flooding attack because of the additional resources used by the SOAP protocol and the resources necessary to process SOAP messages. The transactions used are immaterial as long as they cause resource utilization on the target. In other words, this is a normal flooding attack augmented by using messages that will require extra processing on the target.
CAPEC-227: Sustained Client Engagement
An adversary attempts to deny legitimate users access to a resource by continually engaging a specific resource in an attempt to keep the resource tied up as long as possible. The adversary's primary goal is not to crash or flood the target, which would alert defenders; rather it is to repeatedly perform actions or abuse algorithmic flaws such that a given resource is tied up and not available to a legitimate user. By carefully crafting a requests that keep the resource engaged through what is seemingly benign requests, legitimate users are limited or completely denied access to the resource.
CAPEC-492: Regular Expression Exponential Blowup
An adversary may execute an attack on a program that uses a poor Regular Expression(Regex) implementation by choosing input that results in an extreme situation for the Regex. A typical extreme situation operates at exponential time compared to the input size. This is due to most implementations using a Nondeterministic Finite Automaton(NFA) state machine to be built by the Regex algorithm since NFA allows backtracking and thus more complex regular expressions.