TLS & HTTPS
Prism supports TLS natively through Network.framework — no OpenSSL, no BoringSSL, no external dependencies. Load a PKCS#12 certificate, set your minimum protocol version, and your server speaks HTTPS.TLS Configuration
Enable HTTPS
TLS Versions
Choose the minimum protocol version your server accepts:Version Options
HSTS Middleware
HTTP Strict Transport Security tells browsers to always use HTTPS. This prevents protocol downgrade attacks and cookie hijacking:HSTS Headers
Security Headers
PrismSecurityHeadersMiddleware adds a suite of protective headers to every response:
Security Headers
X-Content-Type-Options: nosniff— prevents MIME type sniffingX-Frame-Options: DENY— blocks clickjacking via iframesX-XSS-Protection: 1; mode=block— enables browser XSS filterReferrer-Policy: strict-origin-when-cross-origin— controls referrer leakage
Production Setup
A typical production configuration combines all security layers:Production Security Stack
Creating a PKCS#12 Certificate
Convert PEM certificate and key to PKCS#12 format:Convert to PKCS#12
Self-Signed Certificate
Prism uses Apple’s Security framework (
SecPKCS12Import) for certificate loading. This is the same system used by iOS and macOS apps — battle-tested and maintained by Apple.