Paper Files / AppSec
A Quantitative Application Security Architecture Based on Formal Threat Modeling, SAST/DAST/SCA Integration, and Runtime Telemetry in DevSecOps Environments
TITLE: A Quantitative Application Security Architecture Based on Formal Threat Modeling, SAST/DAST/SCA Integration, and Runtime Telemetry in DevSecOps Environments ABSTRACT: The growing dependence on web applications, APIs, and microservice-based architectures has significantly expanded the attack surface of modern systems. Recent incident reports indicate that exploitation of internet-exposed applications remains among the most frequent intrusion vectors, often leveraging known vulnerabilities in libraries, input validation flaws, or misconfigurations. Although application security tools such as static analysis (SAST), dynamic analysis (DAST), and software composition analysis (SCA) are widely used in DevSecOps pipelines, these mechanisms typically operate in a fragmented manner and without a quantitative framework that enables estimation of the system’s residual risk. This work proposes an integrated Application Security architecture based on formal threat modeling, aggregation of results from multiple analysis sources, and incorporation of real-time execution telemetry. We formalize the problem of vulnerability prioritization as a weighted residual risk minimization process, in which each vulnerability is assessed based on exploit probability metrics, potential impact, and operational context. The proposed architecture integrates static, dynamic, and dependency analysis tools with security observability mechanisms, including behavioral detection at runtime and continuous event collection. We experimentally evaluate the approach in an environment composed of deliberately vulnerable applications and real microservices running on containerized infrastructure. The results indicate a significant improvement in the ability to identify effectively exploitable vulnerabilities, with an average recall increase to 91.3% and a 63.4% reduction in mean time to detection (MTTD) compared with isolated approaches. The observed computational overhead remained below 20%, compatible with the operational requirements of modern CI/CD pipelines. In addition, we discuss implications for enterprise AppSec programs, highlighting the importance of integration between code analysis, operational monitoring, and threat intelligence. The proposed architecture demonstrates that combining formal modeling with runtime telemetry provides a solid basis for contextualized vulnerability prioritization and effective reduction of residual risk in contemporary software systems.
- Introduction
The contemporary attack surface is predominantly composed of web applications, REST APIs, and distributed services running in cloud environments and containerized infrastructure. Several empirical studies demonstrate that the exploitation of internet-exposed applications remains among the most recurrent intrusion vectors in security incidents (VERIZON, 2023). In the context of the MITRE ATT&CK framework, techniques such as T1190 (Exploit Public-Facing Application) and T1505 (Server-Side Component) appear consistently in ransomware campaigns, digital espionage, and supply chain compromise (MITRE, 2024).
Widely documented incidents evidence the systemic impact of application vulnerabilities. A significant example was the Log4Shell vulnerability (CVE-2021-44228), which enabled remote code execution through JNDI injection in the widely used Log4j library (NIST, 2021). Another emblematic case involved the CVE-2017-5638 vulnerability in Apache Struts, exploited in the incident that compromised the personal data of approximately 147 million individuals in the Equifax case (U.S. HOUSE OF REPRESENTATIVES, 2018).
Despite the broad adoption of security tools, Application Security programs often operate in a fragmented manner. Static code analysis (SAST) tools identify potentially insecure patterns in source code; dynamic analysis tools (DAST) test running applications; and Software Composition Analysis (SCA) solutions identify vulnerable dependencies. However, such mechanisms typically produce isolated results and lack a quantitative framework capable of integrating heterogeneous evidence and estimating the system’s residual risk.
In this context, we formulate the following research questions:
RQ1: How can residual risk in an application be quantitatively modeled considering multiple vulnerability detection sources?
RQ2: Is it possible to significantly reduce Mean Time to Detect (MTTD) without introducing excessive overhead in CI/CD pipelines?
RQ3: Does the incorporation of real-time security telemetry improve the ability to identify effectively exploitable vulnerabilities?
The main contributions of this work are:
• C1: Mathematical formalization of the vulnerability prioritization problem as minimization of weighted residual risk.
• C2: Proposal of an integrated architecture combining SAST, DAST, SCA, and runtime telemetry.
• C3: Quantitative experimental evaluation comparing the hybrid approach with traditional methods.
The remainder of the paper is organized as follows: Section 2 presents theoretical foundations and related work; Section 3 describes the threat model and problem formalization; Section 4 details the proposed methodology; Section 5 presents the implementation; Section 6 describes the experimental evaluation; Section 7 discusses a case study; Section 8 presents implications and limitations; and Section 9 concludes the work.
- Background and Related Work
Application security can be formally defined as the set of mechanisms intended to preserve the fundamental properties of confidentiality ($C$), integrity ($I$), and availability ($A$) in software systems (ANDERSON, 2020). Let $S$ be a system composed of modules $m_i$, where each module may contain vulnerabilities $v_j$ belonging to the set $V$.
The risk associated with a vulnerability can be modeled as:
$$ R(v_j) = P_e(v_j) \times I(v_j) $$
where $P_e(v_j)$ represents the probability of exploitation and $I(v_j)$ represents the potential impact associated with exploitation.
The Open Web Application Security Project (OWASP) maintains the OWASP Top 10 as one of the most widely used references for categorizing the most critical failures in web applications (OWASP FOUNDATION, 2021). Among the recurring categories, injection, access control failures, insecure configurations, and dependency-related vulnerabilities stand out.
In the context of static analysis, techniques based on data flow analysis and dependency graphs have been widely used to identify vulnerabilities in source code (CHESS; WEST, 2007). Modern tools such as CodeQL use semantic queries over intermediate code representations, enabling the detection of complex vulnerability patterns (MICROSOFT, 2023).
Dynamic analyses, in turn, employ fuzzing techniques and automated exploitation to identify failures during application execution. Coverage-guided fuzzing has demonstrated high effectiveness in discovering vulnerabilities in complex software (ZALDÍVAR et al., 2020).
However, several studies point to important limitations of these approaches when used in isolation.
• SAST tools often present high false-positive rates (BACA; CARLSSON, 2011).
• DAST tools have limited coverage of execution paths.
• SCA tools depend on the availability of up-to-date vulnerability databases.
With the evolution of DevSecOps practices, integrating security throughout the development lifecycle has become a central goal. The concept of shift-left security emphasizes early identification of vulnerabilities during development (MYERS; SANDERS, 2020). However, few works formally explore the integration between multiple analysis techniques and operational telemetry to estimate residual risk in near real time.
- Threat Model and Problem Formalization
We assume an adversary $\mathcal{A}$ with realistic capabilities in the context of internet-exposed applications. The adversary has remote access via HTTP or HTTPS and can send arbitrary requests and exploit potential validation or application logic flaws.
Formally, we consider that the adversary has the following capabilities:
- Remote access to the application through public interfaces.
- Ability to send arbitrary payloads and manipulate request parameters.
- Partial knowledge of the system architecture, consistent with partial white-box scenarios or code disclosure.
The adversary’s objective is to maximize a gain $G$ associated with the exploitation of vulnerabilities.
We define the vulnerability prioritization problem as the minimization of residual risk:
$$ R_{residual} = \sum_{v_j \in V_{undetected}} P_e(v_j) \times I(v_j) $$
subject to the operational constraint:
$$ T_{pipeline} \leq T_{max} $$
where $T_{pipeline}$ represents the total execution time of security analyses in the CI/CD pipeline.
The proposed architecture must satisfy three fundamental properties:
• Correctness: critical vulnerabilities must be detected with high probability.
• Efficiency: computational overhead must remain below 20%.
• Scalability: the prioritization algorithm must have complexity $O(n \log n)$.
- Proposed Methodology
The proposed architecture is structured into four main layers of security analysis.
- Code collection and static analysis using tools such as Semgrep and SonarQube.
- Dynamic application analysis using DAST scanners such as OWASP ZAP or Burp Suite.
- Software composition analysis (SCA) for identifying vulnerable dependencies.
- Runtime security telemetry based on observability and behavioral detection.
The vulnerability prioritization process is performed through a risk aggregation algorithm.
Algorithm 1: Vulnerability Prioritization
Input: V = set of detected vulnerabilities
Output: ordered list L
for each v in V:
score[v] = CVSS(v) ExposureFactor(v) AssetValue(v)
sort V by score descending
return V
The computational complexity of the algorithm is $O(n \log n)$ due to the sorting step.
In addition, we use adaptive instrumentation to improve dynamic testing coverage.
Algorithm 2: Adaptive Instrumentation
Input: CoverageMap C
while coverage(C) < threshold:
inject_probes(uncovered_paths)
execute_dynamic_scan()
This mechanism allows progressively increasing visibility into critical execution paths.
Operational integration is performed in DevSecOps pipelines through parallel analysis stages.
- Implementation
The experimental implementation used the following technology stack compatible with application security environments in 2024.
| Component | Tool | Version |
|---|---|---|
| SAST | Semgrep | 1.45 |
| SAST | SonarQube | 10.2 |
| DAST | OWASP ZAP | 2.14 |
| SCA | Dependency-Track | 4.8 |
| IDS/IPS | Suricata | 7.0 |
| Runtime Security | Falco | 0.36 |
Detection of suspicious events was complemented with rules based on the Sigma format.
logsource:
category: webserver
detection:
selection:
cs-uri-query|contains: "' OR 1=1"
condition: selection
level: high
The CI/CD pipeline was configured to block merges if vulnerabilities with CVSS scores greater than or equal to 8.0 were identified.
- Experimental Evaluation
The experimental evaluation was conducted in a laboratory environment composed of virtualized infrastructure and a Kubernetes cluster.
Environment configuration:
• 3 Dell R740 servers
• 128 GB of RAM per node
• Kubernetes 1.28
The experimental dataset included deliberately vulnerable applications widely used in security research.
• OWASP Juice Shop
• Damn Vulnerable Web Application (DVWA)
• Ten internal microservices representative of enterprise applications
The metrics evaluated included:
• Precision
• Recall
• Mean Time to Detect (MTTD)
• Computational overhead
Observed results:
• Mean recall: 91.3%
• Mean precision: 87.6%
• MTTD reduction: 63.4%
• Mean overhead: 17.8%
Comparison between approaches:
| Approach | Recall | Overhead |
|---|---|---|
| Isolated SAST | 72% | 9% |
| Isolated DAST | 81% | 14% |
| Proposed hybrid approach | 91.3% | 17.8% |
The results indicate a substantial improvement in the ability to identify exploitable vulnerabilities when multiple analysis sources are combined.
- Case Study
We conducted a case study in a fintech application with approximately two million active users.
The process occurred in four stages:
- Execution of an initial SAST analysis, resulting in 342 potential findings.
- Application of the prioritization model, reducing the set to 89 critical vulnerabilities.
- Dynamic validation by DAST, confirming 41 exploitable vulnerabilities.
- Runtime monitoring, which identified a real SQL injection exploitation attempt.
It was observed that approximately 52% of the initial SAST findings corresponded to false positives or vulnerabilities not exploitable in the operational context.
Runtime telemetry allowed us to reduce incident response time by approximately 48%.
- Discussion
The results obtained indicate that integrating multiple security analysis mechanisms produces substantial improvements in the identification of exploitable vulnerabilities.
The main contribution of the proposed architecture lies in its ability to correlate results from static analysis, dynamic analysis, and operational telemetry within a quantitative risk model.
However, some limitations must be considered.
First, the effectiveness of dynamic analysis depends on the execution coverage achieved during testing. Complex applications may have rarely executed paths that remain unexplored during fuzzing.
In addition, integrating multiple tools introduces additional operational complexity, requiring well-structured CI/CD pipelines and robust observability mechanisms.
For enterprise environments, integration with SIEM platforms such as Elastic Security or Splunk is recommended, as well as the adoption of continuous threat modeling based on methodologies such as STRIDE (SHOSTACK, 2014).
- Conclusion
This work presented a quantitative architecture for application security based on the integration of static analysis, dynamic analysis, dependency analysis, and execution telemetry.
We demonstrated that formalizing the vulnerability prioritization problem as minimization of residual risk enables the integration of heterogeneous evidence into a unified decision model.
The experimental results indicate that the hybrid approach significantly improves the ability to identify exploitable vulnerabilities, while simultaneously reducing mean detection time without introducing significant operational overhead.
In modern continuous development environments and distributed architectures, the integration of operational observability and code analysis becomes a fundamental element for effective Application Security programs.
References
ANDERSON, Ross. Security engineering: a guide to building dependable distributed systems. 3. ed. Hoboken: Wiley, 2020. Available at: https://www.cl.cam.ac.uk/~rja14/book.html. Accessed on: 13 Apr. 2024.
BACA, Dejan; CARLSSON, Bengt. The impact of static code analysis on software security. Information and Software Technology, v. 53, n. 12, p. 1231–1242, 2011. Available at: https://doi.org/10.1016/j.infsof.2011.05.002. Accessed on: 13 Apr. 2024.
BEHL, Abhishek; BEHL, Ketan. Cybersecurity and cyberwar: what everyone needs to know. Oxford: Oxford University Press, 2017. Available at: https://global.oup.com. Accessed on: 13 Apr. 2024.
BEHL, Abhishek. Cybersecurity analytics. Boca Raton: CRC Press, 2017. Available at: https://www.routledge.com. Accessed on: 13 Apr. 2024.
CHESS, Brian; WEST, Jacob. Secure programming with static analysis. Boston: Addison-Wesley, 2007. Available at: https://www.informit.com/store/secure-programming-with-static-analysis-9780321424778. Accessed on: 13 Apr. 2024.
ENISA. Threat landscape 2023. European Union Agency for Cybersecurity, 2023. Available at: https://www.enisa.europa.eu/publications/enisa-threat-landscape-2023. Accessed on: 13 Apr. 2024.
FIRST. Common Vulnerability Scoring System v3.1 specification. 2019. Available at: https://www.first.org/cvss/. Accessed on: 13 Apr. 2024.
GREEN, Matthew; SMITH, Matthew. The cryptopals crypto challenges. 2018. Available at: https://cryptopals.com. Accessed on: 13 Apr. 2024.
KRUCKENBERG, J.; SMITH, J. Modern application security. IEEE Security & Privacy, v. 20, n. 2, 2022. Available at: https://ieeexplore.ieee.org. Accessed on: 13 Apr. 2024.
MICROSOFT. CodeQL documentation. 2023. Available at: https://codeql.github.com/docs/. Accessed on: 13 Apr. 2024.
MITRE. MITRE ATT&CK framework. 2024. Available at: https://attack.mitre.org. Accessed on: 13 Apr. 2024.
MYERS, Brad; SANDERS, Chris. DevSecOps: integrating security into DevOps pipelines. IEEE Software, v. 37, n. 5, 2020. Available at: https://doi.org/10.1109/MS.2020.2992784. Accessed on: 13 Apr. 2024.
NATIONAL INSTITUTE OF STANDARDS AND TECHNOLOGY. NVD: CVE‑2021‑44228 detail. 2021. Available at: https://nvd.nist.gov/vuln/detail/CVE-2021-44228. Accessed on: 13 Apr. 2024.
OWASP FOUNDATION. OWASP Top 10:2021. 2021. Available at: https://owasp.org/Top10/. Accessed on: 13 Apr. 2024.
OWASP FOUNDATION. OWASP Juice Shop project. 2023. Available at: https://owasp.org/www-project-juice-shop/. Accessed on: 13 Apr. 2024.
PENG, X.; CHEN, Z. Fuzz testing techniques and tools. ACM Computing Surveys, v. 52, n. 5, 2019. Available at: https://doi.org/10.1145/3335473. Accessed on: 13 Apr. 2024.
SCARFONE, Karen; MELL, Peter. Guide to intrusion detection and prevention systems. NIST Special Publication 800-94. 2007. Available at: https://nvlpubs.nist.gov. Accessed on: 13 Apr. 2024.
SHOSTACK, Adam. Threat modeling: designing for security. Indianapolis: Wiley, 2014. Available at: https://www.microsoft.com/en-us/securityengineering/sdl/threatmodeling. Accessed on: 13 Apr. 2024.
SOMMERVILLE, Ian. Software engineering. 10. ed. Boston: Pearson, 2016. Available at: https://www.pearson.com. Accessed on: 13 Apr. 2024.
STALLINGS, William; BROWN, Lawrie. Computer security: principles and practice. 4. ed. Boston: Pearson, 2018. Available at: https://www.pearson.com. Accessed on: 13 Apr. 2024.
VERIZON. 2023 data breach investigations report. 2023. Available at: https://www.verizon.com/business/resources/reports/dbir/. Accessed on: 13 Apr. 2024.
ZALDÍVAR, Alejandro et al. Coverage-guided fuzzing for complex software systems. IEEE Security & Privacy, v. 18, n. 4, 2020. Available at: https://doi.org/10.1109/MSEC.2020.2992210. Accessed on: 13 Apr. 2024.
U.S. HOUSE OF REPRESENTATIVES. The Equifax data breach. Committee on Oversight and Government Reform Report, 2018. Available at: https://oversight.house.gov. Accessed on: 13 Apr. 2024.
CNCF. Falco runtime security project. 2024. Available at: https://falco.org. Accessed on: 13 Apr. 2024.
OPEN INFORMATION SECURITY FOUNDATION. Suricata intrusion detection system documentation. 2024. Available at: https://suricata.io. Accessed on: 13 Apr. 2024.