SPCS deep dive
Containers inside Snowflake's boundary, secure by default
Isolation, ingress, egress, caller identity and tunnels, as of November 2026.
Kevin Keller · kevinkeller.org
Why it matters
Data never leaves the governance boundary
- RBAC, masking and row access policies apply automatically
- No separate copies of data, no separate access control
- Snowflake patches the OS, drivers, controllers and registry
- Nodes are replaced at least monthly with hardened images
Check this first
Since May 2026, any role may publish public endpoints
BIND SERVICE ENDPOINT is now granted to PUBLIC automatically. Revoke it and grant it only to the roles that should have it.
Isolation
The owner role is the trust boundary
- Per customer: a dedicated cluster, isolated by security groups
- Same owner role: services can call each other by default
- Different owner roles: only with a granted service role
USAGEon a service doesn't grant its endpoints, andACCOUNTADMINcan't own one
Ingress
Every public request is authenticated and hardened
- TLS 1.2+, network policies, authenticated Snowflake users only
TRACEandCONNECTblocked, bearer tokens scrubbed- Security headers and a baseline CSP injected automatically
- CORS handled by the proxy, explicit origins only
- PATs go in the header as
Snowflake Token="…", notBearer
Egress
No External Access Integration, no egress
- Network rules are signed and installed in managed egress proxies
- Only ports 22, 80, 443 and 1024+ are allowed
network.egress.denied.packetsshows what was blocked- Stable egress IP ranges rotate: automate your allowlist
Caller identity
Run queries as the user, within a ceiling you set
With executeAsCaller, a service can query as the calling user.
Caller grants are a ceiling: a compromised service can never exceed them.
The caller token defaults to 120 seconds. Not supported through gateways or service functions.
The session token
Short-lived, scoped and refreshed in place
- Each service gets a dedicated service user
- A token valid up to 1 hour sits at
/snowflake/session/token - Works only inside your SPCS cluster, for one account, role and user
- Re-read it periodically; skip mounting it where it isn't needed
Observability
Logs and metrics land in the event table
| Tool | Use |
|---|---|
SYSTEM$GET_SERVICE_LOGS | Real-time tail, 100 KB |
SPCS_GET_LOGS | One service, full SQL |
| Event tables | Production audit, alerts, metrics |
Structured JSON logging fills severity and attribute columns.
Tunnelling
Reach infrastructure that isn't on PrivateLink
| Approach | Best for |
|---|---|
| Data Connectivity Proxy | Supported default, deny-all-inbound networks |
| SSH tunnel | Full control, reverse access |
| WebSocket tunnel | Data sovereignty, HTTPS-only |
| Tailscale (userspace) | Existing tailnet |
| ngrok | Webhooks, but bypasses ingress controls |
Know the limits
Plan around these
- Maintenance runs on weekend nights: single-instance services and jobs are disrupted
- Dropping a service with
FORCEdeletes its volumes; snapshots last 7 days by default - Images can't be dropped individually: one repository per environment
- Traffic between your services is plain TCP/HTTP: add TLS if policy requires it
The takeaway
One thing to do today: check who holds BIND SERVICE ENDPOINT.
Kevin Keller · kevinkeller.org