Skip to content
P

PatchProof

Don't just scan vulnerabilities — prove the exploi

Created on 31st October 2026

•

P

PatchProof

Don't just scan vulnerabilities — prove the exploi

The problem PatchProof solves

Developers use security scanners to identify vulnerabilities in their applications, but finding a vulnerability is only half the job. The bigger challenge is knowing whether the issue is actually exploitable and, more importantly, whether the proposed fix truly resolves it.

Today, developers and security teams often have to rely on manual testing and assumptions to verify security patches. A fix might only partially address the vulnerability, introduce new bugs, or break existing functionality. Without proper verification and supporting evidence, teams cannot confidently know whether their application is secure against the reported issue.

PatchProof addresses this gap by bringing vulnerability detection, automated verification, and security patch validation into one workflow.

It helps developers:

  • Identify Vulnerabilities: Detect potential security issues and understand which parts of their code are affected.
  • Reproduce Security Issues: Run controlled tests to check whether reported vulnerabilities can actually be reproduced.
  • Validate Security Fixes: Compare vulnerable and patched code by running the same security tests against both versions.
  • Prevent New Issues: Run regression tests to ensure security fixes do not break existing application functionality.
  • Generate Evidence: Produce verification reports containing test results, execution logs, and commit references.

By automating these steps, PatchProof reduces manual verification efforts, makes security reviews more reliable, and helps development teams make better-informed decisions before merging security fixes.

Our goal is simple: Move developers from "I think the vulnerability is fixed" to "I have evidence that the fix works under the tested conditions."

Challenges we ran into

Challenges We Ran Into

1. Eliminating "Phantom Fixes" via a Dual-State Verification Matrix

  • The Challenge: Traditional security tools create a dangerous false sense of security: developers frequently silence static analysis scanners (like Semgrep or SonarQube) simply by renaming variables, modifying comments, or wrapping inputs in ineffective string replacements. The scanner reports "0 vulnerabilities," yet the exploit vector remains wide open. Conversely, aggressive patches often close the security hole but accidentally break core business logic (regressions).
  • How We Overcame It: We designed and implemented a Deterministic Dual-State Verification Matrix. Instead of blindly trusting scanner outputs, PatchProof compiles and executes the application under two separate states using dynamic exploit reproducer harnesses:
    1. Reproduction Phase: It executes the exploit harness against the unpatched commit. The test MUST succeed (Exit Code 0) to mathematically prove the vulnerability was real, eliminating false positives upfront.
    2. Fix Verification Phase: It applies the candidate patch and re-executes both the exploit harness (which must now be cleanly blocked) AND the original test suite (which must still pass).
      A patch is only certified if it satisfies both criteria: zero exploitability with zero regression.

2. Eliminating State Pollution & Flakiness in Dynamic Exploit Tests

  • The Challenge: Automated exploit reproduction is notoriously susceptible to "flaky test" behavior. If a dynamic test relies on shared state, external databases, or network calls, it might intermittently pass or fail due to latency or leftover data, rendering automated verification untrustworthy.
  • How We Overcame It: We completely decoupled exploit harnesses from persistent external state. For data-layer vulnerabilities (such as SQL injection), the harness dynamically provisions an isolated, in-memory mock database per test lifecycle. We enforced deterministic binary exit code assertions (0 = exploit payload executed / vulnerability proven; 1 = sanitized or blocked). This guarantees that every reproducer produces the exact same binary outcome regardless of the host environment or execution speed.

3. Safe Execution of Untrusted Repositories in Hardened Micro-Sandboxes

  • The Challenge: To test arbitrary open-source and third-party repositories, our runner must execute potentially malicious code, untrusted npm/pip dependencies, and custom build scripts. Giving these scripts standard system access opens severe risks of host filesystem takeover, cryptomining, or SSRF attacks against internal infrastructure.
  • How We Overcame It: We engineered an Air-Gapped Disposable OCI Sandbox Runner. Each verification job runs inside a dedicated sandbox container enforced with:
    • --network none: Complete network isolation, ensuring zero data exfiltration or external command-and-control calls.
    • --read-only root filesystem backed by temporary in-memory tmpfs mounts for /tmp and /workspace that vanish the millisecond execution stops.
    • --cap-drop ALL & --security-opt no-new-privileges: Strips all Linux kernel capabilities to prevent privilege escalation.
    • Hard cgroup memory (64MB - 512MB) and CPU quotas with strict process table limits (--pids-limit 64) to completely neutralize fork-bombs and runaway resource consumption.

4. Semantic AST Fingerprinting Across Git Commits and Refactors

  • The Challenge: Conventional scanners track vulnerabilities by line coordinates (e.g. src/users.py:42). If a developer inserts 5 lines of comments or refactors an unrelated function above it, the finding shifts to line 47. Traditional tools misinterpret this as the old issue being "resolved" and a duplicate issue being opened, cluttering triage histories and breaking patch linkage.
  • How We Overcame It: We engineered a Semantic AST-Based Fingerprinting Algorithm. Instead of relying on volatile line coordinates, we hash a composite identity:
    Fingerprint = SHA256(RuleID + NormalizedFilePath + CanonicalASTCodeSnippet)
    
    The code snippet is stripped of non-semantic whitespace and indentation before hashing. This allows PatchProof to track the exact lifecycle of a vulnerability across git renames, re-indents, and branch rebases with zero false duplicates.

5. High-Throughput Job Orchestration Without Extra Infrastructure Overhead

  • The Challenge: We wanted to avoid the operational cost and complexity of deploying a separate Redis/RabbitMQ cluster alongside our primary database for job scheduling, while still supporting multiple concurrent worker instances without race conditions or duplicate execution.
  • How We Overcame It: We engineered an atomic job claiming pipeline directly inside PostgreSQL using SELECT ... FOR UPDATE SKIP LOCKED. When a worker polls the queue, PostgreSQL atomically locks only that specific row and imme

Discussion

Builders also viewed

See more projects on Devfolio