Hybrid Static-Dynamic Security Verification for Dynamic Code Loading
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Existing security solutions are inadequate in enforcing security policies for applications that utilize dynamic code loading, as they struggle to distinguish between benign and malicious code behaviors, particularly in scenarios where dynamic code evades static checks.
Innovation Solution
A hybrid approach combining static and dynamic analyses is employed, where static program verification is performed to ensure compliance with a specified security policy, followed by dynamic instrumentation and runtime verification to enforce the policy, especially for security-critical operations involving dynamically loaded code.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Measurement precision
If static analysis is used to verify security policy compliance, then verification completeness is improved, but dynamic code loading evasion capability worsens
Solution Approach 1:
The system performs preliminary static verification on the code loading mechanism and resource structure before runtime execution. This includes analyzing the resource file structure, verifying security policy compliance of loading logic, and establishing verification rules in advance, so that when dynamic code is loaded, the verification framework is already in place to handle it effectively
Solution Approach 2:
The patent introduces an intermediary verification layer that sits between the dynamic code loading mechanism and the security policy enforcement. This intermediary component intercepts loading requests, performs runtime verification using pre-established rules, and mediates between the dynamic nature of loaded code and the static requirements of security policies
2Adaptability or versatility
If dynamic code loading is allowed, then application functionality and IP protection are improved, but security detection capability worsens
Solution Approach 1:
The verification system is segmented into distinct components: a static verification phase that analyzes security policies and establishes rules, a runtime verification phase that handles actual code loading, and a rule management system that bridges them. This segmentation allows each component to specialize in its function while working together to provide comprehensive security verification for dynamic code
Solution Approach 2:
The system changes the verification parameter from purely static to a hybrid static-dynamic approach. Pre-verification establishes baseline security requirements and loading rules, then runtime verification dynamically adjusts checking based on actual loading behavior, effectively adapting the verification process to match the dynamic nature of the code while maintaining security standards
3Reliability
If comprehensive runtime verification is performed on all code, then security enforcement is improved, but system performance worsens
Solution Approach 1:
The system performs partial verification by focusing runtime checks specifically on the dynamically loaded code portions rather than re-verifying the entire application. The static verification phase handles the bulk of verification work upfront, and runtime verification only applies to the variable dynamic portions, avoiding redundant checks and optimizing performance
Data Source
AI summary
A method (and structure) for enforcing a security policy includes retrieving from a memory a program to be verified against a security policy and a security specification defining the security policy. A static program analysis is performed on the program, using a processor on a computer, to determine whether the program is compatible with the security specification. The program is rejected if the program is determined by the static program analysis as being incompatible with the security specification. If the program is determined during the static program analysis as compatible with the security specification under static analysis criteria, then building a call-graph representation of the program for use to evaluate any dynamically-loaded code during an execution of the program. Any paths, if any, of the call-graph representation that reach at least one policy-relevant operation is marked.


