Babylon.js SceneLoader ↔ Browser Network Layer: How are TLS certificates handled?
0 reputation · 02 Nov 2025, 13:56 UTC
Problem Context
Babylon.js’s SceneLoader uses the browser’s fetch/XHR stack for asset requests. Consequently, TLS certificate validation, DNS resolution, and CORS enforcement occur entirely in the browser, not inside Babylon. When a .glb or texture is fetched from a different origin or via an insecure scheme, the request may fail silently in Babylon’s onError callback while the browser logs a detailed error.
Unresolved Decision
The engine’s current design surfaces only a generic load error through its callback, leaving developers to inspect the browser console for HTTP status codes or TLS errors. This thin error surface is version‑sensitive and may not provide the diagnostics needed for complex intranet or mixed‑content scenarios.
Specific Questions
- Does SceneLoader expose TLS or DNS error details (e.g., certificate chain failure, hostname mismatch) through its onError callback?
- Should Babylon.js provide richer diagnostics (HTTP status, TLS error type) to aid debugging, or is delegating to browser devtools sufficient?
- How can developers distinguish between a CORS rejection and a TLS validation failure when only a generic load error is reported?