Semantic Error Detection in Deployed Software via Invariant Learning
Find Innovative SolutionsGenerate Solutions
Solution Overview
Problem
Despite advancements in program robustness, semantic errors in critical applications like browsers continue to pose a significant security risk due to their inherent nature of deviating from the intended program specification, making them difficult to detect and address without explicit information about the program's intended operation.
Innovation Solution
A method is introduced to detect and repair semantic errors by inferring correct program operation through monitoring and learning correct examples, identifying invariants during execution, and augmenting the program logic with error handling procedures to prevent malicious exploitation and failures, even without access to source code or debugging information.
Engineering Contradictions & Design Principles
Engineering Contradiction Analysis
1Reliability
If semantic error detection methods are developed, then security reliability is improved, but device complexity and difficulty of detection increase because semantic errors require understanding of program intent without explicit specifications
Solution Approach 1:
The patent creates a virtual model (copy) of the program's intended behavior by monitoring correct executions and learning invariants. This virtual model serves as a reference to compare against actual program behavior, enabling detection of semantic errors without requiring explicit specifications or complex analysis of program intent.
Solution Approach 2:
The system continuously monitors program executions, compares actual behavior against learned invariants from correct executions, and uses this feedback to detect semantic errors. The feedback loop enables automatic detection by measuring deviations from expected behavior patterns established during the learning phase.
2Reliability
If program logic is augmented with error handling procedures, then reliability is improved, but device complexity increases due to additional monitoring and invariant checking mechanisms
Solution Approach 1:
The patent performs preliminary action by monitoring correct program executions during a learning phase to establish invariants before the program is deployed. These pre-learned invariants are stored and used for subsequent error detection, eliminating the need for complex real-time analysis of program intent during execution.
Solution Approach 2:
The system enables self-service by allowing the program to automatically detect and report its own semantic errors through invariant violation detection. The program monitors itself against learned invariants without requiring external analysis tools or complex intervention mechanisms.
3Measurement precision
If invariants are learned from monitoring executions, then measurement precision of correct operation is improved, but loss of time increases due to monitoring overhead
Solution Approach 1:
The patent performs the time-consuming monitoring and invariant learning process in advance during a separate learning phase, before the program is deployed for production use. This preliminary action separates the time-intensive measurement precision improvement from the actual program execution, minimizing time loss during operational phases.
Solution Approach 2:
The system monitors only specific aspects of program execution relevant to invariant verification rather than complete program behavior. This partial monitoring approach achieves sufficient measurement precision for detecting semantic errors while reducing the time overhead compared to comprehensive monitoring.
Data Source
AI summary
An approach to detection and repair of application level semantic errors in deployed software includes inferring aspects of correct operation of a program. For instance, a suite of examples of operations that are known or assumed to be correct are used to infer correct operation. Further operation of the program can be compared to results found during correct operation and the logic of the program can be augmented to ensure that aspects of further examples of operation of the program are sufficiently similar to the examples in the correct suite. In some examples, the similarity is based on identifying invariants that are satisfied at certain points in the program execution, and augmenting (e.g., “patching”) the logic includes adding tests to confirm that the invariants are satisfied in the new examples. In some examples, the logic invokes an automatic or semi-automatic error handling procedure if the test is not satisfied. Augmenting the logic in this way may prevent malicious parties from exploiting the semantic errors, and may prevent failures in execution of the programs that may have been avoided.


