Atlaslog
Atlaslog / Field Notes / Security & compliance
Field note · Security & compliance

Sensitive facilities and tiles exposed in a public front-end bundle

Quick answer

A routine security scan found facility names and coordinates inside the built JS bundle, and an object-storage tile path readable without login. Raw GeoJSON was imported into the bundle and tiles were published to a public bucket, so no data classification or isolation boundary existed.

Last verified 2026-11-03 · Multiple versions · Cite this page
Applies to: Vite 5.4 / object storage / Nginx
Symptom
Checklist
  1. Grep the build output for sensitive field names and exact coordinate literals
  2. Check `src` for `.geojson`, `.shp` or `.gpkg` files that are imported directly
  3. Request a tile and a data endpoint with an unauthenticated `curl` and look for 200
  4. Review the bucket policy and the CDN origin configuration
  5. Check whether test or demo environments use production data
Fix

Keep sensitive data out of the bundle and fetch it at runtime from an authenticated endpoint (`fetch('/api/secure/features', { headers: { Authorization: 'Bearer ' + token }, credentials: 'include' })`), serve tiles from a private bucket behind signature URLs or an `auth_request` proxy, and generalize coordinates before public display.

Code
[高危] 前端静态资源包含敏感地理信息
  文件: /assets/index-3e8a21.js
  命中: "变电站","管线走向",116.39,39.90

[高危] 对象存储桶允许匿名读取
  GET https://oss.example.cn/gis/secret/12/3412/1420.pbf
  HTTP/1.1 200 OK
  x-oss-object-acl: public-read
grep -r "secret\|classified\|管线" dist/assets/ | head
curl -I "https://oss.example.cn/gis/secret/12/3412/1420.pbf"
# 期望 403;返回 200 即为公开可读
Watch out
All 120 field notesChinese originalRunnable examples
English edition written for Atlaslog from the original Chinese field note. Code is unchanged and runs as-is.
Cite this page

Atlaslog (2026). Sensitive facilities and tiles exposed in a public front-end bundle. https://www.jingweizhi.com/en/cookbook/sensitive-data-leak.html (accessed 2026-11-03).