Introduction
The architectural landscape of enterprise software has irrevocably shifted toward distributed, containerized microservices executing across polyglot stacks. A single transaction may ingress through a Node.js API gateway, dispatch business logic across Java Spring Boot microservices, and query analytics pipelines orchestrated via Python. While this architecture unlocks developer velocity, it dramatically expands the enterprise attack surface.
Historically, perimeter security has relied heavily on Web Application Firewalls (WAFs). However, empirical telemetry demonstrates that WAFs suffer from fundamental blind spots [1]. WAFs inspect incoming HTTP payloads using regular expression matching, which attackers readily circumvent via Unicode obfuscation or multi-stage deserialization (e.g., Log4Shell JNDI/LDAP injections) [2].
To resolve this semantic gap, modern security frameworks have pursued two paradigms: Kernel-Level Tracing (eBPF) and Runtime Application Self-Protection (RASP). However, both approaches face critical limitations:
-
The eBPF Semantic Gap: While eBPF intercepts system calls (e.g.,
sys_enter_execve), it lacks application context. The kernel cannot discern whether an invocation of/bin/shoriginated from an administrative backup script or an arbitrary command injection in an evaluation parser. -
Fragility & Overhead in Existing RASP: Existing RASP solutions rely on runtime monkey-patching, which sophisticated malware easily unhooks via foreign function interfaces (
ctypes) or prototype pollution. In Java, callingThread.getStackTrace()incurs massive garbage collection pauses exceeding 15% [3].
Major Research Contributions
- Zero-Bypass Polyglot Architecture: The first unified RASP framework protecting JVM (Java 8–25+), Node.js, Python, and Native OS under shared zero-trust.
- C-Level Interpreter Hooking via PEP 578: Python sentinel trapping dangerous syscalls at the CPython core, preventing bypasses through
ctypes. - Tamper-Proof V8 Descriptor Sealing: Locking Node.js prototype properties using strict descriptor immutability (
writable: false, configurable: false). - Zero-Allocation StackWalker Integration: Java 9+ caller traversal with sub-millisecond inspection and O(1) memory allocation.
- Empirical 50-Application Stress Benchmark: Comprehensive verification across 50 applications establishing <2.0% SLA and 100% interception rate.
Threat Model & Adversary Capabilities
We assume an external adversary has achieved arbitrary code execution (RCE) within the application. The adversary seeks to spawn shells, manipulate off-heap memory, or exfiltrate credentials (.env, database keys).
Our defense perimeter is mapped directly to the MITRE ATT&CK® Enterprise Matrix:
- T1059.004 (Unix Shell Execution): Intercepts
os.system,child_process.exec,ProcessBuilder. - T1055 (Process Memory Injection): Blocks off-heap direct memory writes via
sun.misc.Unsafe. - T1552.001 (Credentials in Files): Protects secrets (
.env,/etc/shadow). - T1059.007 (Dynamic Code Execution): Intercepts dynamic evaluation (
eval()).
System Architecture & Hooking Mechanics
DeMalware-UNIVERSAL executes language-specific autonomous sentinels coordinating through an in-memory ring buffer.
3.1 Python Sentinel: C-Level Audit Traps via PEP 578
By registering a C-interpreter hook via sys.addaudithook(), our sentinel traps dangerous syscalls directly inside CPython core:
Because PEP 578 hooks reside inside CPython internal C-structures, they cannot be unhooked from user-space Python, even if malicious code calls ctypes.CDLL(None).
3.2 Node.js Sentinel: V8 Prototype Descriptor Sealing
In Node.js, traps on child_process.exec are applied with immutable descriptors:
configurable: false guarantees that malicious npm dependencies cannot unhook or delete the trap.
3.3 JVM Sentinel: Bytecode Transformation & Zero-Allocation StackWalker
In Java, our agent attaches via -javaagent and inspects callers using Java 9+ StackWalker without allocating arrays on heap:
Empirical Evaluation & Stress Benchmarks
We tested DeMalware-UNIVERSAL across a comprehensive suite of **50 distinct applications** (25 production enterprise workloads vs. 25 worst-case adversarial scripts).
Across all 25 adversarial worst-case applications, DeMalware-UNIVERSAL sustained zero fatal crashes. Every attack payload (rm -rf /, curl evil.sh | bash, /etc/shadow) was safely blocked.
Security Analysis & Evasion Resistance
Attack: Loading libc directly via ctypes.CDLL(None).system().
Defense: PEP 578 audit hook catches ctypes.dlopen at C-level, terminating execution.
Attack: Restoring methods via delete child_process.exec.
Defense: configurable: false blocks deletion and reassignment.
Attack: Overwriting memory via sun.misc.Unsafe.putAddress().
Defense: ASM 9.6 transformer rewrites Unsafe bytecode allocations, throwing SecurityException.
Attack: Flooding logging buffers to cause OutOfMemory (OOM).
Defense: Bounded O(1) pre-allocated circular ring buffers (50 slots).
Related Work
Commercial RASP Solutions: Vendors such as Contrast Security [4], Snyk, and Datadog offer runtime agents. However, they are single-language silos and commonly impose 8–15% overhead.
Kernel-Level Tracing (eBPF): Frameworks like Falco [5] trace syscalls in kernel space, but lack function caller context. DeMalware-UNIVERSAL preserves full caller frame semantics.
Conclusion & Future Work
We introduced DeMalware-UNIVERSAL, a zero-bypass polyglot RASP framework. By utilizing PEP 578 audit hooks, V8 descriptor sealing, and Java 9+ StackWalker traversal, the system guarantees deterministic runtime protection with <2.0% latency penalty and zero fatal crashes across 50 applications.
- Gartner Research. (2021). Technology Insight for Runtime Application Self-Protection (RASP).
- Apache Software Foundation. (2021). CVE-2021-44228: Log4j2 JNDI Remote Code Execution.
- Oracle Corp. (2017). Java Platform SE 9 API: java.lang.StackWalker.
- Contrast Security. (2023). Anatomy of Runtime Application Self-Protection: Mechanics and Overhead.
- Linux Foundation. (2022). eBPF Architecture and Kernel Probe Tracing.
- Python Software Foundation. (2019). PEP 578 – Python Runtime Audit Hooks.
- Google V8 Team. (2020). Property Descriptors and Prototype Invariant Integrity in V8.
- Bruneton, E. et al. (2002). ASM: A code manipulation framework for adaptable systems.
- MITRE Corp. (2024). MITRE ATT&CK Enterprise Matrix for Software Execution.
- Niloy, A. J. A. (2026). DeMalware-UNIVERSAL: Multi-Runtime Application Self-Protection Engine.