Hermes
ce21242308
feat(i18n): LocaleController switcher with open-redirect protection ( closes #73 )
...
- App\Controllers\LocaleController: GET /locale?set=xx&return=/path
- Sets 1-year cookie (HttpOnly=false for SSR, SameSite=Lax, Secure on HTTPS)
- 302 redirect to explicit return URL > Referer > /
- Pure buildResponse() helper for unit tests (no headers/exit)
- current() helper: resolves locale from $_GET/$_COOKIE/Accept-Language
- safeRedirect: rejects absolute URLs, protocol-relative (//evil.com),
backslash tricks (\\evil.com), javascript:/data: schemes
- 28 PHPUnit tests (LocaleControllerTest), all green
- Total project tests now: 92
2026-06-04 08:57:33 +00:00
1aedcaf314
refactor: Umstellung auf Mini-MVC-Architektur (Issue #46 )
...
Deploy Feature Branch to Test / deploy (push) Successful in 24s
- Front Controller Pattern mit public/index.php als Einstiegspunkt
- Eigenes Routing (App\Core\Router) ohne externes Framework
- Controller: HomeController, ImpressumController, DatenschutzController
- Views mit gemeinsamem Layout (app/views/layouts/main.php)
- PSR-4 Autoloading
- Statische Assets nach public/ verschoben
- Alte Dateien (index.php, impressum.html, datenschutz.html) geloescht
- 301-Redirects fuer alte URLs
- PHP 8.5 kompatibel
- Apache DocumentRoot auf public/ gesetzt
2026-05-19 14:38:38 +00:00