Commit Graph
8 Commits
Author SHA1 Message Date
F4ilji a32572f5e8 fix(vikon): remove env override for version, use hardcoded default 2026-07-05 17:44:45 +05:00
F4ilji eb142b2513 refactor(vikon): use Redis cache for version instead of file 2026-07-05 15:11:17 +05:00
F4ilji ad8a4d861b fix(vikon): read version from file and update after core update 2026-07-05 15:06:14 +05:00
F4ilji b259809960 feat(vikon): add updatePart endpoint with request validation 2026-07-05 02:50:41 +05:00
F4ilji 0811c4f1fc fix(vikon): add parameter to SyncFilesAction singleton 2026-07-04 20:55:14 +05:00
F4ilji 8e5f26da8d feat(vikon): add file sync from VIKON file manager (FM) 2026-07-04 20:41:49 +05:00
F4ilji 967db81d3c fix(vikon): use correct token introspect endpoint for update system
Original vikon_core security.php validates tokens via:
  POST db-nica.ru/oauth2/resource/token/introspect
  Body: client_id=542&access_token=XXX

Our code was incorrectly using:
  GET auth.db-nica.ru/api/profile_applicant/check_access_token
  Header: Authorization: Bearer XXX

This was the WRONG endpoint — the profile check is for abitur forms,
not for the update system.
2026-07-04 13:54:56 +05:00
F4ilji f4f8bc8e77 feat(vikon): rewrite VikonIntegration from scratch — OAuth + core update
- HttpTask: Laravel Http facade with SSL enabled, retry, timeout
- ValidateTokenTask: token check via auth.db-nica.ru
- RefreshTokenTask: token refresh via db-nica.ru
- FilesystemTask: path traversal protection, blocked extensions (PHP/ASP/etc)
- AuthenticateAction: OAuth2 code→token exchange
- CheckAccessAction: token validation + filesystem writability check
- CheckVersionAction: version comparison against remote API
- UpdateCoreAction: ZIP download, Zip Slip protection, atomic sync with rollback
- VikonController: thin controller, 7 endpoints with Session-based token storage
- Routes: access-check, dashboard.auth, throttle:30,1 middleware
- Vue 3 Composition API frontend with progress bar
- Config: all secrets in .env via config/vikon.php
- vikon_core kept as fallback (not deleted)
2026-07-04 12:53:28 +05:00