Add practical examples to multiple files

- LF9-03 Virtualisierung: Docker Compose + Volume examples
- LF6-02 Frontend: To-Do list practical example
- LF8-04 ETL: Complete ETL pipeline example
- LF6-04 Sicherheit: Express.js security headers
- LF2-04 Nutzwertanalyse: Cloud provider selection example
- LF9-04 Monitoring: Prometheus alerts + Python logging
This commit is contained in:
2026-03-13 12:01:15 +01:00
parent eb4a13ef7c
commit 7df533c7a2
7 changed files with 331 additions and 7 deletions

View File

@@ -80,6 +80,29 @@ function escapeHtml(text) {
Content-Security-Policy: default-src 'self'; script-src 'self'
```
### Praktisches Beispiel: Express.js Sicherheits-Header
```javascript
const helmet = require('helmet');
const cors = require('cors');
app.use(helmet());
// CORS konfigurieren
app.use(cors({
origin: 'https://meine-app.de',
credentials: true
}));
// Rate Limiting
const rateLimit = require('express-rate-limit');
app.use('/api/', rateLimit({
windowMs: 15 * 60 * 1000, // 15 Minuten
max: 100, // Max 100 Anfragen
message: 'Zu viele Anfragen, bitte später versuchen'
}));
```
---
## CSRF (Cross-Site Request Forgery)