Files
ntspi-app/app/Containers/VikonIntegration/UI/WEB/Routes/web.php
T
F4ilji 3dc29d44d8 fix(vikon): DNS bypass, OAuth callback, ABITUR init, token cache, ZIP security
- Add CURLOPT_RESOLVE DNS bypass for db-nica.ru / file.db-nica.ru
- Add OAuth callback route with CSRF state validation
- Add /authorize endpoint to generate OAuth URL with state
- Add ABITUR special case: init empty module core without ZIP download
- Add token validation caching (150s) to reduce API calls
- Block PHP/PHTML/PHAR files inside ZIP before extraction
- Add VikonTokenRefresh middleware for auto token refresh
- Add vikon.refresh middleware alias to Kernel
2026-07-04 17:44:50 +05:00

20 lines
1.2 KiB
PHP

<?php
use App\Containers\VikonIntegration\UI\WEB\Controllers\VikonController;
use Illuminate\Support\Facades\Route;
Route::prefix('/dashboard/vikon-updates')
->name('dashboard.vikon-updates.')
->middleware(['access-check', 'dashboard.auth', 'throttle:30,1', 'vikon.refresh'])
->group(function () {
Route::get('/', [VikonController::class, 'index'])->name('index');
Route::get('/callback', [VikonController::class, 'oauthCallback'])->name('callback');
Route::post('/authorize', [VikonController::class, 'authorize'])->name('authorize');
Route::post('/authenticate', [VikonController::class, 'authenticate'])->name('authenticate');
Route::post('/refresh-token', [VikonController::class, 'refreshToken'])->name('refresh-token');
Route::post('/check-access', [VikonController::class, 'checkAccess'])->name('check-access');
Route::post('/check-version', [VikonController::class, 'checkVersion'])->name('check-version');
Route::post('/update-module', [VikonController::class, 'updateModule'])->name('update-module');
Route::post('/logout', [VikonController::class, 'logout'])->name('logout');
});