Security Checklist untuk Deploy — Security

Security Checklist Sebelum Deploy Sebelum mendeploy aplikasi ke production, pastikan semua aspek keamanan sudah dicek. Checklist ini membantu memastikan tidak a

Security Checklist Sebelum Deploy

Sebelum mendeploy aplikasi ke production, pastikan semua aspek keamanan sudah dicek. Checklist ini membantu memastikan tidak ada yang terlewat.

1. Authentication & Authorization

2. Input & Output

// Checklist validasi
// ✅ Semua input divalidasi di server-side
// ✅ Parameterized queries untuk semua database operations
// ✅ Output di-encode sesuai context (HTML, JS, URL)
// ✅ File upload divalidasi (tipe, ukuran, konten)
// ✅ Content-Type header di-set dengan benar

3. HTTP Security

# Headers yang harus ada
Strict-Transport-Security: max-age=31536000; includeSubDomains
Content-Security-Policy: default-src 'self'; ...
X-Content-Type-Options: nosniff
X-Frame-Options: DENY
Referrer-Policy: strict-origin-when-cross-origin

# Redirect HTTP ke HTTPS
# CORS dikonfigurasi dengan whitelist spesifik

4. Data Protection

5. Infrastructure

# Checklist server
# ✅ APP_DEBUG=false
# ✅ Error messages generik (tidak ekspos detail)
# ✅ Firewall dikonfigurasi
# ✅ SSH menggunakan key, bukan password
# ✅ Automatic security updates aktif
# ✅ Dependencies up-to-date dan di-audit

6. Secrets Management

Tools untuk Automated Checking

# Scan dependencies
npm audit
composer audit

# Scan security headers
curl -I https://yoursite.com

# Online tools
# - securityheaders.com
# - observatory.mozilla.org
# - ssllabs.com/ssltest (TLS configuration)

# SAST tools
# - SonarQube
# - Snyk Code
# - GitHub CodeQL

Deployment Checklist Template

Yang akan kamu pelajari