From 24b244b612aa4f530cf224edc41e25289ffeaa8a Mon Sep 17 00:00:00 2001 From: johnnyq Date: Mon, 2 Mar 2026 19:32:45 -0500 Subject: [PATCH] assets: Add missing CSRF checks, add missing permission checks, renamed unarchive to restore --- agent/asset_details.php | 12 +++--- agent/assets.php | 6 +-- agent/modals/asset/asset_link_credential.php | 1 + agent/modals/asset/asset_link_document.php | 1 + agent/modals/asset/asset_link_file.php | 1 + agent/modals/asset/asset_link_service.php | 1 + agent/modals/asset/asset_link_software.php | 1 + agent/post/asset.php | 41 ++++++++++++++------ 8 files changed, 44 insertions(+), 20 deletions(-) diff --git a/agent/asset_details.php b/agent/asset_details.php index 5da8b5e6..6b15bd2a 100644 --- a/agent/asset_details.php +++ b/agent/asset_details.php @@ -716,12 +716,12 @@ if (isset($_GET['asset_id'])) { Share - + Unlink - + Delete @@ -813,7 +813,7 @@ if (isset($_GET['asset_id'])) { - + @@ -879,7 +879,7 @@ if (isset($_GET['asset_id'])) { data-modal-url="modals/document/document_view.php?id="> - + @@ -970,7 +970,7 @@ if (isset($_GET['asset_id'])) { " target="_blank" >$file_description"; ?> - + @@ -1193,7 +1193,7 @@ if (isset($_GET['asset_id'])) { - + diff --git a/agent/assets.php b/agent/assets.php index 5c95226e..a1b46543 100644 --- a/agent/assets.php +++ b/agent/assets.php @@ -402,8 +402,8 @@ $num_rows = mysqli_fetch_row(mysqli_query($mysqli, "SELECT FOUND_ROWS()"));
+ + + + +