How to fix: CocoaPods Podfile.lock exposed
The response is a CocoaPods lockfile, identified by its PODS and SPEC CHECKSUMS sections.
Why it matters
The lockfile lists every pod and its resolved version, including analytics, crash-reporting and payment SDKs, and the checksum of each spec. That is a full inventory of the third-party code inside the mobile app, which is what an attacker needs to find a known issue in a bundled SDK.
Like Package.resolved, this reaching a web server means an app repository was published rather than a build artifact. The EXTERNAL SOURCES section, when present, names private podspec repositories, which discloses internal hostnames along with the dependency list.
How to fix it
- 1Remove the iOS project directory from the web-served path.
- 2Confirm any private podspec repository the file named is not reachable without authentication.
- 3Review the listed pod versions against known advisories for those SDKs.
Code examples
Find app project files under the document root
find /var/www -name 'Podfile*' -o -name '*.xcworkspace'References
Detected automatically by VulnRadar. The check id is supply-chain-podfile-lock-exposed, stable across every scan so you can filter or diff on it.
More supply chain checks
- Mediumnpm/yarn Lock File Exposed
- MediumPython Requirements File Exposed
- MediumRuby Gemfile or Gemfile.lock Exposed
- MediumExternal CDN Script Without SRI Hash
- HighHTTP Script Loaded on HTTPS Page
- MediumPHP composer.json or composer.lock Exposed
- HighDockerfile or docker-compose.yml Exposed
- Critical.env File Exposed at Public URL
Questions
- How severe is CocoaPods Podfile.lock exposed?
- VulnRadar rates this low severity in the supply chain category. The severity is fixed per check, not scored per site, so the same finding is the same severity on every scan.
- Does VulnRadar check for this automatically?
- Yes. It runs as part of every scan under the check id supply-chain-podfile-lock-exposed, which stays the same between runs so you can filter, diff, or gate CI on it.
- Which standards does CocoaPods Podfile.lock exposed map to?
- It maps to CWE-540. In the OWASP Top 10 it falls under A05:2021.
Missing a check?
The detection set is open. If you know a misconfiguration this does not catch, propose it: the issue template asks for the threat model, how to detect it, the false-positive risk, and a test fixture, which is the same thing a maintainer would have to work out anyway.