How Cal.com Rebuilt AppSec After Going Closed Source
How Cal.com consolidated noisy security tooling into one continuous, context-aware pull request security program with Gecko.
Gecko Security

Your microservice SAST setup flags injection bugs reliably. What it can't do is follow a request from an API gateway through an auth service into a data service and verify that the authorization chain held at every hop. Single-file analysis stops at the repo boundary, and in a microservice architecture, that's exactly where the interesting trust assumptions live. Cross-repo SAST treats the service mesh as the unit of analysis, and that architectural difference is what this post is about.
TLDR:
Standard static code analysis tooling starts with the same foundation: read a source file, parse it into an AST, run pattern queries against that tree. If code matches a known bad pattern, the tool raises a flag.
Taint analysis adds one layer. It tracks whether data from untrusted sources like HTTP parameters, user input, and environment variables flows to dangerous sinks like SQL queries, shell commands, and eval calls within that file's scope. A source-to-sink path with no sanitizing operation in between triggers a finding.
For injection vulnerabilities, this covers real ground. SQL injection, XSS, and command injection all have consistent syntactic shapes across codebases. Pattern matching was built for exactly that.
The file boundary is not incidental to how these tools work. It is the architectural assumption everything else is built on. The AST covers a single file. The taint graph spans one file. The pattern queries run against one file.
This is a structural constraint, not a tuning problem. No ruleset improvement changes the fact that the analysis stops at the file edge.
File-scoped static analysis has a structural limit that no amount of rule refinement can fix: it cannot see across service boundaries.
When a request enters Service A, gets validated, then passes a token to Service B where the actual authorization check runs, no single-file scanner catches the gap. The check exists. It just exists somewhere else. Tools that read one file at a time treat that token handoff as an opaque string with no security semantics attached.
This is the boundary condition that defines cross-repo SAST as a distinct category. The problem is architectural, not a matter of scanner sensitivity.
Three structural facts create this limit:
.py or .go files never sees the policy that is supposed to enforce access control.No tuning of pattern-match rules resolves any of these three points. Each one is a missing input, not a detection threshold problem.
Authorization bugs resist static analysis for business logic because they have no consistent syntactic signature. A missing if user.role == 'admin' check looks identical to intentionally public code. An IDOR vulnerability where a user fetches another user's record by manipulating an ID parameter appears, at the file level, as a perfectly valid database query. The scanner sees correct syntax. It sees a function call. It sees a return value. Nothing in the token stream says "this should have been gated."
This is why single-file analysis SAST tools consistently miss broken access control. The check that was supposed to run doesn't appear in the file being scanned because it lives somewhere else entirely: a middleware layer in a different service, a policy engine in a separate repo, an API gateway rule that never touches the application code.
The gap breaks down into a straightforward mismatch between available inputs and required reasoning:
assertOwner() call actually covers this code path.The structural fact is that authorization correctness is a property of a system, not a property of a file. No amount of rule refinement inside a single-file analysis SAST tool changes that boundary condition.
Each service in a microservice architecture exposes its own API surface requiring dedicated scanning, maintains its own data store, and enforces its own access control rules. When a request travels from a frontend through an API gateway, into a user-facing service, then into a downstream internal service, each hop crosses a trust boundary where authorization assumptions may differ.
Single-file SAST tools scan each service's codebase in isolation. They cannot follow the request across that chain.
The problem gets worse as service count grows. Consider a typical pattern in a mid-size deployment:
| Boundary | What the calling service assumes | What the receiving service assumes |
|---|---|---|
| Frontend to API gateway | Gateway validates JWT and enforces rate limits | Requests are pre-authenticated; no re-validation needed |
| API gateway to user service | User service enforces role checks | Gateway already stripped unauthorized requests |
| User service to data service | Data service trusts caller identity headers | Caller has already validated the user's permissions |
Each assumption is locally reasonable. Across the chain, they compose into a gap: if an attacker can forge or replay a caller identity header, the data service accepts it without question because it trusts the user service implicitly. No individual file contains the flaw. The flaw lives in the contract between services.
Cross-repo SAST vs DAST analysis requires tracing requests across these service boundaries, and beyond what any single one contains. A scanner that reads one repository sees the data service trusting the header. It cannot see that the user service fails to validate where that header came from.
The gateway validation pattern works as follows: the API gateway authenticates the JWT, confirms the user holds a valid role, then forwards the request to a downstream data service with a caller-identity header attached. The data service trusts that header and runs the query.
From inside the gateway file, the auth logic is complete and correct. From inside the data service file, trusting the caller header is deliberate design, not a flaw. A file-scoped scanner on either repo raises no flags because neither repo contains an error.
The omitted check is ownership. The gateway confirmed the user is authenticated. It never confirmed this user can access this specific record. The data service assumed that check happened upstream. No file contains the omission because it lives in the gap between them, in the contract neither service enforces.
This is the structural boundary that single-file analysis SAST cannot cross. The vulnerability has no location in either codebase. It has no location in the gateway repo, and it has no location in the data service repo. It exists only as an assumption each service makes about the other.
A scanner that reads one file, or even one repo, can only flag what is present. It cannot flag what was never written.
Taint analysis asks one question: does untrusted data reach a dangerous sink without sanitization? For injection vulnerabilities, that framing works. For authorization bugs in microservices, it fails at a structural level.
Authorization failures are not data-flow problems; they are part of the broader business logic AppSec problem. The question is not whether data travels an unsafe path, but whether the caller had the right to make this request in the first place. No taint propagation rule can answer that, because the answer lives outside the code itself, in trust models, role definitions, and service topology that no single-file analysis tool ever reads.
Consider a request that flows from an API gateway through an auth service and into a data service. Taint analysis can follow the data. What it cannot see is whether the auth service's decision was consulted at all, whether the token validated in Service A carries any meaning in Service B, or whether Service C is even supposed to accept direct calls from the client tier. Each of those questions requires reasoning across service boundaries, and cross-repo SAST is the only category of tool designed to do that.
Single-file analysis SAST tools treating authorization as a taint problem will consistently miss:
The structural constraint is real. Taint analysis is the right tool for injection. It is the wrong model for access control across service boundaries.
Cross-repo SAST requires the scanner to hold a coherent model of the entire system in memory at analysis time, extending well beyond the file or service currently under inspection. That means resolving service identities across repository boundaries, tracing token propagation through shared libraries, and mapping which roles or permissions each service is expected to enforce before any request reaches it.
Three capabilities separate tools that can do this from tools that cannot:
payment-service and order-service are distinct trust principals, and not treat them as two directories that happen to call each other. Without this, an authorization check in one service looks identical to a missing check in the other.Single-file analysis SAST handles none of these. It sees one file, applies rules, and moves on. Cross-repo SAST requires a fundamentally different architecture: a system-wide semantic index that treats the entire service mesh as the unit of analysis.
Broken access control has held the top spot in OWASP's Top 10 for good reason: according to OWASP's published research, it appeared in 100% of the roughly 500,000 applications tested in their 2021 dataset. Real-world cases like Cal.com broken access controls show exactly how this class of vulnerability leaks sensitive data at scale. That number reflects a detection problem as much as a development one. When authorization logic is spread across multiple services and repos, single-file analysis SAST tools simply cannot trace whether a given request was ever properly gated. The bug exists in the space between files, not inside any one of them.
Coverage gaps follow directly from the unit of analysis each tool operates on. Where a vulnerability lives inside a single file, single-file SAST works. Where it lives between services, it doesn't.
| Vulnerability Class | Single-File SAST | Cross-Repo SAST |
|---|---|---|
| Injection (SQLi, XSS, command injection) | Reliable detection via taint analysis and pattern matching within the file | Detected; additional service context provides no meaningful coverage gain for this class |
| Missing auth check at a single endpoint | Detected if the check is absent in the same file being scanned | Detected with higher confidence; can confirm no upstream service compensates |
| Authorization logic split across services | Blind; no visibility into how Service A's token validation interacts with Service B's permission check | Traceable across trust boundaries; the full call chain is visible |
| Inconsistent role enforcement across repos | Not detectable; each repo appears internally consistent | Detectable by comparing role definitions and enforcement points across services |
| Missing rate limiting on an internal-facing endpoint | May flag the absence, but cannot determine whether a gateway already enforces it | Resolves the ambiguity by inspecting the gateway and downstream service together |
The pattern here is structural. Single-file SAST gives accurate results for vulnerabilities that are self-contained. The moment a security property depends on behavior in a second service, a shared library, or an upstream gateway, the analysis has no way to verify whether that property holds.
Gecko's analysis starts from the same place the compiler does: a full semantic index built on language servers, not AST pattern matching, an approach that has produced 30+ CVEs in 8 months. That index spans multiple repositories, follows call chains across service boundaries, and tracks how shared libraries are called from different services with different trust contexts.
Where single-file SAST loses the thread at a module boundary, Gecko holds it. A permission check in auth-service that gets bypassed by a direct call from data-service is visible because both services exist in the same semantic graph at analysis time.
The cross-repo model also captures the deployment context that single-file tools cannot see. When Gecko reasons about a finding, it factors in whether the vulnerable endpoint sits behind an internal VPN or faces the public internet, which changes the risk weight of an otherwise identical code pattern.
The result is that authorization bugs requiring multi-service call chain reconstruction, the class of vulnerability that breaks OWASP's Broken Access Control category into individually invisible fragments across services, surface as single coherent findings, more like what automated pentest tools and best practices aim to produce, instead of scattered low-confidence alerts per file.
Single-file analysis SAST is not wrong. It is scoped, and its scope ends at the file edge. For injection vulnerabilities, that scope is enough. For authorization logic split across services, it is not, and your attack surface does not stop at the repo boundary either. Book time with the Gecko team to walk through what cross-repo analysis looks like against your actual service topology.
Authorization correctness is a property of a system, not a property of a file. A missing ownership check has no syntactic signature: the handler function reads as valid, the database query looks correct, and neither file contains an error. The omitted check lives in the contract between services, in the gap where one service assumes another already validated what it never did.
No. Semgrep operates at the file level by design and cannot trace call chains across service boundaries. Snyk focuses on dependency and supply-chain scanning; cross-service authorization tracing is outside its design scope. Both tools lose the thread at service boundaries by design; that is an architectural constraint, not a tuning gap.
A cross-repo scanner holds both services in the same semantic index at analysis time, so it can follow the token from the gateway through to the data service and verify whether ownership was ever checked, beyond confirming whether authentication occurred. Gecko builds that index using language servers for compiler-accurate call chain resolution, then traces the token's lifecycle across repositories to surface the missing ownership check as a single coherent finding with a working proof-of-concept, instead of two clean scans with no flags raised.
Run a cross-repo SAST scan that treats the entire service mesh as the unit of analysis. Manual pentests find these bugs but take weeks and produce a point-in-time snapshot; the same class of multi-service authorization flaw that produced the Cal.com account takeover chain (three bugs across services, none visible in isolation) will reappear as the codebase changes. Gecko's continuous scanning maintains a per-repository knowledge base that tracks remediation history and flags regressions, giving you pentest-quality coverage at the speed of CI.
The microservice boundary problem refers to the structural gap where authorization logic is split across services (authentication at the gateway, ownership checks in shared libraries, role enforcement in downstream data services) but single-file SAST tools scan each service in isolation and cannot trace whether the full authorization chain actually executes for a given request path. OWASP's 2025 data shows broken access control appears in 100% of roughly 500,000 tested applications, and this architectural split is a core reason file-scoped tools consistently fail to detect it.
Gecko Security
The latest news, technologies, and resources from our team.
How Cal.com consolidated noisy security tooling into one continuous, context-aware pull request security program with Gecko.
Gecko Security
See what actually changed in the OWASP Top 10 for 2026, from merged SSRF and XXE categories to new supply chain risks and scanner coverage gaps.
Jeevan Jutla
Gecko Security uncovered CVE-2026-21894 in August 2026, an n8n authorization bypass with CVSS 8.8. See why static tools missed it and how to remediate it.
Jeevan Jutla
Security misconfiguration is OWASP A05 for a reason. Learn how deployment context determines exploitability and how to fix gaps in August 2026.
Jeevan Jutla
How do modern AppSec vendors actually compare? This July 2026 capability map covers SAST, DAST, SCA, business logic flaws, and cross-service
Gecko Security
Break down your AppSec stack: what SAST, DAST, SCA, IAST, and pen testing each see — and what they miss. Updated July 2026 by Gecko Security.
Gecko Security
Occasional updates, new content, and insights. No spam; unsubscribe anytime.