Skip to content
116 changes: 0 additions & 116 deletions TESTING.md

This file was deleted.

28 changes: 0 additions & 28 deletions debug-maintenance.php

This file was deleted.

2 changes: 1 addition & 1 deletion resources/app/Initializers/AuthInitializer.php
Original file line number Diff line number Diff line change
Expand Up @@ -59,7 +59,7 @@ public function run( array $argv = [] ): mixed
$sessionManager = new SessionManager();
$passwordHasher = new PasswordHasher();
$authentication = new Authentication( $userRepository, $sessionManager, $passwordHasher );
$csrfToken = new CsrfToken();
$csrfToken = new CsrfToken( $sessionManager );

// Create filters
$authFilter = new AuthenticationFilter( $authentication, '/login' );
Expand Down
55 changes: 31 additions & 24 deletions resources/config/routes.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ routes:
method: POST
route: /logout
controller: Neuron\Cms\Controllers\Auth\Login@logout
filter: auth
filter: auth-csrf

# Password Reset routes
forgot_password:
Expand Down Expand Up @@ -70,7 +70,7 @@ routes:
method: POST
route: /admin/users
controller: Neuron\Cms\Controllers\Admin\Users@store
filter: auth
filter: auth-csrf

admin_users_edit:
method: GET
Expand All @@ -82,13 +82,13 @@ routes:
method: PUT
route: /admin/users/:id
controller: Neuron\Cms\Controllers\Admin\Users@update
filter: auth
filter: auth-csrf

admin_users_destroy:
method: DELETE
route: /admin/users/:id
controller: Neuron\Cms\Controllers\Admin\Users@destroy
filter: auth
filter: auth-csrf

# Profile Management
admin_profile:
Expand All @@ -101,7 +101,7 @@ routes:
method: PUT
route: /admin/profile
controller: Neuron\Cms\Controllers\Admin\Profile@update
filter: auth
filter: auth-csrf

# Blog Post Management
admin_posts:
Expand All @@ -120,7 +120,7 @@ routes:
method: POST
route: /admin/posts
controller: Neuron\Cms\Controllers\Admin\Posts@store
filter: auth
filter: auth-csrf

admin_posts_edit:
method: GET
Expand All @@ -132,13 +132,13 @@ routes:
method: PUT
route: /admin/posts/:id
controller: Neuron\Cms\Controllers\Admin\Posts@update
filter: auth
filter: auth-csrf

admin_posts_destroy:
method: DELETE
route: /admin/posts/:id
controller: Neuron\Cms\Controllers\Admin\Posts@destroy
filter: auth
filter: auth-csrf

# Blog Category Management
admin_categories:
Expand All @@ -157,7 +157,7 @@ routes:
method: POST
route: /admin/categories
controller: Neuron\Cms\Controllers\Admin\Categories@store
filter: auth
filter: auth-csrf

admin_categories_edit:
method: GET
Expand All @@ -169,13 +169,13 @@ routes:
method: PUT
route: /admin/categories/:id
controller: Neuron\Cms\Controllers\Admin\Categories@update
filter: auth
filter: auth-csrf

admin_categories_destroy:
method: DELETE
route: /admin/categories/:id
controller: Neuron\Cms\Controllers\Admin\Categories@destroy
filter: auth
filter: auth-csrf

# Blog Tag Management
admin_tags:
Expand All @@ -194,7 +194,7 @@ routes:
method: POST
route: /admin/tags
controller: Neuron\Cms\Controllers\Admin\Tags@store
filter: auth
filter: auth-csrf

admin_tags_edit:
method: GET
Expand All @@ -206,13 +206,13 @@ routes:
method: PUT
route: /admin/tags/:id
controller: Neuron\Cms\Controllers\Admin\Tags@update
filter: auth
filter: auth-csrf

admin_tags_destroy:
method: DELETE
route: /admin/tags/:id
controller: Neuron\Cms\Controllers\Admin\Tags@destroy
filter: auth
filter: auth-csrf

# Page Management
admin_pages:
Expand All @@ -231,7 +231,7 @@ routes:
method: POST
route: /admin/pages
controller: Neuron\Cms\Controllers\Admin\Pages@store
filter: auth
filter: auth-csrf

admin_pages_edit:
method: GET
Expand All @@ -243,15 +243,21 @@ routes:
method: PUT
route: /admin/pages/:id
controller: Neuron\Cms\Controllers\Admin\Pages@update
filter: auth
filter: auth-csrf

admin_pages_destroy:
method: DELETE
route: /admin/pages/:id
controller: Neuron\Cms\Controllers\Admin\Pages@destroy
filter: auth-csrf

# Media Management Routes
admin_media:
method: GET
route: /admin/media
controller: Neuron\Cms\Controllers\Admin\Media@index
filter: auth

# Media Upload Routes
admin_media_upload:
method: POST
route: /admin/upload/image
Expand Down Expand Up @@ -332,6 +338,7 @@ routes:
method: POST
route: /resend-verification
controller: Neuron\Cms\Controllers\Member\Registration@resendVerification
filter: csrf

# Member Dashboard Routes
member:
Expand All @@ -357,7 +364,7 @@ routes:
method: PUT
route: /member/profile
controller: Neuron\Cms\Controllers\Member\Profile@update
filter: member
filter: member-csrf

# Event Category Management
admin_event_categories:
Expand All @@ -376,7 +383,7 @@ routes:
method: POST
route: /admin/event-categories
controller: Neuron\Cms\Controllers\Admin\EventCategories@store
filter: auth
filter: auth-csrf

admin_event_categories_edit:
method: GET
Expand All @@ -388,13 +395,13 @@ routes:
method: PUT
route: /admin/event-categories/:id
controller: Neuron\Cms\Controllers\Admin\EventCategories@update
filter: auth
filter: auth-csrf

admin_event_categories_destroy:
method: DELETE
route: /admin/event-categories/:id
controller: Neuron\Cms\Controllers\Admin\EventCategories@destroy
filter: auth
filter: auth-csrf

# Event Management
admin_events:
Expand All @@ -413,7 +420,7 @@ routes:
method: POST
route: /admin/events
controller: Neuron\Cms\Controllers\Admin\Events@store
filter: auth
filter: auth-csrf

admin_events_edit:
method: GET
Expand All @@ -425,13 +432,13 @@ routes:
method: PUT
route: /admin/events/:id
controller: Neuron\Cms\Controllers\Admin\Events@update
filter: auth
filter: auth-csrf

admin_events_destroy:
method: DELETE
route: /admin/events/:id
controller: Neuron\Cms\Controllers\Admin\Events@destroy
filter: auth
filter: auth-csrf

# Public Calendar Routes
calendar:
Expand Down
Loading