The AI Hiring Platform That Shipped Its Own Blueprint
A B2B HR-tech platform left its entire API schema public, served 55 prospects' personal data from one unauthenticated request, and let any website read logged-in users' data. The criticals are fixed. Here is how the chain fit together.
Target: Undisclosed — a B2B HR-tech SaaS platform. Reported privately to the vendor. The company is not named here, by policy.
One unauthenticated request returned the full name, work email and phone number of every person who had ever asked the platform for a demo.
They wanted a sales call. They got served to the open internet instead.
The company sells hiring software to enterprise teams. I mapped its external footprint over one session, and the backend answered its very first request with a friendly greeting that happened to include the total number of API routes it served. That number was in the hundreds.
Then I checked whether the API documentation was public. It was. That one fact unravelled the rest.
Everything here was reported privately. The critical findings have since been fixed, and I verified that on retest. A set of lower-severity hardening items is still being worked through, so — in line with my disclosure policy — this post names no company, shows no live endpoint, and leaves the still-open details out until they ship. What follows is the part that is safe to tell: the criticals, and how they were closed.
The scoreboard
| # | Finding | Severity | Status |
|---|---|---|---|
| 1 | Cross-origin data theft via CORS | Critical | Fixed |
| 2 | Unauthenticated mass PII leak | Critical | Fixed |
| 3 | Full API schema publicly exposed | Critical | Fixed |
| 4 | Unauthenticated third-party token generation | High | Fixed |
| 5 | Production source maps downloadable | High | Fixed |
| 6 | Destructive endpoint with broken auth order | High | Fixed |
| 7 | Internal validation stats exposed | Medium | Fixed |
| 8 | Unauthenticated cache-clearing endpoint | Medium | Fixed |
Plus a longer tail of lower-severity hardening items — security headers, build-time metadata in the frontend bundle, configuration that should sit behind auth — that I reported and am holding back here until they are closed. The details below cover the fixed findings only.
How I found it
The platform runs a single-page frontend on a CDN, a Python API backend, and a marketing site on a hosted page builder. A handful of subdomains were live. I started with passive mapping: subdomain enumeration, DNS records, technology fingerprinting. The API identified itself as FastAPI on the first response — and FastAPI, by default, ships interactive API documentation. That was the thread to pull.
1. The API blueprint nobody locked (Critical)
FastAPI enables Swagger UI, ReDoc, and a machine-readable OpenAPI schema out of the box. All three were reachable in production with no authentication.
The schema was hundreds of kilobytes of structured JSON: every route, every parameter, every request and response shape, every auth method the platform used — a complete, self-documenting map of the whole backend. It replaced days of blind enumeration with a single download, and it told me exactly which endpoints to look at next.
This is not a flaw in FastAPI. FastAPI does the right thing for development. The flaw is shipping to production without the config that turns it off:
app = FastAPI(docs_url=None, redoc_url=None, openapi_url=None)
Status fixed. All three documentation endpoints now return 404.
2. Fifty-five people who only asked for a demo (Critical)
The schema listed a route that returned demo requests. I called it without authentication. It returned every record.
Fifty-five people had filled in a "request a demo" form. The endpoint handed back each one's full name, work email, phone number and country — no authentication, no pagination, no rate limit. One request, a few kilobytes of personal data, covering prospects across several countries.
These were not customers. They were people who typed their details into a form expecting a sales call, and the platform served those details to anyone who asked. Under GDPR and equivalent laws, that is a reportable incident. The internal record identifiers returned alongside each person were also exactly the kind of value worth testing against other endpoints — a data leak that doubles as a seed for access-control testing.
Status fixed. The endpoint now requires authentication.
3. CORS that let any website read your data (Critical)
The API returned a wildcard Access-Control-Allow-Origin together with Access-Control-Allow-Credentials: true, on every route.
That pairing is the most dangerous CORS misconfiguration there is. It tells the browser: allow authenticated cross-origin requests from anywhere, cookies included. If a logged-in user so much as visited a malicious page, that page could quietly call the API as them and read whatever came back — their profile, their organization's candidate data, their interview records. The specific wording is meant to be rejected by browsers, but the intent behind it — "everything, from everywhere, with credentials" — is the real tell: nobody reviewed the CORS policy before shipping.
Status fixed. The API now reflects only its own frontend origin. Other origins get no CORS header at all.
4. Unlimited third-party tokens, on the house (High)
The platform used a third-party speech-to-text service to process audio, and exposed an endpoint that minted short-lived tokens for that service — fresh token per call, no authentication, no rate limit.
Anyone could loop it and generate tokens indefinitely, each one billable to the platform's account, each one backed by a cloud key-management operation that was also billable. A quiet way to run up someone else's invoice, and a sign that a sensitive capability had been wired straight to the public internet.
Status fixed. The endpoint now requires both an interview context and candidate authentication.
5. Source maps that gave back the source (High)
The frontend shipped source map files in production — several megabytes that together reconstruct the original, pre-minified code: component structure, state management, the authentication flow, and every build-time variable baked into the bundle.
Source maps exist to debug a build. They do not belong on a public server, where they quietly hand over the architecture. One build flag removes them:
GENERATE_SOURCEMAP=false
Status fixed. The map files now return 404, and the new bundle ships without a source-map reference.
6. A destructive endpoint that checked auth too late (High)
One route performed a destructive operation on organization data, and its authentication check ran after the business logic had already begun. An unauthenticated request came back as a server error from the half-run operation, rather than a clean "unauthorized" — which means the request was partly processed before anything stopped it. On top of that, the destructive action was wired to a request method that browsers and proxies feel free to cache, prefetch and log.
Two issues in one: a dangerous action on the wrong HTTP method, and middleware running in the wrong order. Ordering is a security control, not a detail.
Status fixed. The operation now uses the correct method and rejects unauthenticated requests before any logic runs.
7 and 8. Validation stats and a cache-clearing endpoint (Medium)
Two smaller but clean fixes. An endpoint exposed internal validation statistics — including whether third-party AI integrations were configured and working — to anyone who asked. And a cache-clearing operation accepted unauthenticated requests, letting a passer-by flush the platform's cache at will.
Status fixed. Both now require authentication.
The retest
I retested every reported item after the vendor's remediation window. The critical and high-severity findings below were confirmed closed:
| Finding | Original | Retest |
|---|---|---|
| CORS wildcard + credentials | * with credentials on all routes |
Allowlisted to the frontend origin only |
| PII endpoint | Dozens of records, no auth | Authentication required |
| API docs | Swagger, ReDoc and schema all public | 404 on all three |
| Token generation | Unlimited tokens, no auth | Requires auth + interview context |
| Source maps | Several files, multiple MB | 404, no source-map reference in the new bundle |
| Destructive endpoint | Wrong method, auth after logic | Correct method, auth before logic |
| Validation stats | Public | Authentication required |
| Cache clearing | Unauthenticated | Authentication required |
The vendor triaged by severity and closed the worst issues first — the PII exposure, the CORS misconfiguration and the public API map were all resolved. Credit where it is due. The remaining lower-severity items are a mix of "not yet reached" and "didn't rate it urgent"; I'm keeping those out of this write-up until they are fixed, and I'll update the post when they are.
What I took away
- Framework defaults are for development, not production. Interactive API docs enabled out of the box are a gift to a developer and a gift to an attacker. Shipping without turning them off hands over a complete route map. A few lines of config close it.
- Demo forms collect PII, so treat them like PII. People handed over their name, email and phone for a sales call, not a public JSON feed. Every endpoint that returns personal data needs an auth check — including the ones marketing asked for.
- Wildcard CORS with credentials is a review failure, not a typo. The setting itself says nobody looked at the cross-origin policy before release. Reflect a known allowlist of origins; never
*with credentials. - Source maps are the source. A single map file gives back the pre-minified code, the auth flow and every build-time variable. One flag removes them; there is no reason to ship them.
- Frontend bundles leak whatever the build injects. Assume the client bundle is fully public — because it is — and audit what your build bakes into it.
- Middleware order is a security control. An auth check that runs after the business logic isn't a missing check; it's a logic bug that turns every unauthenticated request into a partial operation.
If a platform's whole job is to assess who can be trusted, the platform itself should pass the same test. Lock the config, gate the endpoints, and assume someone will look.
Tools: subfinder for subdomain enumeration, dnsx for resolution, httpx for probing, manual JavaScript bundle analysis. Probes routed through Tor.
Want a review of your own external footprint? Reach me at hello@jmadhan.me.