|
Bearsampp 2026.3.26
API documentation
|
Go to the source code of this file.
Variables | |
| $csrfProtectedEndpoints | |
| $proc = Util::cleanPostVar('proc', 'text') | |
| $procMap | |
| if(in_array( $proc, $csrfProtectedEndpoints, true)) if(isset($procMap[$proc]) &&file_exists($procMap[$proc])) | else |
| $csrfProtectedEndpoints |
Define which endpoints require CSRF protection. Read-only endpoints (GET-like operations) don't need CSRF protection. Write operations (POST that changes state) require CSRF protection.
| $proc = Util::cleanPostVar('proc', 'text') |
Definition at line 61 of file ajax.php.
Referenced by ActionExt\__construct(), ActionQuit\checkForOrphanedProcesses(), Win32Ps\findByPath(), Win32Ps\findByPid(), ActionQuit\generateCleanupReport(), Win32Ps\killBins(), ActionStartup\killOldInstances(), ActionStartup\processWindow(), and ActionQuit\terminatePhpProcesses().
| $procMap |
| if (!empty( $proc)) else |
Validate CSRF token for protected endpoints Check if the cleaned 'proc' parameter exists in our secure mapping. If valid, include the corresponding AJAX handler file using the pre-defined path. If not valid, return a JSON error message.