mirror of
https://github.com/itflow-org/itflow
synced 2026-02-28 10:54:52 +00:00
Prevent post pages being accessed directly
This commit is contained in:
@@ -4,6 +4,8 @@
|
||||
* ITFlow - GET/POST request handler for roles
|
||||
*/
|
||||
|
||||
defined('FROM_POST_HANDLER') || die("Direct file access is not allowed");
|
||||
|
||||
if (isset($_POST['add_role'])) {
|
||||
|
||||
validateCSRFToken($_POST['csrf_token']);
|
||||
@@ -59,3 +61,11 @@ if (isset($_POST['edit_role'])) {
|
||||
|
||||
header("Location: " . $_SERVER["HTTP_REFERER"]);
|
||||
}
|
||||
|
||||
if (isset($_GET['archive_role'])) {
|
||||
|
||||
validateCSRFToken($_GET['csrf_token']);
|
||||
|
||||
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user