Cornucopia (CX)
Spyros peut contourner les contrôles de l'application car les frameworks, les bibliothèques et les composants applicatifs contiennent du code malveillant ou des vulnérabilités (par exemple: interne, sur étagère, externalisé, open source, externe)
The key concept for this card is software hardening, configuration and patching. See Cornucopia 8 (C8) instead for host/network environment hardening, configuration and patching.
Scenario: Spyros’s Exploitation of Vulnerable Code Libraries and Frameworks
Imagine a situation where Spyros circumvents an application's controls by exploiting vulnerabilities or malicious code within its frameworks, libraries, and components. This can occur in various types of software, including:
- In-House Developed Software: Custom code developed internally may contain vulnerabilities or insufficiently reviewed segments.
- Commercial Off-The-Shelf (COTS) Products: Commercially available software might have undisclosed vulnerabilities.
- Outsourced Software Components: Externally developed components may not adhere to strict security standards.
- Open Source Libraries: Open source code might contain vulnerabilities or, in rare cases, malicious components.
- Externally-Located Code: Software components hosted externally may be compromised or altered without the knowledge of the primary application developers.
Example
Spyros identifies that a financial application uses a popular open-source library, which recently disclosed a vulnerability. However, the application’s developers have not yet updated the library to the patched version. Exploiting this known vulnerability, Spyros gains unauthorized access to the application, allowing him to manipulate transactions and access sensitive customer data. Additionally, Spyros finds that an outsourced module in the application contains poorly written code, which he exploits to bypass the application’s primary security controls.
Threat Modeling
STRIDE
The STRIDE category applicable here is Tampering.
The scenario describes circumventing application controls via vulnerable or malicious code in frameworks, libraries, or components. The primary impact is that an attacker can modify, manipulate, or exploit the application’s behavior through weaknesses in these components. The core issue in the context of vulnerable/malicious components is that the attacker can alter execution or manipulate application operations, which aligns with Tampering.
What can go wrong?
The use of vulnerable or compromised software components can lead to significant security breaches, unauthorized data access, and potential system compromises.
For more things that can go wrong, see the Common Attack Patterns related to this card in the table below.
What are we going to do about it?
- Regularly update all frameworks, libraries, and components to their latest, secure versions and ensure their versions are pinned.
- Conduct thorough security reviews and vulnerability assessments of all in-house, outsourced, and open-source code used within the application.
- Monitor security advisories for any components used within the application and respond swiftly to vulnerability disclosures.
- Establish a robust security protocol for integrating and maintaining external software components.
For detailed advice on how to mitigate threats related to the card, see the ASVS and OWASP Developer Guide requirements in the table below.
Mappings
OWASP ASVS (v5.0): 6.7.1,11.4.1,11.4.3,11.6.1,11.6.2,13.3.1,13.3.2,13.3.3,15.1.1,15.1.2,15.1.4,15.1.5,15.2.1,15.2.4,15.2.5,16.3.4
OWASP DevGuide: SC4,SFL1,SFL2,SFL10,SFL11,SFL12,SFL13,SFL14,SFL15
STRIDE: Tampering
CAPEC™: 68,159,206,442,446,523,538,673,691
SAFECode™: 15
CAPEC Map
| Code | Title | ASVS |
|---|---|---|
| 68 | Subvert Code-signing Facilities | 6.7.1,11.4.1,11.4.3,11.6.1,11.6.2,13.3.1,13.3.2,13.3.3,15.2.5,16.3.1,16.3.2,16.3.3,16.3.4 |
| 159 | Redirect Access to Libraries | 15.2.4,16.3.4 |
| 206 | Signing Malicious Code | 13.3.1,13.3.2,13.3.3,16.3.1,16.3.2,16.3.3,16.3.4 |
| 442 | Infected Software | 15.1.1,15.1.2,15.1.4,15.1.5,15.2.1,15.2.4,15.2.5,16.3.4 |
| 446 | Malicious Logic Insertion into Product via Inclusion of Third-Party Component | 15.1.1,15.1.2,15.1.4,15.1.5,15.2.1,15.2.4,15.2.5,16.3.4 |
| 523 | Malicious Software Implanted | 15.1.1,15.1.2,15.1.4,15.1.5,15.2.1,15.2.4,15.2.5,16.3.4 |
| 538 | Open-Source Library Manipulation | 15.1.1,15.1.2,15.1.4,15.1.5,15.2.1,15.2.4,15.2.5,16.3.4 |
| 673 | Developer Signing Maliciously Altered Software | 15.1.1,15.1.2,15.1.4,15.1.5,15.2.1,15.2.4,15.2.5,16.3.4 |
| 691 | Spoof Open-Source Software Metadata | 15.1.1,15.1.2,15.1.4,15.1.5,15.2.1,15.2.4,15.2.5,16.3.4 |